Is there a way to set an object to the new instance of a class by using the text name of the class?
I will have a library of classes, and depending on some other var
You might be able to do it with a collection class or object array. All the objects are in one array.
In your class have a .Name property and when you create an instance of it do this:
Dim CTest() as New CTest
For n = 1 to 10
Redim Preserve CTest(n)
CTest(n).Name = "CTest" & CStr(n)
Next l
Quick and dirty. The above example would return 10 CTest objects in a single object array. You could also ditch the .Name and just use CTest(n).