R
Roderick O'Regan
I'm trying to adapt the following code to find out if there is a table
in any of the footers:
kJunk = ActiveDocument.Sections(1).Footers(1).Range.StoryType
'Iterate through all story types in the current document
For Each kStory In ActiveDocument.StoryRanges
'Iterate through all linked stories
Do
On Error Resume Next
Select Case kStory.StoryType
Case wdEvenPagesFooterStory, wdFirstPageFooterStory,
wdPrimaryFooterStory
*
* Pseudo-code: If there are any tables in this story then select the
third cell in the first row
*
Next
End If
Case Else
'Do Nothing
End Select
On Error GoTo 0
'Get next linked story (if any)
Set kStory = kStory.NextStoryRange
Loop Until kStory Is Nothing
Next
Can anyone help with this please?
Roderick
in any of the footers:
kJunk = ActiveDocument.Sections(1).Footers(1).Range.StoryType
'Iterate through all story types in the current document
For Each kStory In ActiveDocument.StoryRanges
'Iterate through all linked stories
Do
On Error Resume Next
Select Case kStory.StoryType
Case wdEvenPagesFooterStory, wdFirstPageFooterStory,
wdPrimaryFooterStory
*
* Pseudo-code: If there are any tables in this story then select the
third cell in the first row
*
Next
End If
Case Else
'Do Nothing
End Select
On Error GoTo 0
'Get next linked story (if any)
Set kStory = kStory.NextStoryRange
Loop Until kStory Is Nothing
Next
Can anyone help with this please?
Roderick