-
Notifications
You must be signed in to change notification settings - Fork 2
/
Form1.frm
93 lines (87 loc) · 2.67 KB
/
Form1.frm
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
VERSION 5.00
Begin VB.Form Form1
BorderStyle = 1 'Fixed Single
Caption = "ucDriveCombo Test Form"
ClientHeight = 3915
ClientLeft = 45
ClientTop = 390
ClientWidth = 4350
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 3915
ScaleWidth = 4350
StartUpPosition = 3 'Windows Default
Begin VB.CommandButton Command4
Caption = "Show Path (legacy)"
Height = 615
Left = 1200
TabIndex = 5
Top = 1440
Width = 1935
End
Begin VB.CommandButton Command3
Caption = "Refresh List"
Height = 615
Left = 1200
TabIndex = 4
Top = 3240
Width = 1935
End
Begin VB.CommandButton Command2
Caption = "Set Selection"
Height = 615
Left = 1200
TabIndex = 3
Top = 2520
Width = 1935
End
Begin VB.TextBox Text1
Height = 285
Left = 1920
MaxLength = 1
TabIndex = 2
Text = "D"
Top = 2160
Width = 375
End
Begin ucDriveComboTest.ucDriveCombo ucDriveCombo1
Height = 360
Left = 360
TabIndex = 1
Top = 240
Width = 3735
_ExtentX = 6588
_ExtentY = 556
ComboStyle = 1
End
Begin VB.CommandButton Command1
Caption = "Show Path"
Height = 615
Left = 1200
TabIndex = 0
Top = 720
Width = 1935
End
End
Attribute VB_Name = "Form1"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Private Sub Command1_Click()
MsgBox "Current selection: " & ucDriveCombo1.SelectedDriveName
End Sub
Private Sub Command2_Click()
ucDriveCombo1.SelectedDriveLetter = Text1.Text
End Sub
Private Sub Command3_Click()
ucDriveCombo1.RefreshDriveList
End Sub
Private Sub Command4_Click()
MsgBox ucDriveCombo1.Drive
End Sub
Private Sub ucDriveCombo1_SelectionChanged(ByVal NewPath As String, ByVal NewLetter As String, ByVal NewName As String, ByVal NewDriveType As Long)
Debug.Print "Selected drive changed to " & NewPath
End Sub