Code not working in script step in flow designer whereas it is perfectly working fine in background
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-15-2024 08:34 AM
Hello community members,
Code not working in script step in flow designer whereas it is perfectly working fine in background.
Any idea what could be the reason?
//background script works fine gives the content present in text file.
var output = '';
var is = new GlideSysAttachment().getContentStream(sysid);
var reader = new GlideTextReader(is);
var ln = ' ';
while((ln = reader.readLine()) != null) {
// gs.info(ln);
output = ln;
gs.print(output);
}
// Same script not fine in Script Step in action
Please assist if you can let me know what needs to be changed in code in flow side
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-22-2024 01:19 AM
Any update can anyone assist here?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-07-2024 09:38 AM
it could be a scope issue, instead of getContentStream() can you try getContentBase64() and output the results in /sys.scripts.do in the same scope as the flow
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-29-2024 10:11 AM
I have the same issue and I have opened a case with support a month ago. They are still trying to figure out the issue.