0% found this document useful (0 votes)
85 views25 pages

CCP503

This document provides instructions for creating MDI (Multiple Document Interface) applications in Visual Basic. It begins with an overview of MDI applications and their features, such as allowing multiple documents to be viewed at once. It then outlines the steps to create an MDI parent form using the "Add MDI Form" option and to create MDI child forms by setting the form's "MDIChild" property to True. Sample code is provided to load a child form from the parent form. Screenshots illustrate the process. Key points are recapped and an objective quiz is included.

Uploaded by

api-3849444
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
85 views25 pages

CCP503

This document provides instructions for creating MDI (Multiple Document Interface) applications in Visual Basic. It begins with an overview of MDI applications and their features, such as allowing multiple documents to be viewed at once. It then outlines the steps to create an MDI parent form using the "Add MDI Form" option and to create MDI child forms by setting the form's "MDIChild" property to True. Sample code is provided to load a child form from the parent form. Screenshots illustrate the process. Key points are recapped and an objective quiz is included.

Uploaded by

api-3849444
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 25

DEPARTMENT OF TECHNICAL EDUCATION

ANDHRA PRADESH
Name of the Faculty : NAND KISHORE SINGH
Designation : LECTURER
Branch : DCCP
Institute : SGMGPT, Abdullapurmet
Year/Semester : V
Subject : VISUAL BASIC-I
Subject Code : CCP-503
Topic : MDI Applications and
Graphics
Duration : 50 Minutes
Sub-Topic : Creation of MDI Applications
Teaching Aids : PPT, Animations and
Photographs

CCP-503.44 1
Recap
 Parent Form is container for Child Forms
 Menus & Buttons only appear on Parent
Form
 Menus of selected Child forms appear on
Parent form
 Only one form can be active at a time
 MDI Form closes all Child Forms

CCP-503.44 2
Objectives
On completion of this period, you would be
able to know:

 Features of MDI Applications

 Creation of MDI Applications

 Creation of MDI Parent Form

 Creation of MDI Child Forms

CCP-503.44 3
MDI Applications
Features :
 MDI applications allow to display
multiple documents at the same time,
 It often has a Window menu item with
submenus for switching between
windows or documents.
 MDI Applications consists of two parts,
 MDI parent form and MDI child form

CCP-503.44 4
MDI Applications
Features :

 MDI applications can have one


MDI parent form
 MDI parent form can have
multiple MDI child forms.
 MDI parent form is the form that
contains all the MDI child forms

CCP-503.44 5
MDI Applications
Features :

 The MDI child forms are displayed


as independent windows under an
MDI parent window.
 A user interacts with an MDI application
by using the MDI child windows and the
MDI parent window.

CCP-503.44 6
Sample MDI Application

Fig.4.1
CCP-503.44 7
Steps to Create MDI Application

 The foundation of an MDI Application is the


MDI parent form
 Creating an MDI parent form is easy

CCP-503.44 8
Steps to create MDI Parent Form

Choose Add MDI Form option from the

Project menu

CCP-503.44 9
Step-1
Project → Add MDI Form

Fig.4.2

CCP-503.44 10
Step-2
Select “MDI Form” and click “Open”

Fig.4.3

CCP-503.44 11
Design view of MDI Parent Form

Fig.4.4

CCP-503.44 12
Note :
If a project already has an MDI form, the
“Add MDl Form” command on the
“Project menu” is unavailable. –

CCP-503.44 13
Steps to create MDI Child Form(s)

Select the “Add Form” option of the


“Project menu”
(or open an existing one) and
set its “MDIChild property” to
“True”

CCP-503.44 14
Step-1
Project Add Form

Fig.4.5
CCP-503.44 15
Step-2
Select Form and click Open

Fig.4.6 CCP-503.44 16
Step-3
Form is added to the Project

Fig.4.7
CCP-503.44 17
Step-4
Set Form1 MDIChild Property to True

Fig.4.8
CCP-503.44 18
Design view of MDI Child Form

Fig.4.9

CCP-503.44 19
 Visual Basic displays special icons in the
Project Explorer for the MDI Parent Form and
MDI child forms
 The MDI Parent Form requires a menu, which
helps us access the child forms

CCP-503.44 20
 In the MDI Window Code Menu type
the following code

Private Sub MDIForm_Load()


Load Form1
End Sub

 Now run the application

CCP-503.44 21
MDI Application At Run Time

Fig.4.10
CCP-503.44 22
Summary
 MDI Application consist of MDI Parent
Form and MDI Child Form(s)
 Add MDI Form for Parent form
 Add ordinary Form for Child form
 Set form’s MDI child property to True

CCP-503.44 23
Quiz
Objective Type

1. MDI Application consists of more than one


MDI Parent Form. (True/False)
Ans: False
2. MDI Child property should be set to FALSE.
(True/False)
Ans: False

CCP-503.44 24
Questions
1. Write the procedure to create MDI
Applications in Visual Basic.
2. Write the procedure to create MDI Parent
Form and MDI Child Form(s).

CCP-503.44 25

You might also like