GlideEvaluator.evaluateString not working from the flow actions

vishnupuli
Tera Expert

I am trying to use GlideEvaluator.evaluateString from the custom flow action, it is returning a null value.

If anyone encountered the same issue or having any workaround please respond here

4 REPLIES 4

Amit Verma
Kilo Patron
Kilo Patron

Hi @vishnupuli 

 

Is your action part of a scoped application? If it is not in Global Scope, use GlideScopedEvaluator.

. Refer https://developer.servicenow.com/dev.do#!/reference/api/yokohama/server/no-namespace/c_GlideEvaluato...

 

Thanks and Regards

Amit Verma


Please mark this response as correct and helpful if it assisted you with your question.

Yes Amit, action is part of Global space.

Ankur Bawiskar
Tera Patron
Tera Patron

@vishnupuli 

is your flow action is global scope?

Is the script field against which you are evaluating in same scope or other scope?

what's your business requirement?

GlideEvaluator.evaluateString also works in scoped app.

If my response helped please mark it correct and close the thread so that it benefits future readers.

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

Yes Flow action is in Global. below is the action script and results

For task_sd, i am directly getting the variable

For task_desc, I am using evaluateString and passing as a string.

vishnupuli_0-1739486312484.png

 

Output:

vishnupuli_1-1739486481357.png

 

 

If i use the same from the fix script it is executed as expected.

 

vishnupuli_2-1739486568065.png

 

Output:

vishnupuli_3-1739486618011.png