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

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics SL (Archived)

DSLDate don't work correctly in New .Net application

(1) ShareShare
ReportReport
Posted on by 7

Hi All,

I created a new .Net application used in SL and I'm using the DSLDate control connected to a SmallDateTime field in the database.

I managed to assign the DateTime.Now value to my "ReceivedDate" field using Value when opening the screen.

But when I leave this field (lost focus) without making any changes and my date ends with an 8 or a 9 (Ex: July 8 or July 19), the control change it to the MinDate or MaxDate value.

If the date ends with something else, it stays with the assigned value at the opening.

As soon as I select a new date in the calendar popup, this error stop to occur.

More, in any case, in the immediate window, i get this error each time: 

Exception setting property Text.
System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.ArgumentOutOfRangeException: Year, Month, and Day parameters describe an un-representable DateTime.
at System.DateTime.DateToTicks(Int32 year, Int32 month, Int32 day)
at Microsoft.Dynamics.SL.Controls.DSLDate.set_Text(String value)
--- End of inner exception stack trace ---

Best Regards,

Martine

*This post is locked for comments

I have the same question (0)

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…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics SL (Archived)

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans