System.Type objectType;
System.Object obj;
objectType = System.Type.GetType("Class Name Here");
/* note: if you don't qualify the class name properly
you get an undefined type here. */
obj = Activator.CreateInstance(objectType);
What is the difference between using the Activator class
and using AppDomain.CreateInstance method? The only
difference I can see is that the Activator class allows
you to create remote objects.
Are there any other differences?
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.