VB編程中用Dictionary填充數據的方法,簡單的代碼案例如下:
Private?Sub?Command1_Click()Dim?TblMap_Card?'創建壹個變量?
Set?TblMap_Card?=?CreateObject(Scripting.Dictionary)?
TblMap_Card.Add?"Table",?"Cards"?'前面是?Key?後面是?Value
TblMap_Card.Add?"Serial",?"serialno"
TblMap_Card.Add?"Number",?"surface"
MsgBox?TblMap_Card.Item("Table")
End?Sub