That's what I needed. Thanks
On Apr 27, 12:04 pm, Cerebrus <[email protected]> wrote: > I elaborated on GetType in this thread (and the one it links to) : > > http://groups.google.com/group/DotNetDevelopment/browse_thread/thread... > > On Apr 27, 9:36 pm, Joe Enos <[email protected]> wrote: > > > When it's in a different assembly, I believe you'll need to specify it > > with a comma, space, then the assembly name like the following: > > > Type.GetType("MyNamespace.MyClassName, MyAssembly") > > > I'm not 100% sure, but I think that will work. > > > On Apr 27, 7:50 am, jtaylor <[email protected]> wrote: > > > > That seems to be what I need, but I'm having issues with the > > > Type.GetType. It works fine if the Type is defined within my project > > > but not if it is contained in a DLL reference. When specifying a Type > > > out of a DLL, the Type.GetType returns a null. The reference itself > > > is working, since I can hard-code the Dim statement. My best guess is > > > that I'm not specifying the parameter properly on the Type.GetType, > > > but I can't seem to figure it out. > > > > On Apr 18, 12:59 am, Joe Enos <[email protected]> wrote: > > > > > You'll need to do a little more than just "Double", but I think what > > > > you're looking for is Activator.CreateInstance. It accepts a full > > > > type name, or a Type variable, and instantiates an object of that > > > > type. > > > > > You can convert a fully qualified type name to a type of Type by using > > > > the Type.GetType method. > > > > > On Apr 17, 1:11 pm, jtaylor <[email protected]> wrote: > > > > > > I don't think it's possible, but is there any way to use a variable as > > > > > a type in a Dim statement? > > > > > > For example: > > > > > > Dim Field1 as String = "Double" > > > > > Dim Field2 as Field1- Hide quoted text - > > > - Show quoted text -
