编写一个集合类,类包含Add,Remove,Count,Item等属性和方法
问题是:如何对Item进行操作下面的方法能读Item,要怎样才能写Item呢?
private c_Item() as variant
'''''读Item
public property get Item(Index As Long) as Variant
Item(index)=c_Item(Index)
End Property
''''读Item
Public Function Item(Index As Long) As Variant
Item=c_Item(Index)
End Function如何实现像Collection对象的Item一样进行写操作?
问题是:如何对Item进行操作下面的方法能读Item,要怎样才能写Item呢?
private c_Item() as variant
'''''读Item
public property get Item(Index As Long) as Variant
Item(index)=c_Item(Index)
End Property
''''读Item
Public Function Item(Index As Long) As Variant
Item=c_Item(Index)
End Function如何实现像Collection对象的Item一样进行写操作?
解决方案 »
- VB如何生成一个真正唯一的机器码
- VB生成不了exe,请大家指点
- 在TreeView控件中,如何判断鼠标已经移开了某个结点?
- 分享我做的类代码:我找到了比较好的对文本框进行数据验证的好办法,现把代码分享出来,请大家批评!!!
- 如何才能知道系统文件夹在哪个盘符下和系统文件夹叫什么名字?
- access 有事物功能吗?
- 关于windows media player 控件的问题.
- 就“VB6中使本机与局域网内别的计算机的系统时间同步”再请教……
- 100分详细询问如何写支持条码设备的数据库应用程序?
- 大神帮忙:webbrowser控件无法获得新浪微博网页源文件
- winio.dll
- 如何将word文档输出到text文本框?
public property get Item(Index As Long) as Variant
Item(index)=c_Item(Index)
End Property public property let item(index as long ,value as variant)
c_item(index)=value
end property