kerrypnx
12/24/2019 - 1:42 AM

excel vba 讲列转换成数组再遍历

bColumnCount = Cells(Rows.Count, 2).End(xlUp).Row
ActiveSheet.Range("B40 : B" & CStr(bColumnCount)).Select
itemsArr = ActiveSheet.Range("B40 : B" & CStr(bColumnCount))
MsgBox itemsArr(1, 1)