Hi EE People,
I have found some scripts that partially do what I need but not entirely. After fiddling with them, I have attached the one closer to my needs within my workbook.
Merits of Worksheet_Change script:
- Based on a change in a cell value (UserInput C3), it hides/unhides some cells (DataRange Col A).
Shortcomings of Worksheet_Change script:
- It doesn't work with a formula result (UserInput B3).
- Its displayed range is currently limited to one column of cells (DataRange Col A).
- It hides/unhides individual cells in colunm A instead of inserts/deletes them.
- Script should work with the result of a formula (see UserInput B3).
- Script should insert a range of one row as many time as needed based on the date difference (see UserInput B3).
- The range to be inserted is comprised of array and regular formulas (see Stats 15:15).
- Special case: based on the date difference, if the number of rows to be inserted is less than the number of rows currently displayed in the worksheet, the extra rows should be removed.
Objective: the script should dynamically manage the insertion or removing of rows based on user input in a worksheet.
Thx in advance for your help.