C
Chris Lewis
What I need to do is if I have a table of rows x. Each row
can contain either 1, 2, 4 or 5 cells. I need to loop through each row in
the table and clear the contents of the Cells 3, 4 and 5 only in the rows
with 5 cells. all other rows are left alone.
so
Selection.Tables(1).Select
j = Selection.Rows.Count ' i need the number of rows later so stored in
variable now
For rownum = 1 To j
Selection.Tables(1).Rows(rownum).Select
If Selection.Cells.Count = 5 Then
Something here to delete the contents of cells 3, 4 and 5 of the current
row#
Next rownum
any ideas?
can contain either 1, 2, 4 or 5 cells. I need to loop through each row in
the table and clear the contents of the Cells 3, 4 and 5 only in the rows
with 5 cells. all other rows are left alone.
so
Selection.Tables(1).Select
j = Selection.Rows.Count ' i need the number of rows later so stored in
variable now
For rownum = 1 To j
Selection.Tables(1).Rows(rownum).Select
If Selection.Cells.Count = 5 Then
Something here to delete the contents of cells 3, 4 and 5 of the current
row#
Next rownum
any ideas?