Hi all,
Hopefully this is a simple question to you guys.

I am trying to do the following:

I have created a userform, in which I can select balance sheet items. The commandbutton of the userform copies the selected balance sheet items to Sheet2. Based on the number of years selected which is noted in cell D5 of Sheet1, rows are inserted/copied for each of the selected balance sheet items. For example, see below table. Three balance sheet items were selected (equity, loans, total assets, but the number of selected balance sheet items may vary) and the number of years selected was 3 with starting point 2014 (noted in cell D4 of Sheet 1).

What I need the macro to do is to add the starting year in the column before the balance sheet item, to count down by one year for each row with the same balance sheet item and then to repeat this action for every subsequent balance sheet item.

Could anyone please have a look? Hopefully you can come up with a code that does the job!

Thanks in advance


2014 Equity
2013 Equity
2012 Equity
2014 Loans
2013 Loans
2012 Loans
2014 Total assets
2013 Total assets
2012 Total assets