One of the basic components of most applications is a set of drop down Menus. Visual Basic offers a simple system to allow menus to be developed. However, code must be written for the Menu to do anything.
To create a menu, ensure that the form is open and active. Obviously, you need to know what menus you need. Use Tools .. Menu Editor. In this case, a menu to clear the drawing and to exit the program are required. To add keyboard equivalents, precede the key letter with a &. For example, use &Clear to make Clear on the menu.. Alt C will work as well as the mouse click.

The code for this should be obvious at this time. However, it is
shown:Sub MnuClear_Click () Picrture1.clsEnd Sub
Sum MnuExit_Click
() ExitEnd Sub
Add the menu to the graphics program from the previous section.
The Checked property on menus can be useful for indicating what the current selection is within the menu. Assume that the method Picture1.line -(X,Y), QBColor(drawcolor) is active and drawcolor is Red. Then the menu propery Checked would be set to True. MnuRed.Checked=True. (The rest would be set to false).
To setup the program on start, the Form_Load() event should be used.
Yous task is to write a fully functional programs to achieve one of the following tasks. You must be part of a team of three students. Each student must have a predefined task (such as making a menu system).
Author Mike Leishman
Last Modified 28 June 1998