Using this command we can create the menus in our form as well as can work dynamically.
Creating menu process:-
1. go to tools menu.(ctrl+E).
2. click on menu editor.
a. Right click on form.
b. Click on menu editor.
The menu editor’s options:-
Caption:-write the menu’s caption.
Name:-write down the name of menu that should be unique.
Shortcut:-Through this we can set the shortcut key for menu.
Checked:-If you check on it display the check sign in menu.
Arrows:-Used to create the sub menu in the main and move up and down.
Next:-create new after the existing menu.
Insert :-create new.
Delete:-To delete the created menu.
Creating line in the Sub menu:-
Write das in Caption( -) and name as well as move one arrow inside.
Write down the ampersand(&) before the letters of menu.
Creating shortcut keys:-
Choose the shortcut key for the sub menu as far as possible you need to choose the shortcut key for useable ,the useable shortcut key.Like to create the shortcut key for open ctrl+o.
Writing code in menu:-
After creating the menu in the design view using menu editor use the following ways to write the code in the menu editor:-
a. click on menu in the design time,that creates the event procedure in code.
b. Write down the code according to the menu purposes.
Example of some menu codes:-
Private Sub mnuclose_Click()
Private Sub mnuexit_Click()
Private Sub mnufontname_Click()
cd.Flags = cdlCFBoth
rt.SelFontName = cd.FontName
Private Sub mnufontsize_Click ()
cd.Flags = cdlCFBoth
rt.SelFontSize = cd.FontSize
Private Sub mnuforecolor_Click()
rt.SelColor = cd.Color
Private Sub mnuopen_Click ()
On Error GoTo pp:
fn = cd.FileName
Private Sub mnusave_Click ()
FN = cd.FileName
Microsoft windows common control 5.0 (sp2):-
It is the complex control used to provide the many graphical effects with many advanced controls. There are many controls in the MWCC 5.0 like progress bar,status bar,toolbar ,etc.
It is one of the member of MWCC 5.0 ,used to display the processing of the programme.
Without the timer the progress bar has no use. So that we need the timer together with the progress bar.
1. go to component.
2. Check on the Microsoft windows common control 5.0(sp2).
3. Click on apply and close.
4. It is on the tool bar ,draw the progress bar.
The properties of the Progress bar:-
Min:-It is the starting point of the progressbar the default value of the progress bar is Zero(0).
Max:-It is the ending point of the progress bar.The default value of pbr’s max is 100.
Alignment:-There are four alignment using these we can set the progress bar in the particular location.
Value:-It is also the important property used to specify the how much of the progress bar making visible.
Private Sub Form_Load()
tmrpbr.Interval = 100
Private Sub tmrpbr_Timer()
pbr.Value = pbr.Value + 1
If pbr.Value >= 100 Then
‘pbr.Value = 0
pbr.Enabled = False