I have a script that has a line that fails to work on 64 bit Windows 7 that used to work on WinXP. The line that fails is:
RunProgram>cmd /c net view /domain:engineering > %temp_dir%EngTest.txt
I have 2 workgroups and two domains. I use "net view" with each of them to create a list of all the computers on my network. I have four RunProgram> lines identical to the one above except that they each have a different domain or workgroup name. The other three lines work fine this one line does not. It gives an "Access denied" error.
On the same Win7 computer.
Running "net view /domain:engineering" from a DOS prompt works fine.
Running "net view /domain:engineering" from "Start" > "Search Programs and Files" works fine.
I tried putting the line in a batch file and running the batch file. Again it works every way I run it except from Macro Scheduler RunProgram> and ExecuteFile>
I tried putting Let>RP_Admin=1 ahead of the RunProgram> line and it still fails.
Any suggestions welcome.
Net View Access Denied
Moderators: JRL, Dorian (MJT support)
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
Re: Net View Access Denied
Macro Scheduler will be running the 32 bit version of cmd.exe and in turn it is running the 32 bit command. Try this:
RunProgram>%SYS_NATIVE%\cmd /c net view /domain:engineering > %temp_dir%EngTest.txt
You may also need RP_ADMIN if it's an admin thing or run Macro Scheduler/the macro as admin first.
RunProgram>%SYS_NATIVE%\cmd /c net view /domain:engineering > %temp_dir%EngTest.txt
You may also need RP_ADMIN if it's an admin thing or run Macro Scheduler/the macro as admin first.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
Re: Net View Access Denied
SYS_NATIVE did the trick.
Thank you very much.
Dick
Thank you very much.
Dick