Reputation: 105
System.NullReferenceException: Object reference not set to an instance of an object. at Microsoft.Web.Services2.WebServicesExtension.AfterSerializeServer(SoapServerMessage message)
Above exception is thrown whenever i try to access any method of webservice on another machine.
Regards, Muhammad Waqas
Upvotes: 1
Views: 341
Reputation: 124
Muhammad, Could you please give us some more specifics? Are you saying that whenever you access any web service that is not located on your machine you get this error? Or are you saying that you have a web service on your machhine that you cannot access from another machine? Also, how are you hosting this web service? IIS, Apache, your own soon-to-be-released replacement for all web servers everywhere?? And, as John Saunders said before, where in the code is the exception coming from?
From what you've written, my first hunch is a permissions issue, but some more details would greatly help.
Upvotes: 0
Reputation: 22597
After serialize event takes place when the SOAP payload is successfully serialized from the client.
I am guessing there might be some issue with the web service method rather than your code.
Upvotes: 0
Reputation: 161821
Muhammad, I don't know what's causing your problem because you didn't show us the area of code where the exception comes from in your code.
However, it's clear that you are using WSE2. Were you aware that WSE2 is very obsolete? You should not use WSE at all unless you have no choices at all.
You should use WCF for all web services work; certainly for all new web services work.
Upvotes: 1