Link to home
Start Free TrialLog in
Avatar of apollo7
apollo7Flag for United States of America

asked on

CRM 2011 Autopopulate lookup field onload

I have a lookup fleld that I want to populate with the same value every time the form loads (and when the lookup field is empty).

The field is called "new_lookupid" and the text value I want to add to this field when the form loads is: "This is the first value for the lookup".

Can someone give me the Jscript that I can put in a function that is called onLoad?

Thanks
ASKER CERTIFIED SOLUTION
Avatar of Chinmay Patel
Chinmay Patel
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of apollo7

ASKER

Thanks, this worked great and when I used the text of the actual lookup, I did not get the warning symbol.
:) Great to hear. If the record with that text exists then it will not, if that record is missing[suppose you migrate to a new environment or the text of that record is changed] then it will show that icon.
Avatar of apollo7

ASKER

Good to know - at some point I will need it to select the first option (instead of hard coded value) but that is for another day :)

Thanks again