I have 12 projects and 3 variables per project (INT, STR, STR).
I want to loop these variables, together at the project-level, across the macro. For example:
for key, value in data.items():
record = d[key]
project = d[items(0)]
map = d[items(1)]
How can I properly translate this to VBA? Thanks in advance!
VBA Code:
'Lists
'rec = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12]
'prj = ["ALD", "AZ1", "FL1", "FL4", "FL5", "GA3", "GA4", "MA1", "MS3", "MW1", "MW2", "TN1"]
'Map = ["B2", "B4", "B6", "B8", "B10", "B12", "B14", "B16", "B18", "B20", "B20", "B22"]
'data = {[1, 'ALD', 'B2'], [2, 'AZ1', 'B4'], [3, 'FL1', 'B6'], [4, 'FL4', 'B8'], [5, 'FL5', 'B10'], [6, 'GA3', 'B12'], [7, 'GA4', 'B14'], [8, 'MA1', 'B16'], [9, 'MS3', 'B18'], [10, 'MW1', 'B20'], [11, 'MW2', 'B20'], [12, 'TN1', 'B22']}
I want to loop these variables, together at the project-level, across the macro. For example:
for key, value in data.items():
record = d[key]
project = d[items(0)]
map = d[items(1)]
How can I properly translate this to VBA? Thanks in advance!