Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Word / Programming / November 2007

Tip: Looking for answers? Try searching our database.

Select text on specific line

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Dan - 04 Nov 2007 16:17 GMT
Hi,
I need to get the text that is on a specific line. The text will always be
different but always in the same
position in the document.
Thanks!

Dan
Helmut Weber - 04 Nov 2007 16:50 GMT
Hi Dan,

how is position defined?

3rd line on a page?

Then:
Goto page,
goto line "+2",
MsgBox Selection.Bookmarks("\line").Range.Text

Signature

Greetings from Bavaria, Germany

Helmut Weber, MVP WordVBA

Win XP, Office 2003
"red.sys" & Chr$(64) & "t-online.de"

Dan - 04 Nov 2007 23:54 GMT
Thanks Helmut,
That's what I needed.

Dan

> Hi Dan,
>
[quoted text clipped - 6 lines]
> goto line "+2",
> MsgBox Selection.Bookmarks("\line").Range.Text

Rate this thread:






 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.