home *** CD-ROM | disk | FTP | other *** search
/ CD Actual Thematic 7: Programming / CDAT7.iso / demos / VB_CCE / VB5CCEIN.EXE / test.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1997-02-14  |  3.9 KB  |  126 lines

  1. VERSION 5.00
  2. Object = "*\AAXLstpik.vbp"
  3. Begin VB.Form Test 
  4.    Caption         =   "Form1"
  5.    ClientHeight    =   3870
  6.    ClientLeft      =   4320
  7.    ClientTop       =   3285
  8.    ClientWidth     =   6090
  9.    LinkTopic       =   "Form1"
  10.    LockControls    =   -1  'True
  11.    ScaleHeight     =   3870
  12.    ScaleWidth      =   6090
  13.    Begin VB.CommandButton cmdAdd 
  14.       Caption         =   "Add Destination Item"
  15.       Height          =   465
  16.       Index           =   1
  17.       Left            =   3135
  18.       TabIndex        =   2
  19.       Top             =   2040
  20.       Width           =   2160
  21.    End
  22.    Begin VB.CommandButton cmdAdd 
  23.       Caption         =   "Add Source Item"
  24.       Height          =   465
  25.       Index           =   0
  26.       Left            =   210
  27.       TabIndex        =   1
  28.       Top             =   2040
  29.       Width           =   2160
  30.    End
  31.    Begin VB.CommandButton cmdClearAll 
  32.       Caption         =   "Clear All"
  33.       Height          =   480
  34.       Left            =   210
  35.       TabIndex        =   5
  36.       Top             =   3240
  37.       Width           =   2160
  38.    End
  39.    Begin VB.CommandButton cmdShowAll 
  40.       Caption         =   "Show All Items Picked"
  41.       Height          =   480
  42.       Left            =   3135
  43.       TabIndex        =   6
  44.       Top             =   3210
  45.       Width           =   2160
  46.    End
  47.    Begin VB.CommandButton cmdCurrent 
  48.       Caption         =   "Show Current Dest. Item"
  49.       Height          =   465
  50.       Index           =   1
  51.       Left            =   3135
  52.       TabIndex        =   4
  53.       Top             =   2640
  54.       Width           =   2160
  55.    End
  56.    Begin VB.CommandButton cmdCurrent 
  57.       Caption         =   "Show Current Source Item"
  58.       Height          =   465
  59.       Index           =   0
  60.       Left            =   210
  61.       TabIndex        =   3
  62.       Top             =   2640
  63.       Width           =   2160
  64.    End
  65.    Begin AXLstPik.AXListPicker AXListPicker1 
  66.       Height          =   1785
  67.       Left            =   120
  68.       TabIndex        =   0
  69.       Top             =   195
  70.       Width           =   5820
  71.       _ExtentX        =   10266
  72.       _ExtentY        =   3149
  73.       SourceCaption   =   "&Source:"
  74.       DestinationCaption=   "&Destination:"
  75.       SourceSortType  =   1
  76.       DestinationSortType=   2
  77.    End
  78. Attribute VB_Name = "Test"
  79. Attribute VB_GlobalNameSpace = False
  80. Attribute VB_Creatable = False
  81. Attribute VB_PredeclaredId = True
  82. Attribute VB_Exposed = False
  83. Private Sub AXListPicker1_MoveToDestination(Cancel As Boolean, Count As Integer)
  84.   MsgBox "Moving " & Count & " items to the Destination!"
  85. End Sub
  86. Private Sub AXListPicker1_MoveToSource(Cancel As Boolean, Count As Integer)
  87.   MsgBox "Moving " & Count & " items to the Source!"
  88. End Sub
  89. Private Sub cmdAdd_Click(Index As Integer)
  90.   Dim sTmp As String
  91.   sTmp = InputBox("Add Item:")
  92.   If Len(sTmp) = 0 Then Exit Sub
  93.   If Index = 0 Then
  94.     AXListPicker1.AddItem sTmp, lspSource
  95.   Else
  96.     AXListPicker1.AddItem sTmp, lspDesintation
  97.   End If
  98. End Sub
  99. Private Sub cmdClearAll_Click()
  100.   AXListPicker1.ClearAll
  101. End Sub
  102. Private Sub cmdCurrent_Click(Index As Integer)
  103.   If Index = 0 Then
  104.     If AXListPicker1.SourceListIndex < 0 Then Exit Sub
  105.     MsgBox AXListPicker1.SourceList(AXListPicker1.SourceListIndex)
  106.   Else
  107.     If AXListPicker1.DestinationListIndex < 0 Then Exit Sub
  108.     MsgBox AXListPicker1.DestinationList(AXListPicker1.DestinationListIndex)
  109.   End If
  110. End Sub
  111. Private Sub cmdShowAll_Click()
  112.   Dim sTmp As String
  113.   Dim i As Integer
  114.   For i = 0 To AXListPicker1.ListCount(lspDesintation) - 1
  115.     sTmp = sTmp & ":" & AXListPicker1.DestinationList(i)
  116.   Next
  117.   MsgBox sTmp
  118. End Sub
  119. Private Sub Form_Load()
  120.   AXListPicker1.AddItem "AAA", lspSourceList
  121.   AXListPicker1.AddItem "BBB", lspSourceList
  122.   AXListPicker1.AddItem "DDD", lspSourceList
  123.   AXListPicker1.AddItem "CCC", lspSourceList
  124.   AXListPicker1.AddItem "ABC", lspSourceList
  125. End Sub
  126.