davew
10-03-2012, 04:49 AM
Hi,
I’ve got what should be a simple problem but I’m struggling with it.
I have two tables. The first table contains three fruit: orange; apple, and pear. The second table contains 3 colours: red; yellow, and green.
I’d like a macro to cycle through and create a new list of two columns* like so (i.e. creates a list of every combination):
Colour
Fruit
red
orange
red
apple
red
pear
yellow
orange
yellow
apple
yellow
pear
green
orange
green
apple
green
pear
*I had some trouble getting it to display as two columns in this post but hopefully you get what I mean.
Once I’ve mastered this I can apply to larger tables.
Any help would be greatly appreciated.
Thanks
davew
I’ve got what should be a simple problem but I’m struggling with it.
I have two tables. The first table contains three fruit: orange; apple, and pear. The second table contains 3 colours: red; yellow, and green.
I’d like a macro to cycle through and create a new list of two columns* like so (i.e. creates a list of every combination):
Colour
Fruit
red
orange
red
apple
red
pear
yellow
orange
yellow
apple
yellow
pear
green
orange
green
apple
green
pear
*I had some trouble getting it to display as two columns in this post but hopefully you get what I mean.
Once I’ve mastered this I can apply to larger tables.
Any help would be greatly appreciated.
Thanks
davew