可以通过字典的keys和items方法,获取字典的所有key值和item值。
Sub a()
Dim arr, d As Object
Set d = CreateObject("scripting.dictionary")
arr = [a1].CurrentRegion
'----------新增字典d的条目-----------------------
For i = 2 To UBound(arr)
d(arr(i, 1)) = arr(i, 2)
Next
s = d.keys
ss = d.items
End Sub