Hi
I hv a lookup field which give me a view with accont name, account number and product offered i wanted to retrieve to account number from the lookup i hv used the following code to get the values
function pushvalue( ) {
if (Xrm.Page.getAttribute("account").getValue()!= null)
{
var acc = Xrm.Page.getAttribute("account").getValue();
if(acc !=null) {
var varSubject = Xrm.Page.getAttribute("number").getValue(); // get the value of
field
Xrm.Page.getAttribute("number").setValue(acc[0].name);
// set description field value
alert (varSubject);
}
}
}
the account is the lookup field on the form, the result of the above is it only get the account name and does not get the account number from the lookup field. how change i change the script so that it get the account number and not the account name