SETHA SITE INFORMATION

  • Increase font size
  • Default font size
  • Decrease font size

How to Create MDI Form and Menu Bar in Visual Basic 2008

E-mail Print PDF

This article shows you how to create MDI Form with Menu Bar in Microsoft Visual Basic 2008. From this article, you will know:

  • How to create MDI Form?
  • How to create Menu Bar?
  • How to click on each menu item to open child form in MDI form?

  1. Create MDI Form
    Create New Form (Project Menu -> Add New Item -> Windows Form)
    Change Properties of Form as below
    • WindowState: Maximized
    • isMdiContainer: True
  2. Create Menu Bar
    Drag MenuStrip Control to MDI Form
    Add Menu Item and Sub Menu Item (See in Video Below)
  3. Write Code
    Click on Menu Item to show Form in MDI Form (see example below)
            frmStudent.MdiParent = Me
            frmStudent.Show()
    

See video below