I have set up an email event to trigger a Job action that is supposed to pass email variables to a job. For some reason, I can only pass 1 variable through the job action Parameters Override section.... ie <email.subject> or <email.message>. If I try to put more than one, it bombs out. I have tried a space, comma, carriage return, quotes, etc... At this point, I would like to see if it is even possible to do this or if I have to try a different technique.
Email event --> Job Action with override parameters to launch job, which launches script below and prints to echo.txt for testing. It will give me %1, but never %2. Here is the cmd....
echo %Number1% >c:\active\echo.txt
echo %Number2% >>c:\active\echo.txt
For testing, can you just echo %1, echo %2 in the script and see if the joboutput shows the values ? Does it still only display the value of %1 ?
Did what you said above. Still only echo of %1. Override output below:
"test 5" "<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<body lang="EN-US" link="#0563C1" vlink="#954F72">
<p class="MsoNormal">Test 6<i><span style="font-size:8.0pt;font-family:"Arial",sans-serif;color:gray"><o:p></o:p></span></i></p>
<p class="MsoNormal"><o:p> </o:p></p>
I ran the script above with the parameters you sent. The first argument is just text without html tags, test 5 so this gets echo correctly and directed to echo.txt. The second argument, however, is the culprit. This message body contains a plethora of html tags, angled brackets, and quotation marks--it's no wonder why the script would error out. Most common error for this type of problem is the syntax of the command is incorrect, or < was unexpected at this time. If you would like to see for yourself, then try running it from the DOS shell. Is it possible for you to use plain ASCII text as an alternative?
This is totally possible however you have to set up what you want correctly
if you are using Tidal 5.3.1 which is what it looks like
I tested this out and it works... you may encounter problems with Number of Characters or something
Let us know how it turns out
Add the quotes around the variables in the Parameters section
In your script, let's remove intermediate variables, and strip quotes
echo %1 %2
echo %~1 > C:\active\echo.txt
echo %~2 >> C:\active\echo.txt