Hello,
I am using Windows 7 computer, .NET 4.0 application running as administrator.
Now the process is running using MyUserAccount and from this account I can connect to computer MyRemoteComputer using the Task Scheduler GUI that comes with Windows 7 and I can create Windows 7 compatible tasks (>v1) using the GUI.
Now if I use new TaskService(MyRemoteComputer) it fails with an access denied exception. If I call TaskService(MyRemoteComputer,MyUserAccount,MyDomain,MyPassword, false) same thing. If however I cange false to true (so force v1) it works!
I can also call TaskService(MyRemoteComputer,null,null,null,true) and that works as well so it is not an issue with credentials as you can see it is successfully creating a v1 task remotely, so why will it not allow v2 given that MyRemoteComputer is WIndows 7 and I can do this via the GUI?
I am using Windows 7 computer, .NET 4.0 application running as administrator.
Now the process is running using MyUserAccount and from this account I can connect to computer MyRemoteComputer using the Task Scheduler GUI that comes with Windows 7 and I can create Windows 7 compatible tasks (>v1) using the GUI.
Now if I use new TaskService(MyRemoteComputer) it fails with an access denied exception. If I call TaskService(MyRemoteComputer,MyUserAccount,MyDomain,MyPassword, false) same thing. If however I cange false to true (so force v1) it works!
I can also call TaskService(MyRemoteComputer,null,null,null,true) and that works as well so it is not an issue with credentials as you can see it is successfully creating a v1 task remotely, so why will it not allow v2 given that MyRemoteComputer is WIndows 7 and I can do this via the GUI?