For Each FRM As Form In Application.Ope nForms
MsgBox(FRM.Name )
Next
only getting open form name... i want all form name used in project
MsgBox(FRM.Name )
Next
only getting open form name... i want all form name used in project
Public Function GetForms(ByVal sender As Object) As List(Of Form)
Dim Forms As New List(Of Form)()
Dim formType As Type = Type.GetType("System.Windows.Forms.Form")
For Each t As Type In sender.GetType().Assembly.GetTypes()
If UCase(t.BaseType.ToString) = "SYSTEM.WINDOWS.FORMS.FORM" Then
Forms.Add(t.Name)
End If
Next
Return Forms
End Function
Public Function GetForms(ByVal sender As Object) As List(Of String)
Dim Forms As New List(Of String)()
For Each t As Type In sender.GetType().Assembly.GetTypes()
If t.BaseType.ToString().ToUpper() = "SYSTEM.WINDOWS.FORMS.FORM" Then
Forms.Add(t.Name)
End If
Next
Return Forms
End Function
Comment