UI Action, is it possible that gsftSubmit() returns value?

PhoenixMing0912
Giga Expert

For example

function on_test(){

    gsftSubmit(null, g_form.getFormElement(), 'test');

}

 

I want to do some client scripts after calling gsftSubmit() and use some values from server.

I have also tried GlideAjax, however, in my server side scripti I need to use current.update() which is not supported in AJAX script include.

 

1 ACCEPTED SOLUTION

Hi Phoenix,

I haven't come across scenario where you will write code after gsftSubmit()

that line is used to pass control from client to server only client side script or validations are done

you can have async GlideAjax just before gsftSubmit() is you want to update the record and that script include function will update the record

Regards
Ankur

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

View solution in original post

12 REPLIES 12

Ankur Bawiskar
Tera Patron
Tera Patron

Hi Phoenix,

are you saying after using gsftSubmit() you still want to execute some script; I believe once you add that line the control moves over from client to server

Regards
Ankur

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

But I think there should be a callback and continue to execute the scripts after gsftSubmit().

Hi Phoenix,

I haven't come across scenario where you will write code after gsftSubmit()

that line is used to pass control from client to server only client side script or validations are done

you can have async GlideAjax just before gsftSubmit() is you want to update the record and that script include function will update the record

Regards
Ankur

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

It sounds possible, but how to pass the "current" to a GlideAjax script include so that I can do update afterwards?