We have an application which dynamically loads an assembly and creates
instances of classes. For this we have written a factory class which
reflects the assembly and creates the classes and returns the created
objects as plain objects. The caller method casts the object returned
by the object factory into appropriate class object and uses it.

All this works fine when exe is invoked directly. But when the
application is deployed on the IIS for no touch deployment, the casting

of the object returned by the object factory is throwing an invalid
cast exception. Strange thing is that the statement that is causing
exception during run time works fine if executed in the Immediate
window of the VS.Net IDE.


How do I fix it?

Re: Problem with no touch deployment of application which has dynamically loaded assemblies by Vijay

Vijay
Wed May 10 22:19:28 CDT 2006

Ravi you might have checked. but I am just throwing it out there... IDE
works in Debug mode.. are you deploying in same Debug mode..or Release
mode.. any difference in the 2 modes.?

VJ

"Ravi" <ravichandra.thalluri@gmail.com> wrote in message
news:1147258622.442178.96850@j73g2000cwa.googlegroups.com...
> We have an application which dynamically loads an assembly and creates
> instances of classes. For this we have written a factory class which
> reflects the assembly and creates the classes and returns the created
> objects as plain objects. The caller method casts the object returned
> by the object factory into appropriate class object and uses it.
>
> All this works fine when exe is invoked directly. But when the
> application is deployed on the IIS for no touch deployment, the casting
>
> of the object returned by the object factory is throwing an invalid
> cast exception. Strange thing is that the statement that is causing
> exception during run time works fine if executed in the Immediate
> window of the VS.Net IDE.
>
>
> How do I fix it?
>



Re: Problem with no touch deployment of application which has dynamically loaded assemblies by Ravi

Ravi
Fri May 12 02:04:29 CDT 2006

We tested by deploying both Release Mode and Debug mode dlls. Both have
the same issue. I used the debug DLLs for identifying where the problem
is.