cannot set property of an element by api call.

Hi All ,

My api function (getElementById) is absolutely correct . But this is not setting the property :

elements.XXXXXl_1.getElementById('btnNew').enabled = false;

But this is working fine :

elements.XXXXXXXX_2.menuItems[0].enabled = false;

Please provide some suggestions . How can we set the property using the api call ?

Please give some suggestions

https://wiki.servoy.com/pages/releaseview.action?pageId=1869552#Specification(.specfile)-Enabled

Thanks for your reply .

In my case “enabled” is not the direct model property . menuItems is the model property . and enabled is one of the property of the menuitem . It is not working.

Please provide some suggestions.