How to set default value on Reference variable?

Radhika11
Tera Contributor

Hello everyone,

I have two variables (Requested For and Asset Tag).

Based on the user name, asset tag will automatic populate the assets that the user currently have.

 

1.  When the form load, the Asset Tag is showing empty.

Radhika11_0-1691777091276.png

 

2.  When I clicked on the Asset Tag, it showing all the Assets that belonging to the user.

Radhika11_1-1691777641366.png

 

Here is what I would like to accomplish: 

When form load..... 

If user has 1 asset, then default the asset tag in the Asset Tag field

else if user has more then 1 asset, then don't default to the first asset, just list them so that user have an option to select from the dropdown.

 

Thank you so much,

 

 

 

10 REPLIES 10

Hello @Jaspal Singh 

 

Thank you for your suggestion.

 

Based on the user name, asset tag will automatic populate the assets that the user currently have.  This part is working fine. Your suggested code is what I currently have in the Reference qualifier for Lookup Select Box

 

Here is what I would like to accomplish and Swarnadeep Nandy is trying to guide me there.

When form load..... 

If user has 1 asset, then default the asset tag in the Asset Tag field

else if user has more then 1 asset, then don't default to the first asset, just list them so that user have an option to select from the dropdown.