Topic
1 reply Latest Post - ‏2013-05-06T10:01:41Z by AleksandarKarneluti
SystemAdmin
SystemAdmin
1316 Posts
ACCEPTED ANSWER

Pinned topic Passing variables to a SYSOPTS cmd

‏2013-02-09T16:27:28Z |
I have the following process:

&ARG1=""
&ARG2=""
&FILE1="&ARG1"
&FILE2="E:\testB\&ARG2"

XCOPYB RUN TASK PNODE (PGM=Windows)
SYSOPTS="cmd(xcopy) args(&FILE1 &FILE2 /k)"

File Agent is calling this process with &ARG1="%FA_FILE_FOUND." &ARG2="%FA_NOT_PATH."

In the File Agent logs, the variables are getting translated correctly.

The process validates fine and when running a Process Monitor on it, returns with a result code of 0. However, the files never copy. I think I'm missing something minor can't figure out what. Probably something simple I'm overlooking.

If anyone could shed some light on how to resolve this I would be greatly appreciative. I've found many different ways people use SYSOPTS cmd to handle variables and tried different variations but can't seem to get it to work.

Thanks!
Jason