Unfortunately, I can't use shortcut keys. I'm converting a spreadsheet from Lotus1-2-3 to Excel, trying to keep the same functionality as the original.
To go more into depth of what I'm trying to do:
Have a spreadsheet of different corporate locations across the US, and the listing of areas are in a pre-defined order which I'm not allowed to re-sort. Those locations are further broken down into groups, but the locations in those groups are spread out amongst the selections:
example:
rows 1-4,10 may be in Group A
rows 5-8,12-14 in Group B
rows 9,15 in grp C
The kind of information maintained for each location, may need to spill over onto a 2nd line, therefore there is an "add line" feature that will add a row directly underneath the location in question. Therefore, taking the example above, if row 3 was Topeka, KS, and I added a line underneath this, so that row 4 also was Topeka, KS, group A would then consist of rows 1-5,11. I was hoping this would be a dynamic change. I am using the following to add the line:
ActiveCell.Offset(1).EntireRow.Insert
and then copying the location name from the "activecell" to the offset cell.
For some reason, excel doesn't automatically pick up the new row added, and therefore doesn't automatically adjust the range for each group.
Therefore, when adding a new line, I need to determine, from which cell/row is current, which range name I'm in, add the row, and then recreate the range name to take into account the new range.