O
OfurGørn
....it does not throw the exception in a C# form. The same code works
perfectly in C# forms application. It seems like the computer noes not let
ASPNET get into the ROT, where the object I want is. I have experienced with
changing users, impersonating and so on, but with no luck.
I test which user I am before the faulty code, with
WindowsIdentity.GetCurrent().Name
where I was the user ASPNET when I started, but now I am "myself" who,
incidentally am running the process I am trying to reach.
the exceptions are:
"System.NullReferenceException: Object reference not set to an instance of
an object", when I run a method from the object I am trying to load.
"System.Runtime.InteropServices.COMException (0x800401E3): Operation
unavailable at System.Runtime.InteropServices.Marshal.GetActiveObject(Guid&
rclsid, UInt32 reserved, Object& ppunk) at
System.Runtime.InteropServices.Marshal.GetActiveObject(String progID)", when
I try to access the external object itself with Marshal.GetActiveObject()
Like I typed before, exactly the same code works in the windows forms
version of C#, but with the web service this seems impossible.
This error is driving me mad !!! I have been trying to fix this but am
afraid that I've become so frustrated that I cannot see the solution now -
typically a simple solution....
________________________
Gunnar Gudmundsson
perfectly in C# forms application. It seems like the computer noes not let
ASPNET get into the ROT, where the object I want is. I have experienced with
changing users, impersonating and so on, but with no luck.
I test which user I am before the faulty code, with
WindowsIdentity.GetCurrent().Name
where I was the user ASPNET when I started, but now I am "myself" who,
incidentally am running the process I am trying to reach.
the exceptions are:
"System.NullReferenceException: Object reference not set to an instance of
an object", when I run a method from the object I am trying to load.
"System.Runtime.InteropServices.COMException (0x800401E3): Operation
unavailable at System.Runtime.InteropServices.Marshal.GetActiveObject(Guid&
rclsid, UInt32 reserved, Object& ppunk) at
System.Runtime.InteropServices.Marshal.GetActiveObject(String progID)", when
I try to access the external object itself with Marshal.GetActiveObject()
Like I typed before, exactly the same code works in the windows forms
version of C#, but with the web service this seems impossible.
This error is driving me mad !!! I have been trying to fix this but am
afraid that I've become so frustrated that I cannot see the solution now -
typically a simple solution....
________________________
Gunnar Gudmundsson