AutoCAD 3DMAX C语言 Pro/E UG JAVA编程 PHP编程 Maya动画 Matlab应用 Android
Photoshop Word Excel flash VB编程 VC编程 Coreldraw SolidWorks A Designer Unity3D
 首页 > VB编程

用ParamArray接收任意个参数

51自学网 http://www.wanshiok.com
Public Sub FillList(ListControl As ListBox, ParamArray Items())
Dim i As Variant
With ListControl
.Clear
For Each i In Items
.AddItem i
Next
End With
End Sub

Private Sub Command1_Click()
FillList List1, "TiffanyT", "MikeS", "RochesterNY"
End Sub

 

 

 
上一篇:在GotFocus时快速选择文本  下一篇:统计VB程序的运行时间