Hi all, hope anybody can help me
I wrote a little Powershellscript for creating a Login-document for a user. I have a Word .docx Template and just replace some text like 'user_login' or 'user_mail' etc. with the real user data.
The script is working when I start it from my Windows Powershell ISE, but it doesn't work when I start it over ARM Web Client. So I get a 'Job finished successfully' in ARM, but the final file isn't there.
What am I missing?
I created a Share on our ARM Maschine where our ARM-serviceuser has the rights to read/write, so I don't think it's a permission problem?!
And I have a second question:
How can I monitore the output of my Powershellscript?
I wanted to write my -Verbose into a textfile with ' -Verbose 4> file.txt' but this also isn't working.
from ARM I only get the logfiles which contains only the transfered Json File.
do I have to write outputs in my powershellscript with ' Write-Host' ?
Thought Write-Verbose would be better cause I can switch the output on and off.
I would be happy, if anyone can help me
the problem is, that since Office 2013 office automation is not working anymore per default in session 0. The reason is that you could write macros and so on. The script engine in ARM is running in session 0 and therefore your script is not working. TO overcome that you need to go to DCOMCNFG.EXE in Admin mode on the machine and check if you can see the Word DCOM Object. Now change to interactive user, that should work now. If you need still further help we can do it together via remote let. Contact me at Mike.Wiedemann@cusatum.de.
Have a nice day.
ARM by default records the console output of the script that is being run in its own log file. That should include output from Write-Verbose assuming you pass the -verbose flag or set the $VerbosePreference variable accordingly.
You can find a link to the log file in the "Logbook" section of the ARM fat client in the category "Execute External Script":
SolarWinds solutions are rooted in our deep connection to our user base in the THWACK® online community. More than 150,000 members are here to solve problems, share technology and best practices, and directly contribute to our product development process. Learn more today by joining now.