R
Rajat
I’m using Excel 2003, what I intended to accomplish to create a macro to
unhide row (By default few rows will be hidden) based on the drop down list
value of a Cell.
Say I have created a dropdown list in F2 cell using Data>Validation>List
which have value 1 to 7.
I need the Macro to do the following –
1. When the sheet is open or Active hide Row 3 to 30
2. If the Cell F2 Value is selected 1 then immediately Row 3 to 6 will be
unhide/Shown but rows 7 to 30 will be hidden.
3. If the Cell F2 Value is selected 2 then immediately Row 3 to 10 will be
unhide/Shown but rows 11 to 30 will be hidden.
4. If the Cell F2 Value is selected 3 then immediately Row 3 to 14 will be
unhide/Shown but rows 15 to 30 will be hidden.
5. If the Cell F2 Value is selected 4 then immediately Row 3 to 18 will be
unhide/Shown but rows 19 to 30 will be hidden.
6. If the Cell F2 Value is selected 5 then immediately Row 3 to 22 will be
unhide/Shown but rows 23 to 30 will be hidden.
7. If the Cell F2 Value is selected 6 then immediately Row 3 to 26 will be
unhide/Shown but rows 27 to 30 will be hidden.
8. If the Cell F2 Value is selected 7 then immediately Row 3 to 30 will be
unhide/Shown.
Thanks in advance,
unhide row (By default few rows will be hidden) based on the drop down list
value of a Cell.
Say I have created a dropdown list in F2 cell using Data>Validation>List
which have value 1 to 7.
I need the Macro to do the following –
1. When the sheet is open or Active hide Row 3 to 30
2. If the Cell F2 Value is selected 1 then immediately Row 3 to 6 will be
unhide/Shown but rows 7 to 30 will be hidden.
3. If the Cell F2 Value is selected 2 then immediately Row 3 to 10 will be
unhide/Shown but rows 11 to 30 will be hidden.
4. If the Cell F2 Value is selected 3 then immediately Row 3 to 14 will be
unhide/Shown but rows 15 to 30 will be hidden.
5. If the Cell F2 Value is selected 4 then immediately Row 3 to 18 will be
unhide/Shown but rows 19 to 30 will be hidden.
6. If the Cell F2 Value is selected 5 then immediately Row 3 to 22 will be
unhide/Shown but rows 23 to 30 will be hidden.
7. If the Cell F2 Value is selected 6 then immediately Row 3 to 26 will be
unhide/Shown but rows 27 to 30 will be hidden.
8. If the Cell F2 Value is selected 7 then immediately Row 3 to 30 will be
unhide/Shown.
Thanks in advance,