Hey Guys,
I want to create a macro in Excel. An example of the data is added to this thread.
First thing you notice when you open the data is the top row with all the different variables.
Now as you notice this line of data is just one out of a bigger dataset. You also see that not every cell has got a value, this is normal. What I want to achieve is some kind of a transpose, I guess, but I have illustrated this in the dataset as well.
First Thing:
So what I need is when a cell contains a value, for instance cell N2, I need the variable name, in this case it's "g", to be copied to the first cell. Then I need the corresponding value, this is 2 in this case, and I also need the corresponding value next to this variable, this is cell O2 and corresponds to 5.
I call these variables "row specific" since every row will be unique, and the number of rows will be depended on how many cells contain a value. In this case only 2 cells contain a value (yes, 4 indeed but "g and b01g" belong together as do "j" and "b01j").
Second Thing:
There are also "fixed" variables. The values of these variables need to be copied as well to the different rows. An example is "ID", cell A2. Other examples are "Fixed" (cell AH2) and "Bpost" (cell AI2).
Anyways, hope someone can help me and let me know if more explanation is needed!
Sincerely
Bookmarks