I actually kinda figured this out from some other posts on here, but not completely. Heres the code:
This works great, but I am going to have to search for about 30-40 columns and copying and pasting this over and over seems to be a little redundant. Is there some way I can setup an array that has the columns header i am looking for (for example, in this function it is "Facility ID") and the column letter it should go in (here it is column "E") ? I have a general idea but I have no idea how to translate it into excel vba terms.
So basically it seems like I need it to search the column headers for a name in an array, and if found, put it in the column that corresponds to that specific header.
I was thinking that I could maybe make the "array" as an excel sheet and use a VLOOKUP to find out which column to paste into. But again, I am not sure how to code this. Are there any easier ways?
Bookmarks