CSDN博客

img lzmtw

单击菜单只运行一个子窗体实例的简单方法

发表于2004/11/2 21:59:00  1650人阅读

    Private m_Form2 As Form2

 

    Private Sub Form2MenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Form2MenuItem.Click

        If m_Form2 Is Nothing OrElse m_Form2.IsDisposed Then

            m_Form2 = New Form2

            m_Form2.MdiParent = Me

            m_Form2.Show()

        Else

            m_Form2.Activate()

        End If

    End Sub

阅读全文
0 0

相关文章推荐

img
取 消
img