i have an MDI application, which reads child forms from seperated form classes, each built into their own dll which i just reference.
I now want to make this more dynamic by having an XML file which will determine the sequence / flow of the forms to be opened, and thus a SUB which will take the reference to the project and its formname and open the form within the MDI parent window.
eg.
<forms>
<form id=1>
<formname>frmAbout</formname>
<projref>About</projref>
<cls>about.ddl</cls>
</form>
<form id=2>
<formname>frmLegal</formname>
<projref>Legal</projref>
<cls>legal.ddl</cls>
</form>
<form id=3>
<formname>frmForm1</formname>
<projref>Form1</projref>
<cls>form1.ddl</cls>
</form>
<form id=4>
<formname>frmForm2</formname>
<projref>Form2</projref>
<cls>form2.ddl</cls>
</form>
</forms>
Public Sub OpenChildForm(ByVal id as Integer)
'' Determine class name, dll, and project reference
***** THIS IS WHERE I GET STUCK
***** HOWTO REFERENCE A CLASS BY A STRING VALUE ???
Dim ChildForm As New projref.formname '*** derived from XML
ChildForm.MdiParent = Me
ChildForm.Show()
End Sub
>
:O> wASP >
:O>
I now want to make this more dynamic by having an XML file which will determine the sequence / flow of the forms to be opened, and thus a SUB which will take the reference to the project and its formname and open the form within the MDI parent window.
eg.
<forms>
<form id=1>
<formname>frmAbout</formname>
<projref>About</projref>
<cls>about.ddl</cls>
</form>
<form id=2>
<formname>frmLegal</formname>
<projref>Legal</projref>
<cls>legal.ddl</cls>
</form>
<form id=3>
<formname>frmForm1</formname>
<projref>Form1</projref>
<cls>form1.ddl</cls>
</form>
<form id=4>
<formname>frmForm2</formname>
<projref>Form2</projref>
<cls>form2.ddl</cls>
</form>
</forms>
Public Sub OpenChildForm(ByVal id as Integer)
'' Determine class name, dll, and project reference
***** THIS IS WHERE I GET STUCK
***** HOWTO REFERENCE A CLASS BY A STRING VALUE ???
Dim ChildForm As New projref.formname '*** derived from XML
ChildForm.MdiParent = Me
ChildForm.Show()
End Sub
>