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 / January 2005

Tip: Looking for answers? Try searching our database.

Removing Blanks and returns from pdf to Word

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Dr. M - 26 Jan 2005 00:43 GMT
This question has probably been posted a thousand times, but I can't find it
on a search, so please forgive my ignorance.

I've copied text from a locked .pdf and pasted it into Word. How do I get
all the lines from the .pdf which are shorter than my margins to be the
length of a normal word doc line?

For instance, let's turn this:
Mary suffers from encopresis.
Jack does as well.

Into this with a space after the period:
Mary suffers from encopresis. Jack does as well.

I have written some code that kind of hammers on it, but it is brute force
and inelegant. Your help would save me many hours.

Thank you so much!
Signature

Dr. M

Jezebel - 26 Jan 2005 01:22 GMT
Display non-printing characters to you can see what's causing the problem.
Either you have line feeds (hard returns) or paragraph marks at the end of
each line.

If you have line feeds, with a paragraph mark at the end of each paragraph,
then simply delete them using Find and Replace: search for ^l (el not one)
and replace with a single space.

If you have a single paragraph mark at the end of lines and two paragraph
marks at the end of paragraphs then, again using Find and Replace --

Search for ^p^p and replace with "XXXX" (or any string that doesn't
otherwise occur in the document). Then search for ^p and replace with a
single space. Then search for "XXXX" and replace with ^p.

You might need to do a little cleaning up before and after, for example to
remove superfluous spaces on either side of paragraph marks, double spaces,
etc.

> This question has probably been posted a thousand times, but I can't find it
> on a search, so please forgive my ignorance.
[quoted text clipped - 14 lines]
>
> Thank you so much!

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.