I have created a onChange client Script auto populate the user's mobile number

kranthi2
Tera Expert

Hi,

I have created a onChange client Script auto populate the user's mobile number, but it is not working as per the expectation.

please find the below mentioned SS

 

 

kranthi2_0-1706188251386.png

 

onLoad:

 

kranthi2_1-1706188314241.png

 

onload is working fine but onchange is not working.

 

Thanks,

 

 

 

Thanks,

 

 

 

12 REPLIES 12

@kranthi2  Are you doing it on personal instance then i can quickly check it ? script is absolutely fine i tested on my personal instance. 

If possible you can connect via zoom or any webex , send me details on below email .

hvrdhn88@gmail.com.

 

Ehab Pilloor
Mega Sage

Hi @kranthi2,

You need to assign the variable 'r' for getReference in line 11. You haven't assigned it and then used it in your setValue. 

 

If you found this reply useful, please mark it as solution/helpful.

 

Thanks and Regards,

Ehab Pilloor

Tai Vu
Kilo Patron
Kilo Patron

Hi @kranthi2 

It appears that your script works fine from my end.

There're 2 different phone fields: Mobile phone [mobile_phone] and Business phone [phone]. Make sure you're using the correct field.

Screenshot 2024-01-25 at 21.32.33.png

Screenshot 2024-01-25 at 21.33.02.png

 

You can try the Auto-populate (no code feature) within the variable. And see if it works.

Screenshot 2024-01-25 at 21.34.11.png

 

Cheers,

Tai Vu