Discussion Locked

While printing a VB-Word document......

0 helpful
3 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

Hi!
Iam printing values taken from database through a vb program in to a ms-word document.While printing,i found the need for sensing the line number of word document for alignment.Is there any function available to do the same? Bye!

3 replies

by dklippert

This may give you some direction.
Sub WhereAmI()
'
MsgBox "The selection is on Line " & _
Selection.Information(wdFirstCharacterLineNumber) & " of page " _
& Selection.Information(wdNumberOfPagesInDocument)
End Sub

This discussion is closed to new replies.