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

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

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

Jonas ”Jones” Melgaard – Community Spotlight

We are honored to recognize Jonas "Jones" Melgaard as our April 2025…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 294,336 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 233,025 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,158 Moderator

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans