home *** CD-ROM | disk | FTP | other *** search
- VERSION 5.00
- Begin VB.Form frmOLE
- Caption = "OLE Run-Time"
- ClientHeight = 4245
- ClientLeft = 60
- ClientTop = 345
- ClientWidth = 5880
- LinkTopic = "Form1"
- ScaleHeight = 4245
- ScaleWidth = 5880
- StartUpPosition = 3 'Windows Default
- Begin VB.CommandButton cmdClose
- Cancel = -1 'True
- Caption = "&Close"
- Height = 495
- Left = 0
- TabIndex = 2
- Top = 960
- Width = 1215
- End
- Begin VB.CommandButton cmdObjInfo
- Caption = "&Object Info..."
- Enabled = 0 'False
- Height = 495
- Left = 0
- TabIndex = 1
- Top = 480
- Width = 1215
- End
- Begin VB.CommandButton cmdInsObj
- Caption = "&Insert Object..."
- Default = -1 'True
- Height = 495
- Left = 0
- TabIndex = 0
- Top = 0
- Width = 1215
- End
- Begin VB.OLE oleDisplay
- Height = 4215
- Left = 1185
- TabIndex = 3
- Top = -135
- Width = 4575
- End
- Attribute VB_Name = "frmOLE"
- Attribute VB_GlobalNameSpace = False
- Attribute VB_Creatable = False
- Attribute VB_PredeclaredId = True
- Attribute VB_Exposed = False
- Option Explicit
- Private Sub cmdClose_Click()
- Dim Quit As String
- Quit = MsgBox("Are you sure you want to quit?", vbYesNo + vbQuestion)
- If Quit = vbYes Then
- End
- End If
- End Sub
- Private Sub cmdInsObj_Click()
- frmType.Show
- End Sub
- Private Sub cmdObjInfo_Click()
- Dim SourceText As String
- Dim TypeText As String
- Dim ItemText As String
- Dim MsgText As String
- SourceText = "The object's source file is " & oleDisplay.SourceDoc
- TypeText = "The type of object is " & oleDisplay.Class
- ItemText = "The selected item is " & oleDisplay.SourceItem
- MsgText = SourceText & vbCrLf & TypeText & vbCrLf & ItemText
- MsgBox MsgText, vbInformation, "Object Information"
- End Sub
-