How to access attributes RRS feed

  • Question

  • Hi, I am fairly new to CRM development and this is my first post on this forum.  I am using CRM 4.0 and my question are the followings :


    1) Is the only way to have access to an entity's attribute in a form to include it in the form itself?  For instance, say we add a new_read_only attribute to my entity and we'd like disable my form's elements using jscript, do we have to add the new_read_only field to our form and then hide it using style.display = 'none'? The disadvantage to us using this approach is that the print preview form (executed from the crm toolbar) does show hidden attributes and that isn't what we want.  The alternative we found is to obtain these attributes by calling the crm web services from jscript on the onload event, but that again has the disadvantage of being a complex way and having to do another round trip to the server. 


    2) Similarly, when we are in a plugin, is it possible to access properties that were not modified (even if they were not shown in the form) without having to do a round trip to the server to obtain these attributes?  We know there is a ForceSubmit attribute we can set for element that are in the form but that again doesn't solve our problem if the attribute is not shown in the form.


    Thanks for your help,


    Wednesday, May 21, 2008 4:49 PM


  • Hi


    1) There are not other way than as you describe it. Also if you hide fileds using JScript users can find the values by viewing the html source.


    7)You have to do the round trip.





    Wednesday, May 21, 2008 5:21 PM