I have a SQL table with a list of forms (frmForm1, frmForm2)

i have a listbox that fills from this table and i would like it to call the form in the 'FormToCall' Column


How can i call a form if i only know the form name at runtime?

i didn't understand what your saying here?

Try declaring an object for the form2 and call it at runtime..

I have found the solution

Dim assem As Reflection.Assembly = Me.GetType.Assembly
Dim frm As Form = assem.CreateInstance(assem.GetName.Name & ".frmMaint")
frm.Show()

Thanks

commented: Good :) +3
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.