Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nuGet version works on development machine, error on prodcution server #94

Closed
simmy7 opened this issue Aug 26, 2014 · 2 comments
Closed

Comments

@simmy7
Copy link

simmy7 commented Aug 26, 2014

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!

@eneifert
Copy link
Contributor

eneifert commented Sep 3, 2014

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.

@simmy7
Copy link
Author

simmy7 commented Sep 3, 2014

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

@eneifert eneifert closed this as completed Sep 3, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants