The CreatorCon Call for Content is officially open! Get started here.

I am trying to convert a workflow to a flow in flow designer and I am not sure where to put the scripts.

TempestT-37
Tera Contributor

I am new to ServiceNow, still learning
In the workflow, I have a run script block and I have this script

current.description = current.short_description;
current.short_description = current.variables.title_of_request;

Also I have a Create Task block, and in the Advanced Script area, I have

task.short_description = current.short_description

I cannot find a place to add the script. I have tried adding pills but the information I am looking for is blank.

4 REPLIES 4

cp11
ServiceNow Employee
ServiceNow Employee

For simple things like this you dont need to script, you can add using the data pill, when you say the information is blank - what do you mean? 

If you absolutely must script - you start by creating an action and using that action in your flow

I dont think you need that based on what I'm seeing above

TempestT-37
Tera Contributor

CP Thank you for your reply. 

In my research, I have seen posts where they were using a script step to add scripts so I was trying to find that.

I have tried using data pills when creating both a flow or a subflows, but I am not sure which to use. In both, I have added a send email to validate that the information I am wanting to capture from the catalog (title_of_request) is present. Everything I have tried when I check the email the information from the pill I added is blank/empty. I feel that either the record did not load or I am adding it wrong.

When I am using a flow I cannot find an option to add title_of_request. I do find title_of_request when I try to use a subflows which makes me believe I should use a subflow. 

This flow/subflow needs to run every time my Catalog item (ITS Request for Resources) is submitted.

Hopfully this helps you help me.

Thank you.

Richard Hine
Tera Guru

I recommend you take this course to get familiar with Flow Designer:

https://nowlearning.service-now.com/lxp?id=learning_path_prev&path_id=193b8e6c87acf450ed3b74c9cebb35...

and this course to understand a little more about Integration Hub:

https://nowlearning.service-now.com/lxp?id=learning_path_prev&path_id=329ac7201bbafcd4a5e699b1b24bcb...

Developing without this training could result in longer time to achieve your outcome.

Thanks,

Richard

Richard thank you for the course suggestion, I will take a look at them.