View Single Post
 
Old 11-21-2017, 03:24 PM
macropod's Avatar
macropod macropod is offline Windows 7 64bit Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 22,467
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

You could change the line:
Code:
ActiveDocument.ContentControls(2).Range.Text = StrDetails
to:
Code:
    With ActiveDocument.SelectContentControlsByTitle("ClientDetails")
      .Item(.Count).Range.Text = StrDetails
    End With
where 'ClientDetails' is the title you give to the output content control. That way, the output will always go to the last output content control in the document.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote