home *** CD-ROM | disk | FTP | other *** search
- VERSION 2.00
- Begin Form PathFrm
- Caption = "Add Network Path"
- ClientHeight = 3120
- ClientLeft = 105
- ClientTop = 675
- ClientWidth = 7365
- Height = 3525
- Left = 45
- LinkMode = 1 'Source
- LinkTopic = "Form1"
- ScaleHeight = 3120
- ScaleWidth = 7365
- Top = 330
- Width = 7485
- Begin CommandButton Command2
- Caption = "Abort"
- Height = 495
- Left = 1950
- TabIndex = 2
- Top = 2460
- Width = 1215
- End
- Begin CommandButton Command1
- Caption = "OK"
- Height = 495
- Left = 330
- TabIndex = 1
- Top = 2460
- Width = 1215
- End
- Begin ListBox List1
- Height = 1005
- Left = 2070
- TabIndex = 3
- Top = 1140
- Width = 825
- End
- Begin TextBox Text1
- Height = 315
- Left = 2070
- TabIndex = 0
- Top = 420
- Width = 4935
- End
- DefInt A-Z
- Sub Command1_Click ()
- Abort% = False
- If PathFrm.List1.ListIndex = -1 Then
- Txt$ = "You must first select a drive!"
- MsgBox Txt$, 32, "Must Pick a Drive"
- Exit Sub
- End If
- If Text1.Text = "" Then
- Txt$ = "You must at least give the volume "
- Txt$ = Txt$ + "label, as in SYS:"
- MsgBox Txt$, 32, "Must Enter Text"
- Exit Sub
- End If
- TmpDrive$ = PathFrm.List1.List(List1.ListIndex)
- Map_Drv.Hidden1.Text = TmpDrive$
- Map_Drv.Hidden2.Text = Text1.Text
- Unload PathFrm
- End Sub
- Sub Command2_Click ()
- Abort% = True
- Unload PathFrm
- End Sub
- Sub Form_Load ()
- ' Load only the drives that aren't mapped yet!
- For i% = 1 To 26
- If Len(ArrayUnMap$(i%)) > 0 Then
- PathFrm.List1.AddItem ArrayUnMap$(i%)
- End If
- Next i%
- End Sub
- Sub Form_Paint ()
- TmpTxt$ = "Please enter the path: "
- PathFrm.CurrentX = PathFrm.Text1.Left - TextWidth(TmpTxt$)
- PathFrm.CurrentY = PathFrm.Text1.Top + 20
- PathFrm.Print TmpTxt$
- TmpTxt$ = "Please Pick a drive: "
- PathFrm.CurrentX = PathFrm.List1.Left - TextWidth(TmpTxt$)
- PathFrm.CurrentY = PathFrm.List1.Top + 20
- PathFrm.Print TmpTxt$
- End Sub
-