View Single Post
  #3   Report Post  
Posted to microsoft.public.word.tables
adgorn adgorn is offline
external usenet poster
 
Posts: 8
Default search for empty cells in word tables

That seems to be identifying the cells. What I really need is to have the
cursor jump from empty cell to the next empty cell rather than a message.
Possible?
--
Alan


"macropod" wrote:

Hi Alan,

Here's some code to do the testing:

Sub TableTest()
Dim oTbl As Table
Dim oCel As Cell
With ActiveDocument.Range
For Each oTbl In .Tables
For Each oCel In oTbl.Range.Cells
If oCel.Range.Text = vbCr & Chr(7) Then MsgBox "Cell " & _
oCel.ColumnIndex & "," & oCel.RowIndex & " is empty."
Next
Next
End With
End Sub

Cheers
--
macropod
[MVP - Microsoft Word]
-------------------------

"adgorn" wrote in message ...
I have a document with many tables, including nested tables. I need to be
able to find all the cells that are empty since we may need to put a value in
there. It would be great to be able to go from empty cell to empty cell one
at a time. Any thoughts? Thanks.
--
Alan