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

Fow Hide Field based on checkbox selection

$
0
0

Hi, 

please forgive my ignorance, but I am new to CRM 2011.

I would like to simply show or hide a field based on whether a checkbox is selected or not.

I have research the following code, but I still cannot get this to work, can someone please point me in the right direction.

the code is:

function ShowHide()

    {
        if(Xrm.Page.getAttribute("tsg_additionaltraining").getValue() == 0)
    {
        Xrm.Page.getControl("tsg_date").setVisible(False);
    }
        else
    {
        Xrm.Page.getControl("tsg_date").setVisible(True);
    }

All I'm then doing is calling the ShowHide function from the OnChange Event.

Thanks in advance for the assistance.

James



James Everson


Viewing all articles
Browse latest Browse all 8223

Trending Articles



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