That gives something to work with at least, but I still have no idea of what you expect to see, so...
lets try this as a test run of the basic idea;
First, I broke all your merged cells, and used center across selection instead (merged cells are a pain to write formulas around, therefore, gone)
then this in A2 of 'Main Page' :
Formula:
=INDEX('Sub Data'!$A$3:$Z$3,MATCH($C$1,'Sub Data'!$A$1:$Z$1,0)+(ROWS($A$2:$A2)-ROW($A$2)+1))
Drag down to A6 (see attached)
I don't think this is what you are looking for, but it may give us a basis to start getting your answer
Hope this helps
Bookmarks