SCCM Add to Device Collection activity

Rick Mann
Tera Expert

I am working with the SCCM Activity pack and specifically the Add to Device Collection activity.  The activity works great, but occasionally we may have an invalid collection name passed into the workflow.  I would like to capture the error and write it to the work notes of the RITM.

This docs article states that the Output can be passed to other activities in the workflow, but I'm not sure how to do that.  I've tried adding the following to a run script after the SCCM activity, but I'm not having success.

doProcessResponse();
function doProcessResponse() {
workflow.scratchpad.chkcol = activityOutput.output.toString();
workflow.scratchpad.chkerror = activityOutput.error.toString();
}

 

find_real_file.png

find_real_file.png

Thank you for any insight on how to pass output from the SCCM activity into a run script.

Rick

 

1 REPLY 1

Dale Hynes
Kilo Sage

Rick, the answer is in this thread:  https://community.servicenow.com/community?id=community_question&sys_id=f8c8c761db5cdbc01dcaf3231f961930&view_source=searchResult

Specifically:  https://hi.service-now.com/kb_view.do?sysparm_article=KB0635207