I have a WebResource with html mark-up that draws a html button with an onclick event. The onclick event calls a javascript function that tries to reference the data property on Xrm.Page. The html webresource is embedded on a Form in a custom entity.
When I click the html button and debug the script I can see that Xrm.Page.data is NULL.
I tried calling this same javascript function in the OnLoad event of Form. In this case the Xrm.Page.data property is not null.
Should i expect the Xrm.Page.data property to be NULL when embedded in a webreource on a form and populated when used in OnLoad event of the form?
*This post is locked for comments