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 CRM (Archived)

CRM 365 auto format date time field input

(0) ShareShare
ReportReport
Posted on by 241

We are using CRM 365 on-Premise V8.2, I need a function that auto format user's input on the date time field. For example, on Contact form, if user enters 01011980, I can use script to change it to 01/01/1980. Any suggestion on how to do this?

Here is what I have done so far:

1) On CRM 2011, we have script add onKeyup event to field with className "ms-crm-DateTime". It doesn't work now. So in the Form_load event, I am trying to add the event using Xrm.Page.getControl("birthdate").addOnChange or addOnKeyPress but I always got error says "Property/Method not found". I am not sure what I did wrong.

2) I add change event to the birthdate field from Form editor. The problem is that, this event only fires when the field has an valid value. Also I am not sure how to get the "raw" value of the user input, CRM date time value returns a long string representing CRM date time.

Thanks

Holly

 

*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 CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans