Solved

MS CRM 2011 JSCRIPT - Set Date and time in contract end date - not accepting my time

Posted on 2013-10-22
3
1,197 Views
Last Modified: 2013-10-28
1. I have experienced that it prints the incorrect date from a contracts end date on a schedule.
2. We capture the contract end date (Fieldname: "expireson") as 28th February but it prints
    1st March 2013.
3. I enquired on Experts-Exchange and they recommended that I must change the time
     when entering it in the form.
4. I made the field only a display field and populates it with JavaScript.  
5. I have attached my function in JavaScript.
6. The variable in which I set up the date and time is correctly populated.
7. I set the date for 08:00:00. (See on attachment)
8. When I print the contract schedule it prints still the incorrect date.
9. Looking in the data base I see the time value is populated as 22:59:59:000. See the SQL
    Query display in attachment.
10. I have changed the time value in my JavaScript to other values but it keeps changing it
      to this value.
11. I will appreciate help a lot. I do not know what to try anymore.
12. Thanking you in advance for your help.
function-DateAndTime-and-Results.doc
0
Comment
Question by:Pierre_Eksteen
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 27

Accepted Solution

by:
Chinmay Patel earned 500 total points
ID: 39592161
Hi Pierre_Eksteen.

Are you sure there is no workflow/plugin being executed that can change this field in the background?

CRM stores datetime in UTC format and UI takes care of conversion so I don't think a script is needed here to prepare a datetime string.

Regards,
Chinmay.
0
 

Author Closing Comment

by:Pierre_Eksteen
ID: 39602595
Hallo Chinmay,

Just want to thank you for the direction and guideline. It was a view with a selection over the database table (contracts) that caused it with some scripting.

Thanks again.
Regards.
Pierre.
0
 
LVL 27

Expert Comment

by:Chinmay Patel
ID: 39605018
No problem Pierre. Glad I could help.
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The new Microsoft OS looks great, is easier than ever to upgrade to, it is even free.  So what's the catch?  If you don't change the privacy settings, Microsoft will, in accordance with the (EULA) you clicked okay to without reading, collect all the…
Article by: Leon
Software Metering within our group of companies has always been an afterthought until auditing of software and licensing became a pain point. Orchestrator and SCCM metering gave us the answer and it was an exciting process.
Viewers will learn the different options available in the Backstage view in Excel 2013.
The viewer will learn how to create two correlated normally distributed random variables in Excel, use a normal distribution to simulate the return on different levels of investment in each of the two funds over a period of ten years, and, create a …
Suggested Courses

623 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question