get the value of a select box in record producer script(service portal)

G Balaji
Kilo Guru

Hi,

I'm creating a record producer where I have a "select box" and "reference" variables. How to capture the value entered by user from "Select Box" and "Reference" type variables. I tried g_form.getValue('variable_name') but it doesn't work.

What am I missing in syntax

 

Thanks.

1 ACCEPTED SOLUTION

it should be like

 

current.field name=producer.variable_name;

 

current.audit_frequency=producer.audit_frequency;
current.biso_head=producer.sys_id;

 

https://docs.servicenow.com/bundle/london-it-service-management/page/product/service-catalog-managem...

View solution in original post

12 REPLIES 12

please share the screenshot where exactly have you written this

Thanks for the response,Harshvardhan.

 

pfa SCREENSHOT

it should be like

 

current.field name=producer.variable_name;

 

current.audit_frequency=producer.audit_frequency;
current.biso_head=producer.sys_id;

 

https://docs.servicenow.com/bundle/london-it-service-management/page/product/service-catalog-managem...

Record producer is for custom table. Variable name in record producer and field name in table were different. Setting the names resolved this issue.

glad it solved.

kindly mark the answer correct and close this thread