I have one of the field called business unit needs to be populated based on the requested for onchan

vinuth v
Tera Expert

Hi All

I have on of the field called Bussiness unit field and it is a reference field.

My query is when I select request for user, users Department needs to be populated when User open the form .

I wrote the Onchange script and it is working fine.

Business unit field is reference one, when I open the form my Department needs to be populated automatically and when I changed the requested for name automatically requested for user department needs to be populated.

How to populate the Requested for department when the form is loaded.

Note : Bussiness unit field is reference one.

 

Thanks

Vinuth

 

6 REPLIES 6

Hi @Brian Lancaster 

I tried above way also javascript:gs.getUser().getDepartment();, this one also not working.

I'm referring to the field on the form that has the user. The one that your onchange script runs against. That needs the default value of 

BrianLancaster_0-1666727513463.png