home *** CD-ROM | disk | FTP | other *** search
- VERSION 4.00
- Begin VB.Form Form1
- Caption = "Form1"
- ClientHeight = 5415
- ClientLeft = 1095
- ClientTop = 1515
- ClientWidth = 5280
- Height = 5820
- Left = 1035
- LinkTopic = "Form1"
- ScaleHeight = 5415
- ScaleWidth = 5280
- Top = 1170
- Width = 5400
- Begin VB.CommandButton Command4
- Caption = "Delete All"
- Height = 375
- Left = 960
- TabIndex = 11
- Top = 1440
- Width = 1455
- End
- Begin VB.CommandButton Command2
- Caption = "Delete Selected"
- Height = 375
- Left = 2640
- TabIndex = 8
- Top = 1440
- Width = 1455
- End
- Begin VB.TextBox Text4
- Height = 285
- Left = 3360
- TabIndex = 6
- Text = "Text4"
- Top = 4800
- Width = 735
- End
- Begin VB.TextBox Text3
- Height = 285
- Left = 3360
- TabIndex = 4
- Text = "Text3"
- Top = 4320
- Width = 735
- End
- Begin VB.CheckBox Check1
- Caption = "IsChecked"
- Height = 255
- Left = 960
- TabIndex = 3
- Top = 4320
- Width = 1095
- End
- Begin VB.TextBox Text2
- Height = 285
- Left = 960
- TabIndex = 9
- Text = "Text2"
- Top = 3840
- Width = 3135
- End
- Begin VB.CommandButton Command3
- Caption = "Add Text && Check"
- Height = 375
- Left = 2640
- TabIndex = 2
- Top = 960
- Width = 1455
- End
- Begin VB.CommandButton Command1
- Caption = "Add Text"
- Height = 375
- Left = 960
- TabIndex = 1
- Top = 960
- Width = 1455
- End
- Begin VB.TextBox Text1
- Height = 285
- Left = 960
- TabIndex = 0
- Text = "Another Line of text"
- Top = 600
- Width = 3135
- End
- Begin CHKLISTLib.ChkList ChkList1
- Height = 1335
- Left = 990
- TabIndex = 10
- Top = 2055
- Width = 3135
- _Version = 65536
- _ExtentX = 5530
- _ExtentY = 2355
- _StockProps = 13
- End
- Begin VB.Frame Frame1
- Caption = "When Selection Changes"
- Height = 1575
- Left = 720
- TabIndex = 12
- Top = 3600
- Width = 3615
- End
- Begin VB.Label Label3
- Caption = "Index"
- Height = 255
- Left = 2640
- TabIndex = 7
- Top = 4800
- Width = 615
- End
- Begin VB.Label Label2
- Caption = "Count"
- Height = 255
- Left = 2640
- TabIndex = 5
- Top = 4320
- Width = 615
- End
- Attribute VB_Name = "Form1"
- Attribute VB_Creatable = False
- Attribute VB_Exposed = False
- Private Sub ChkList1_SelectionChanged(ByVal Index As Integer)
- Text2.Text = ChkList1.GetString(Index)
- Text3.Text = ChkList1.GetCount
- Text4.Text = Index
- If ChkList1.IsChecked(Index) = True Then
- Check1.Value = 1
- Check1.Value = 0
- End If
- End Sub
- Private Sub Command1_Click()
- ChkList1.AddString (Text1.Text)
- End Sub
- Private Sub Command2_Click()
- Index = ChkList1.GetCurSel
- If Index > -1 Then
- ChkList1.DeleteItem (Index)
- End If
- End Sub
- Private Sub Command3_Click()
- ChkList1.AddStringCheck Text1.Text, True
- End Sub
- Private Sub Command4_Click()
- ChkList1.Clear
- End Sub
- Private Sub Command5_Click()
- n = 0
- n = ChkList1.FindString(Text1.Text)
- If n > -1 Then
- MsgBox (n)
- End If
- End Sub
- Private Sub Form_Load()
- For i = 0 To 20
- If i Mod 2 = 0 Then
- ChkList1.AddString "Test Line " + Chr(85 - i)
- Else
- ChkList1.AddStringCheck "Test Line " + Chr(85 - i), True
- End If
- Next i
- End Sub
-