I wrote an c# console app which calls web service.
I needed to run this app for every night, so I decided to use this task scheduler as it seems a good one to do my job.
But I got an issue which says "Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object. ..."
I read many articles described about same issue, but nothing is helpful.
For example,
```
TaskDefinition td = ts.NewTask();
td.RegistrationInfo.Description = "Does something";
td.Principal.Id = "any string";
td.Principal.GroupId = "NETWORK SERVICE";
td.Principal.RunLevel = TaskRunLevel.LUA;
td.Principal.LogonType = TaskLogonType.S4U;
ts.RootFolder.RegisterTaskDefinition(@"NetsuiteInvoiceGetTask", td);
```
My OS is Windows7 64bit.
Can anyone help me? Thanks.
Comments: Unknown resolution
I needed to run this app for every night, so I decided to use this task scheduler as it seems a good one to do my job.
But I got an issue which says "Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object. ..."
I read many articles described about same issue, but nothing is helpful.
For example,
```
TaskDefinition td = ts.NewTask();
td.RegistrationInfo.Description = "Does something";
td.Principal.Id = "any string";
td.Principal.GroupId = "NETWORK SERVICE";
td.Principal.RunLevel = TaskRunLevel.LUA;
td.Principal.LogonType = TaskLogonType.S4U;
ts.RootFolder.RegisterTaskDefinition(@"NetsuiteInvoiceGetTask", td);
```
My OS is Windows7 64bit.
Can anyone help me? Thanks.
Comments: Unknown resolution