Following is my problem description
A B C D
1 H1 H2 H3 H4
2 1 3 4 2
3 2 4 1 8
4 3 1 6 1
5 4 2 8 5
First row has the headings. Column A has the serial number of the table. Columns B, C, and D are values coming out from some calculations. I want to write a VBA code such that the code finds the minimum value in the Column D, selects all the corresponding values of the row, copies and pastes just the values in a sheet named NewSheet.
For the given case above, the VBA code should identify that the Cell D4 has the minimum value, it should select the corresponding values in row 4 (from cells B4, C4 and D4), copy these selected values and paste the values in the cells P2,Q2 and R2 of ‘NewSheet’.
Since I am just a beginner, it will be highly appreciated if the responder can provide some comments that will help me to understand the code.
This will do the trick.