- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-27-2017 11:31 PM
Hi Team,
On the change request form, i have a field called "Change Owner". There is also a "company field" which is a reference to the company table. The company record has a field called "u_test" which is a user reference field. (It's like a company manager field with the managers name).
I want the "Change owner" field in the change request form to have the default value of "u_test" based on the company field.
How can this be done?
I have tried "javascript : current.change_owner = company.u_test"
But i did not get anything.
All help is appreciated.
Thank you
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-27-2017 11:43 PM
So, basically, you need to have to change_owner name based upon the company name. I think you can get it done through onChange() client, let's try and see if this helps.
function onChange(control, oldValue, newValue, isLoading) {
var cmp= g_form.getReference('company', doAlert);
}
function doAlert(cmp) {
g_form.setValue('change_owner', cmp.u_test);
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-27-2017 11:57 PM
Hi Guys,
Thank you all for the replies. All of you guys are correct with the Client script, unfortunately i can only select one correct answer. But all your answers are correct.
Thank you