Quantcast
Channel: Microsoft Dynamics CRM Forum - Recent Threads
Viewing all articles
Browse latest Browse all 82002

GetSrc() of an Html WebResource is not working

$
0
0

In CRM 2015, I add a WebResource in the ServiceAppointment entity's form.

When I call this function: Xrm.Page.getControl('WebResource_Test').getSrc() in the javascript web resource of the ServiceAppointment form, I get this error in Chrome : Uncaught TypeError: this._control.get_innerControl(...).getSrc is not a function. And this error in IE : Object doesn't support property or method 'getSrc'.

When I call this function for the same WebResource from others similar entities (ex: PhoneCall), it works.

Here are the results when I inspect the ServiceAppointment WebResource in Chrome console :

Here are the results when I inspect the same WebResource from a similar entity (Phone Call) in Chrome console :

Why the control is different in ServiceAppointment ? Is it only because ServiceAppointment is an exception ? If yes, I might use a different way for this entity, instead of getSrc(), something like : document.getElementById('WebResource_Test').getAttribute('url')

Thank you,


Viewing all articles
Browse latest Browse all 82002

Latest Images

Trending Articles



Latest Images