Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Checking a cell in Word 2000 to see if it contains data. 1

Status
Not open for further replies.

ftpdoo

Programmer
Aug 9, 2001
202
GB
Hi,

I've got a table in Word 2000. The cursor is currently sitting at a cell and I wish to check if a cell is blank or if it contains some data.

Something like:

If .Selection.cell = "" then
msgbox "NO DATA"
else
msgbox "CONTAINS DATA"
End If

Any idea's??
Thankx,
Jonathan
 
Am using Word 97 but this may help you

Dim sCellText As String

sCellText = Selection.Cells(1).Range.Text
sCellText = Left$(sCellText, Len(sCellText) - 2)


 
am using Word 97 but this may help you

Dim sCellText As String

sCellText = Selection.Cells(1).Range.Text
sCellText = Left$(sCellText, Len(sCellText) - 2)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top