home *** CD-ROM | disk | FTP | other *** search
- VERSION 2.00
- Begin Form LInks
- BorderStyle = 3 'Fixed Double
- Caption = "Links"
- Height = 2685
- Left = 645
- LinkMode = 1 'Source
- LinkTopic = "Form2"
- MaxButton = 0 'False
- MinButton = 0 'False
- ScaleHeight = 2280
- ScaleWidth = 7695
- Top = 1590
- Width = 7815
- Begin CommandButton cmdOK
- Caption = "OK"
- Default = -1 'True
- Height = 495
- Left = 6120
- TabIndex = 1
- Top = 480
- Width = 1215
- End
- Begin CommandButton cmdCancel
- Cancel = -1 'True
- Caption = "Cancel"
- Height = 495
- Left = 6120
- TabIndex = 2
- Top = 1080
- Width = 1215
- End
- Begin Frame Frame1
- Caption = "Update"
- Height = 860
- Left = 240
- TabIndex = 3
- Top = 1280
- Width = 5535
- Begin OptionButton optUpdate
- Caption = "Automatic"
- Height = 495
- Index = 0
- Left = 120
- TabIndex = 4
- Top = 240
- Width = 1215
- End
- Begin OptionButton optUpdate
- Caption = "Frozen"
- Height = 495
- Index = 1
- Left = 1440
- TabIndex = 5
- Top = 240
- Width = 1095
- End
- Begin OptionButton optUpdate
- Caption = "Manual"
- Height = 495
- Index = 2
- Left = 2640
- TabIndex = 6
- Top = 240
- Width = 1095
- End
- End
- Begin Label Label1
- Caption = "Links:"
- Height = 255
- Left = 120
- TabIndex = 0
- Top = 120
- Width = 615
- End
- Begin Label lblLinkInfo
- BorderStyle = 1 'Fixed Single
- Height = 705
- Left = 240
- TabIndex = 7
- Top = 480
- Width = 5535
- End
- Sub cmdCancel_Click ()
- Unload Links
- End Sub
- Sub cmdOK_Click ()
- If optUpdate(0).Value = True Then
- 'Automatic
- frmMain.OleClient1.UpdateOptions = OLE_AUTOMATIC
- ElseIf optUpdate(1).Value = True Then
- 'Frozen
- frmMain.OleClient1.UpdateOptions = OLE_FROZEN
- ElseIf optUpdate(2).Value = True Then
- 'Manual
- frmMain.OleClient1.UpdateOptions = OLE_MANUAL
- End If
- Unload Links
- End Sub
- Sub Form_Load ()
- Dim LinkDisplay As String
- Screen.MousePointer = 11
- Select Case frmMain.OleClient1.UpdateOptions
- Case 0
- optUpdate(0).Value = True
- optstring$ = "Automatic"
- Case 1
- optUpdate(1).Value = True
- optstring$ = "Frozen"
- Case 2
- optUpdate(2).Value = True
- optstring$ = "Manual"
- End Select
- 'create string to display in links list box
- frmMain.OleClient1.ServerClass = frmMain.OleClient1.Class
- DisplayName$ = frmMain.OleClient1.ServerClassesDisplay(RegIndex)
- LinkDisplay = DisplayName$ + " - " + frmMain.OleClient1.SourceDoc + " - " + frmMain.OleClient1.SourceItem + " - " + optstring$
- 'display links string in lblLinkInfo
- lblLinkInfo.Caption = LinkDisplay
- Screen.MousePointer = 0
- End Sub
- Sub optUpdate_Click (Index As Integer)
- Dim LinkDisplay As String
- Select Case Index
- Case 0
- optUpdate(0).Value = True
- optstring$ = "Automatic"
- Case 1
- optUpdate(1).Value = True
- optstring$ = "Frozen"
- Case 2
- optUpdate(2).Value = True
- optstring$ = "Manual"
- End Select
- ' create string to display in links list box
- frmMain.OleClient1.ServerClass = frmMain.OleClient1.Class
- ' Get Display Name based on RegIndex, a global variable that stores
- ' the object's registration database index
- DisplayName$ = frmMain.OleClient1.ServerClassesDisplay(RegIndex)
- LinkDisplay = DisplayName$ + " - " + frmMain.OleClient1.SourceDoc + " - " + frmMain.OleClient1.SourceItem + " - " + optstring$
- ' display links string in lblLinkInfo
- lblLinkInfo.Caption = LinkDisplay
- End Sub
-