Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

How to Save form using UI Action Server Script(Without Client)

AlwinJebakY
Tera Expert

I have one Requirement 
In Work order form have one Button, If user click that button need to save all the fields from that current form.
Here don't use Client option in UI Action

Current.update() is not capture all the fields. 
In that time what we can do? 


So any OOB is there or how we can achieve that 

1 ACCEPTED SOLUTION

@Ankur Bawiskar 
After update the record need to perform the Integration with another application, for that I need new Button
Once perform that Information this button is disappeared.

And one more think this button is need to show in Portal also. 
In Portal Client checked UI Actions are not shown, and don't want more portal customization.




View solution in original post

4 REPLIES 4

Ankur Bawiskar
Tera Patron
Tera Patron

@AlwinJebakY 

why not ask them to use Update button which is available OOTB? why to use custom button?

it will save record with the latest values user entered on form

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

@Ankur Bawiskar 
After update the record need to perform the Integration with another application, for that I need new Button
Once perform that Information this button is disappeared.

And one more think this button is need to show in Portal also. 
In Portal Client checked UI Actions are not shown, and don't want more portal customization.




@AlwinJebakY 

in portal client side UI actions don't render on form, only Server side buttons are shown

Since your requirement is to have that then you need to use current.update() to update the record

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

@Ankur Bawiskar 

I try with current.update() already, but it will not get all the fields from current form. 
If you know any other solution let me know.