W
Will
Hello,
I have an ASP.Net 1.1 web service running on a Win2K Server machine
under IIS 5.0.
Within the web service project, I have a class whose only purpose is to
define the interface to an unamanged DLL. I use the DllImport attribute
and all of the class's functions are declared public static extern.
Intermittently I am seeing an error on the call to unmanaged DLL. The
web service catchaes a NullReferenceException: "Object not set to an
instance of an object" and the web service becomes unresponsive at that
point - so much so that I am forced to restart the ASP.NET worker
process on the web server. The stack trace of the exception points back
to a call to the unamanged DLL by a web method of the web service,
which looks pretty much like this:
MyAPIClass.UnmanagedFunctionCall();
Why is it complaining that there is a null reference exception when the
line of code that is throwing it involves a static function call?
Also, restarting the ASP.NET worker process is not something I want to
continue doing. Right now, the only way I know how to do it is by
killing the process using task manager. Is there a way I can automate
this using perhaps a setting in web.config, machine.config, or
programatically?
Thanks for any help or suggestions,
Will.
I have an ASP.Net 1.1 web service running on a Win2K Server machine
under IIS 5.0.
Within the web service project, I have a class whose only purpose is to
define the interface to an unamanged DLL. I use the DllImport attribute
and all of the class's functions are declared public static extern.
Intermittently I am seeing an error on the call to unmanaged DLL. The
web service catchaes a NullReferenceException: "Object not set to an
instance of an object" and the web service becomes unresponsive at that
point - so much so that I am forced to restart the ASP.NET worker
process on the web server. The stack trace of the exception points back
to a call to the unamanged DLL by a web method of the web service,
which looks pretty much like this:
MyAPIClass.UnmanagedFunctionCall();
Why is it complaining that there is a null reference exception when the
line of code that is throwing it involves a static function call?
Also, restarting the ASP.NET worker process is not something I want to
continue doing. Right now, the only way I know how to do it is by
killing the process using task manager. Is there a way I can automate
this using perhaps a setting in web.config, machine.config, or
programatically?
Thanks for any help or suggestions,
Will.