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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Service | Customer Service, Contact Center, Fie...
Suggested Answer

Set date & time field using JS

(0) ShareShare
ReportReport
Posted on by 10

Hi,

I want to save date & time field in CRM using JS.

I tried formContext.getAttribute("date").setValue(d);

Thanks in advance

I have the same question (0)
  • Suggested answer
    Bipin D365 Profile Picture
    28,985 Moderator on at

    Hi,

    What is d that you are setting?

    Are you getting any error?

    I tried below code on my instance and it worked.

    var currentDate = new Date();

    formContext.getAttribute("birthdate").setValue(currentDate);

    mscrmonline.wordpress.com/.../

    Please mark my answer verified if this is helpful!

    Regards,

    Bipin Kumar

    Follow my Blog: xrmdynamicscrm.wordpress.com/

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

Season of Sharing Community Challenge Launch!

Jump in, show your community spirit, and win prizes!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Congratulations to the May Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Service | Customer Service, Contact Center, Field Service, Guides

#1
Abhilash Warrier Profile Picture

Abhilash Warrier 51 Super User 2026 Season 1

#1
Muhammad Shahzad Shafique Profile Picture

Muhammad Shahzad Sh... 51 Most Valuable Professional

#3
Nagaraju_Matta Profile Picture

Nagaraju_Matta 50

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans