Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

create instance of form from string name

Status
Not open for further replies.

eward1

Programmer
Feb 24, 2003
18
US
I have a lot of forms in my project, and several programmers working on it. I have one form which lists all the forms in the project. (I read the .vbproj file and parse the .resx file names.)
What I am looking for is code that will let me create an instance of the form from the string name that I have, something like:

dim strName as string
dim f as form
strName = "frmMyForm"
f = new ctype(form, strName)

of course this doesn't work because ctype can't convert a string to a form, but this shows what I am attempting.
Can someone show me how to do it right?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top