web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Start date and end date are same

(0) ShareShare
ReportReport
Posted on by 95

6170.1.PNG

0804.2.PNG

Hi all 

if we select one Start date for any month(Ex:May) and if i clicked on End date calendar should show the same month(May). have any code for this ? Check the Screen shot if i selected start date of May month if i click on end date the calendar should show May Month only?

*This post is locked for comments

I have the same question (0)
  • Verified answer
    Community Member Profile Picture
    on at
    RE: Start date and end date are same

    Hi Atmakuri Rajashekar,

          No need to write code for this. Just Add TransDate(Extended Data Type) or FromDate(Extended Data Type) on your selected field. Automatically it will show the calender to select the required date.

    Thanks

    Suresh

  • Verified answer
    Faisal Fareed Profile Picture
    10,796 User Group Leader on at
    RE: Start date and end date are same

    What are you trying to achieve and for start and end data simply use transDate EDT for your date type fields in table.

  • Verified answer
    Community Member Profile Picture
    on at
    RE: Start date and end date are same

    Hi Rajashekar,

        As my understanding when you select the start date,  also the same date should reflect in EndDate?

        You need the pass the start date in end date, for this you need to write piece of code.

        You can do this by modified method, in standard will have so many methods are there in tables. please refer those. If not please us know, i will try to help you.

    Thanks

    Suresh

  • Verified answer
    Faisal Fareed Profile Picture
    10,796 User Group Leader on at
    RE: Start date and end date are same

    Hi,

    Under your form's datasource, go to startDate field and override modified method and put this sample code. Replace dateSourceName with actual datasource name of your form.

    public void modified()

    {

       super();

       dataSourceName.EndDate = dataSourceName.StartDate;

    }

  • Atmakuri Rajashekar  Profile Picture
    95 on at
    RE: Start date and end date are same

    hi Suresh

    Can you send the code

  • Verified answer
    Community Member Profile Picture
    on at
    RE: Start date and end date are same

    Hi,

        As your asking to show same month on end date is not easily possible.

        But if you wanted to show start date as enddate you can do easily by modified method.

      

        

    public void modified()
    
    {
       super();
       
       dataSourceName.EndDate = dataSourceName.StartDate;
    
    }


    If it not your solution, please let me know.

    Thanks

    Suresh

  • Atmakuri Rajashekar  Profile Picture
    95 on at
    RE: Start date and end date are same

    Thank you Mr. Faisal Fareed

    I got it.

  • Verified answer
    Faisal Fareed Profile Picture
    10,796 User Group Leader on at
    RE: Start date and end date are same

    Cheers.

    Please verify answer if it helps you.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Community Member Profile Picture

Community Member 4

#2
Nayyar Siddiqi Profile Picture

Nayyar Siddiqi 2

#2
NNaumenko Profile Picture

NNaumenko 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans