Creation of Task on Windows 7 remotely using Managed Wrapper.

Topics: Errors
Nov 7, 2014 at 6:56 AM
I am trying to create task in remote computer running on Windows 7 from client computer running Windows 7. Is it possible? When I tried to do this I get following exception.

System.UnauthorizedAccessException was unhandled
Message=Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))

As per this MSDN link, http://technet.microsoft.com/en-us/library/cc766266.aspx , one can create task remotely connected to computers running Windows Server® 2008, Windows Vista®, Windows Server 2003, Windows XP, or Windows 2000.
Coordinator
Nov 7, 2014 at 3:25 PM
You need to be in a domain and need to be a member of the Administrators group on the remote computer. Try doing it using the "Connect to a remote computer" menu item in the "Task Scheduler" system app.
Nov 11, 2014 at 7:20 AM
I also tried option 'Connect to another computer' option from task scheduler by specifying remote machine name and credentials. I got error 'Task scheduler service is not available. Verify that service is running'. I found task scheduler services at both end up and running. What could be the issue?
May 29, 2015 at 6:41 AM
While creating a remote task, I am getting error message "(18,8):LogonType:". What could be the issue? I am using logon type 'TaskLogonType.S4U' to create the task. Please help.
Coordinator
May 29, 2015 at 8:55 PM
This is usually either that the account used when creating the TaskService object doesn't have rights to create the task with an S4U user, you haven't supplied a username in the RegisterTaskDefiniton method, or there is a combination of settings on the task's definition that can't be run interactively.
Marked as answer by dahall on 9/1/2015 at 9:58 AM