Hi,
I am trying to select a number of cells in a column that may not be sequential in order to delete these cells and move cells up 1. My goal would be much like the following manual example:
Click on cell G4
Hold Ctrl key
Click on cell G6
Right click
Select delete
Select Shift Cells Up
I ran through a loop that built an array of the row number of the cells that I wish to delete but I'm lost on how to seclect just those cells in the array to perform the delete and shift cells up.
This is my code to indentify the rows of the cells in column G to delete"
Erase CheckBoxDelArray()
ReDim CheckBoxDelArray(1 To 14)
i = 1
ii = 4
For i = 1 To 14
If Me.Controls("CheckBox" & i).Value = True Then
CheckBoxDelArray(ii) = CheckBoxDelArray(ii) + 1
End If
ii = ii + 1
Next i
Using Watch, I determined the correct row numbers were in the array.
Any help would be great.
Thanks.
I am trying to select a number of cells in a column that may not be sequential in order to delete these cells and move cells up 1. My goal would be much like the following manual example:
Click on cell G4
Hold Ctrl key
Click on cell G6
Right click
Select delete
Select Shift Cells Up
I ran through a loop that built an array of the row number of the cells that I wish to delete but I'm lost on how to seclect just those cells in the array to perform the delete and shift cells up.
This is my code to indentify the rows of the cells in column G to delete"
Erase CheckBoxDelArray()
ReDim CheckBoxDelArray(1 To 14)
i = 1
ii = 4
For i = 1 To 14
If Me.Controls("CheckBox" & i).Value = True Then
CheckBoxDelArray(ii) = CheckBoxDelArray(ii) + 1
End If
ii = ii + 1
Next i
Using Watch, I determined the correct row numbers were in the array.
Any help would be great.
Thanks.