Create object from dll name

me_tvm

New member
Joined
Jun 20, 2007
Messages
2
Programming Experience
Beginner
Hi,
I am developing an application which shd create an object with dll name
Can anyone tell me how to create a class object by passsing the dllname as string? I dont need to use reflection for tht? Any alternative..
Its very urgent plz do help me..

Thanks in advance
 
Yes, to create an object from only the name of the class you use Reflection.

or perhaps use If/SelectCase:
VB.NET:
        Dim toCreate As String = "objectA"
        Dim o As Object
        Select Case toCreate
            Case "objectA"
                o = New objectA
            Case "objectB"
                o = New objectB
        End Select
 
Back
Top