In a new WindowsForm project with default settings I wrote a loop:
For Each frm In My.Application. OpenForms
If frm.Name <"MDIMain" Then
frm.Close()
End If
Next
Everything was fine until I decided to use Sub Main as Startup object. In
order to have it in the list of startup objects I had to uncheck Enable
application framework. Since that I have My.Application. OpenForms
highlighted and IDE says 'OpenForms is not a member of
'CMS.My.MyAppli cation'
How can I have OpenForms collection in my project if I use Sub Main as
Startup object?
Thank you
vovan
For Each frm In My.Application. OpenForms
If frm.Name <"MDIMain" Then
frm.Close()
End If
Next
Everything was fine until I decided to use Sub Main as Startup object. In
order to have it in the list of startup objects I had to uncheck Enable
application framework. Since that I have My.Application. OpenForms
highlighted and IDE says 'OpenForms is not a member of
'CMS.My.MyAppli cation'
How can I have OpenForms collection in my project if I use Sub Main as
Startup object?
Thank you
vovan
Comment