I need Macro which would hide/unhide rows based on a data in one cell.
Lets say I have info in cell A1 (which refers to years) and I would like to hide rows which are not "inside" this years (this refers to a data from this year).

If I put:
i) in A1 15 (years) I would like to show only rows from row 1 to row 15 and hide others (lets say I need no more than 80 rows)
ii) and if I put 20 (years) I would like show only rows from row 1 to row 20 and hide the rest of them

and so on, for every single number (year).

I've allready tried and don't know rule for manual Target.Value...in my way I would have to put code for every single number..

And I would also like that if I once type 15, that in next step I can type 20 and it still works (read: rows till 15 does not stay hidden).