locked
Iframe + Javascript...to change value of a field. RRS feed

  • Question

  • Hi everyone. I want to create a CRM time control as an IFrame which automatically populates a drop down field in CRM. This drop down field contains a time.

    I want it to be something like this http://www.nogray.com/time_picker.php

    Any ideas on where to start?

    Monday, July 16, 2012 8:42 PM

All replies

  • You can code your IFrame as an html page, then add it to your solution as a web resource.  You can use the window.Parent object to refer to your CRM page that hosts your IFrame.  You can then use the Xrm.Page.getAttribute('crmfieldname') to manipulate the value, something like:

    window.Parent.Xrm.Page.getAttribute('crmfieldname').setValue('newValue');

    in Javascript

    Monday, July 16, 2012 9:06 PM