Solved

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

Posted on 2013-10-22
3
1,190 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

Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

Question has a verified solution.

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

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.
Desired Skill Set for Microsoft Dynamics CRM Technical Resources – Part I
The view will learn how to download and install SIMTOOLS and FORMLIST into Excel, how to use SIMTOOLS to generate a Monte Carlo simulation of 30 sales calls, and how to calculate the conditional probability based on the results of the Monte Carlo …
The viewer will learn how to use a discrete random variable to simulate the return on an investment over a period of years, create a Monte Carlo simulation using the discrete random variable, and create a graph to represent the possible returns over…

751 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