太高兴了,我用VFP做的带spinner控件的可复选列表框
按这个思路,可以在列表框里自由添加任何控件.首先将list的multiselect属性设为.t.
在list的click事件中这样写:
FOR i=1 TO this.ListCount
objname=ALLTRIM(this.List(i))
IF TYPE("thisform.&objname.") = "O"
thisform.removeobject(objname)
endif
IF this.Selected(i)
thisform.AddObject(objname,"spinner")
itemsize=thisform.list1.fontsize+8
WITH thisform.&objname.
.visible=.t.
.top=i*itemsize+thisform.list1.top-17
.width=40
.height=itemsize
.left=thisform.list1.Left+thisform.list1.Width-100
.value=1
ENDwith
ENDIF
NEXT
thisform.refresh
注:本例中list的fontsize是12.