G
Guest
Hi
I have a class in the App_Code location of my web project.
example:
namespace Company.AppName.Objects {
public class ObjectA {
public ObjectA(){
}
public void DoSomething() {
}
}
}
In a web page I want to dynamically get the type of this class like so:
Type t = Type.GetType("Company.AppName.Objects.ObjectA");
However this code will return a null null object, due to the compilation
model of ASP.NET 2, it basically can't find the dll to load the type.
ASP.NET 1.x didn't have this problem because the code-behind was represented
in a single dll.
Apart from say putting ObjectA into it's own project thus dll, does anyone
know of a way around this?
Craig
I have a class in the App_Code location of my web project.
example:
namespace Company.AppName.Objects {
public class ObjectA {
public ObjectA(){
}
public void DoSomething() {
}
}
}
In a web page I want to dynamically get the type of this class like so:
Type t = Type.GetType("Company.AppName.Objects.ObjectA");
However this code will return a null null object, due to the compilation
model of ASP.NET 2, it basically can't find the dll to load the type.
ASP.NET 1.x didn't have this problem because the code-behind was represented
in a single dll.
Apart from say putting ObjectA into it's own project thus dll, does anyone
know of a way around this?
Craig