home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Visual Basic Programmer'…arterly (Limited Edition)
/
Visual_Basic_Programmers_Journal_VB-CD_Quarterly_Limited_Edition_1995.iso
/
code
/
ch19code
/
mdiwin.frm
< prev
next >
Wrap
Text File
|
1995-08-14
|
2KB
|
77 lines
VERSION 4.00
Begin VB.MDIForm mdiApplication
BackColor = &H8000000C&
Caption = "MDIForm1"
ClientHeight = 4236
ClientLeft = 1008
ClientTop = 1980
ClientWidth = 6720
Height = 4788
Left = 960
LinkTopic = "frmContainer"
Top = 1476
Width = 6816
Begin VB.Menu mnuWindow
Caption = "&Window"
WindowList = -1 'True
Begin VB.Menu mnuAdd
Caption = "&Add"
End
Begin VB.Menu mnuDelete
Caption = "&Delete"
End
Begin VB.Menu mnuArrange
Caption = "A&rrange"
End
Begin VB.Menu sep
Caption = "-"
End
Begin VB.Menu mnuDialog
Caption = "&New Dialog"
End
End
End
Attribute VB_Name = "mdiApplication"
Attribute VB_Creatable = False
Attribute VB_Exposed = False
Option Explicit
Private Sub MDIForm_Unload(Cancel As Integer)
' You need to explicitly end here, or
' application will not end during debugging.
End
End Sub
Private Sub mnuAdd_Click()
Dim Window As New Window
Window.Create
End Sub
Private Sub smnuAdd_Click()
Windows.Add
End Sub
Private Sub mnuArrange_Click()
Windows.Arrange 1
End Sub
Private Sub mnuDelete_Click()
Windows.Remove Application.ActiveWindow.Index
End Sub
Private Sub mnuDialog_Click()
Dim dlgNew As New Dialog
' If there's no active window.
If TypeName(Application.ActiveWindow) = "Nothing" Then
' Add a window.
mnuAdd_Click
End If
' Create a child window (dialog).
dlgNew.Create Application.ActiveWindow
End Sub