Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

please find below the code where I am trying to access a Webresource. I am working on CRM 2016

var xyz= window.xyz|| {};

$("#WebResource").contentWindow.xyz.Scheduler.load();

Gives out "Unable to get property 'contentWindow' of undefined or null reference" message.

Need help.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
457 views
Welcome To Ask or Share your Answers For Others

1 Answer

Don't manipulate the DOM, it's unsupported.

Do this

Xrm.Page.getControl("WebResource").getObject().contentWindow.[etc. etc.]


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...