Quantcast
Channel: CRM Development forum
Viewing all articles
Browse latest Browse all 8223

Xrm.Page.getControl not working

$
0
0

I'm doing an upgrade from CRm 4.0 to CRM 2011. I'm trying to update the following line of code:

document.getElementById("nav_intrastudent").style.display='none';
alert(document.getElementById("nav_intrastudent"));

to use Xrm.Page.getControl, like this:

var control = Xrm.Page.getControl("nav_intrastudent");	

alert(control);

The first alert works, the second one is null. I can't see anything wrong with the Xrm.Page.getControl statement. Any ideas?

Thanks


Viewing all articles
Browse latest Browse all 8223

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>