Form fields visible when click on UI actoin

ganeshexpert
Kilo Contributor

I want the field to be visible on incident form when user click on form header button newly created. Then user enter the value for that fields and update the incident. Is it possible to create show form fields when user click button.

 

Thanks in advance.

5 REPLIES 5

DrewW
Mega Sage
Mega Sage

The best way to do this is to add the field to the table and then the form.   Have an onLoad script hide the field using g_form.   Then create a UI Action that runs on the client that when clicked unhides the field.



Keep in mind that there is setDisplay and setVisible and they are a little different.



g_form docs


http://wiki.servicenow.com/index.php?title=GlideForm_(g_form)


lawrence_eng
Administrator
Administrator

Note:



I moved this thread out of the Support sub-community and into the Implement sub-community.



thanks,


Lawrence


--


Online Community Program Manager, ServiceNow


Bhavesh Jain1
Giga Guru

2 Steps :



1. Create ONLOAD client script


Capture 2.png


2. Create UI Action



Capture.PNG


Regards,


Bhavesh


IGate-logo.png


http://www.igate.com


This does'nt seem to work as because if I am putting the statement- action.setRedirectURL(current) in the UI action, that make the form to load and the field is geting hidden as per onload client script .