How do you run a scheduled task with Quest powershell snap in?
Asked
Active
Viewed 2,997 times
2 Answers
2
You would schedule PowerShell.exe, and use one of its command-line parameters to specify the script to run. At the start of that script, add:
Add-PSSnapin Quest.ActiveRoles.ADManagement
That will load the snapin for that script, and then execute whatever else is in the script.
(BTW, this would be the case for any script that needs one or more extra snapins.)

Don Jones
- 9,367
- 8
- 39
- 49
0
Another option would be to create a console file (using Export-Console - which will create a *.psc1 ) and adding -PSConsoleFile YourConsole.psc1 to your powershell.exe command line.

Steven Murawski
- 10,959
- 41
- 53