On clicking on the UI Action , getting message as connection refused

Community Alums
Not applicable

HI Team,

 

I am trying to redirect to a URL using UI Action for eg.  action.RedirectURL('xyz.com');

Its giving message on center of page as "refused to connect." But when I open the URL from browser I am able to see the login page.

 

Can you assist, how to get rid of this error?

 

BR,

Ankur

1 ACCEPTED SOLUTION

Community Alums
Not applicable

Its not working.I am getting below error in the logs:

com.glide.script.RhinoEcmaError: "window" is not defined.
sys_ui_action.408457c0db55e910ec203ec8f4961905.script : Line(17) column(0)
14:
15: var url = 'https://' + gs.getProperty('it.glue.com') + '/' + current.u_global_id;
16: gs.info(url);
==> 17: window.open(url, '_blank');

 

This is server side code, does "window" command work in server side?

View solution in original post

6 REPLIES 6

Hi @Community Alums,

 

Please find the below KB.

https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0721369 

 

I hope this helps!

 

Regards,

Hemant 

**If my answer has helped with your question, please mark my answer as accepted solution and give a thumb up.

**

Community Alums
Not applicable

Thaks its resolved...by writing this code:

var url = 'https://' + gs.getProperty('it.glue.com') + '/' + current.u_global_id;
action.setRedirectURL(url);

 

That is first I set it in URL later I do redirect.. That was the issue I guess.