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)

How to assign date vasue to entity attribute using xrmservice toolkit library in crm 2015?

(0) ShareShare
ReportReport
Posted on by 262

Hi,

On my html web resource i have an calendar control. I select a date.

I put the date to a variable as  

 var dateVal= document.getElementById("test").value;

and i want this value to assign to the entity attribute. But i can't the xrmservice library gives me error. Her is my assigment :

  entityObj.attributes["new_billdate"] =dateVal;  

How can i  achieve this? Cn anyone help me please?

*This post is locked for comments

I have the same question (0)
  • Aileen Gusni Profile Picture
    44,524 on at

    What is the error?

    I think you need to convert the dateVal to the CRM DateTime value

  • Verified answer
    Nithya Gopinath Profile Picture
    17,078 on at

    Hi Muharrem,

    Try the following code. Hope it helps.

     entityObj.attributes["new_billdate"] = { value: dateVal, type: "DateTime" };

    Thanks

  • altun8tr Profile Picture
    262 on at

    I solved my problem thanks a lot

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