You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am using the ZendeskApi_v2_Net35.dll to create tickets. When I use the following code from VS 2010 (on Win7) it works fine.
ZendeskApi api = new ZendeskApi("https://XXX.zendesk.com/api/v2", "zendesk@XXX", "", "XXX");
var ticket = api.Tickets.CreateTicket(new ZendeskApi_v2.Models.Tickets.Ticket()
{
Requester = new ZendeskApi_v2.Models.Tickets.Requester {Email = email},
Subject = (Subject == "" ? "Default Subject" : Subject),
Comment = new ZendeskApi_v2.Models.Tickets.Comment() { Body = details }
});
The problem is that when I use the same code on the production server (win 2003 with .net 3.5, IIS 6) I get the following error:
System.NullReferenceException: Object reference not set to an instance of an object.
at ZendeskApi_v2.Core.RunRequest(String resource, String requestMethod, Object body)
at ZendeskApi_v2.Core.RunRequest[T](String resource, String requestMethod, Object body)
at ZendeskApi_v2.Core.GenericPost[T](String resource, Object body)
at ZendeskApi_v2.Requests.Tickets.CreateTicket(Ticket ticket)
at DataService.ContactUs2
I have tried downloading the source code from here but I get lots of errors when I try to compile, and it seems oriented to .Net 4 and above.
Any help greatly appreciated!
The text was updated successfully, but these errors were encountered:
Here is an idea, assuming you are using nuget, after you download the package, find the ZendeskApi_v2_Net35 dll, copy it somewhere, then remove the package from nuget and manually reference that dll. I just want to verify that the correct dll is being referenced.
I have used the example on the Zendesk site which doesn't use the DLL and have indirectly discovered that the Securoty Certificate isn't being received properly, so I am assuming that's causing the problem. Just a shame that this DLL (and the other code) don't give a better error message
I am using the ZendeskApi_v2_Net35.dll to create tickets. When I use the following code from VS 2010 (on Win7) it works fine.
ZendeskApi api = new ZendeskApi("https://XXX.zendesk.com/api/v2", "zendesk@XXX", "", "XXX");
var ticket = api.Tickets.CreateTicket(new ZendeskApi_v2.Models.Tickets.Ticket()
{
Requester = new ZendeskApi_v2.Models.Tickets.Requester {Email = email},
Subject = (Subject == "" ? "Default Subject" : Subject),
Comment = new ZendeskApi_v2.Models.Tickets.Comment() { Body = details }
});
The problem is that when I use the same code on the production server (win 2003 with .net 3.5, IIS 6) I get the following error:
System.NullReferenceException: Object reference not set to an instance of an object.
at ZendeskApi_v2.Core.RunRequest(String resource, String requestMethod, Object body)
at ZendeskApi_v2.Core.RunRequest[T](String resource, String requestMethod, Object body)
at ZendeskApi_v2.Core.GenericPost[T](String resource, Object body)
at ZendeskApi_v2.Requests.Tickets.CreateTicket(Ticket ticket)
at DataService.ContactUs2
I have tried downloading the source code from here but I get lots of errors when I try to compile, and it seems oriented to .Net 4 and above.
Any help greatly appreciated!
The text was updated successfully, but these errors were encountered: