C
ChrisC
I have searched for and found code that looks like it ought to work to
do this - here is one example ive tried
Dim IndexCol As Long
Dim IndexRow As Long
With Selection
If Not .Information(wdWithInTable) Then
MsgBox "Selection must be in a table cell.", _
vbCritical, "Invalid Selection"
Exit Sub
Else
IndexCol = .Columns(1).Index
IndexRow = .Rows(1).Index
MsgBox "The coordinates of the top left cell of " _
& "the current selection is row " & IndexRow _
& " and column " & IndexCol & ".", _
vbInformation, "Active Cell"
End If
End With
Now the problem I am experiencing is that my document is locked, and as
such the user cannot select a table row or cell. If I put the cursor
within a cell the wdWithinTable still comes back false, and the
wdEndOfRangeRowNumber etc properties come back as -1.
Answers on a postcard...
Thanks.
do this - here is one example ive tried
Dim IndexCol As Long
Dim IndexRow As Long
With Selection
If Not .Information(wdWithInTable) Then
MsgBox "Selection must be in a table cell.", _
vbCritical, "Invalid Selection"
Exit Sub
Else
IndexCol = .Columns(1).Index
IndexRow = .Rows(1).Index
MsgBox "The coordinates of the top left cell of " _
& "the current selection is row " & IndexRow _
& " and column " & IndexCol & ".", _
vbInformation, "Active Cell"
End If
End With
Now the problem I am experiencing is that my document is locked, and as
such the user cannot select a table row or cell. If I put the cursor
within a cell the wdWithinTable still comes back false, and the
wdEndOfRangeRowNumber etc properties come back as -1.
Answers on a postcard...
Thanks.