03-11-2011, 10:42 PM | #1 |
Member
Posts: 12
Karma: 10
Join Date: Feb 2011
Device: Kindle 3
|
word macro for editing needless paragraph marks
I am not sure whether I am posting the thread in the right forum part, as this is my first thread.
I need a macro for word 2007 to change paragraphs that doesn't have a dot,comma,question mark,exclamation mark or quote sign at the end but ended with a paragraph mark and replace them with a space to get a correct text flow. I used Stingo's macro but it changes all text¶graph flow, I want the text format stay the same but only to change the wrong looking sentences after conversion from pdf to word. Any help with this subject or similar macros for fixing related paragraph problems will be highly appreciated |
03-11-2011, 10:57 PM | #2 |
Not an Addict
Posts: 301
Karma: 5678807
Join Date: Mar 2011
Device: The blue one next to the fish.
|
Perhaps there is something in BookCreator that can help you.
https://www.mobileread.com/forums/showthread.php?t=28313 |
03-12-2011, 04:04 AM | #3 |
Connoisseur
Posts: 75
Karma: 204999
Join Date: Aug 2006
Location: London
|
Hi excalibra.
If your text has got 2 consecutive paragraph marks to indicate a new paragraph but here and there a single one where it shouldn't be, then you could do this with search and replace. First, search for ^p^p and replace them with ### Second, search for ^p and replace with a single space character Third, search for ### and replace with ^p^p All this is doing is preserving the paragraph breaks and then replacing the unwanted single returns with a space, then putting the paragraph breaks back. Please post back if I've misunderstood. bob |
03-12-2011, 08:20 AM | #4 | |
Member
Posts: 12
Karma: 10
Join Date: Feb 2011
Device: Kindle 3
|
Thanks for the answers.
Hoyt Clagwell: I think what I need is an improved version of Bookcreator's word wrap fix selection, I can do the corrections for extra paragraphs with that word wrap fix selection but it takes too much time to do one by one and other word wrap options; Stingo's and word wrap preserve styles change the format completely. comtrjl: Thanks for your help, I think you misunderstood, because I couldn't find any double paragraph marks(^p^p) in the text I want to edit, actually I want to remove paragraph breaks which are not pointing paragraphs, i.e. a word not having a dot,question mark,etc. at the end but having a paragraph mark,for example the text looks like this Quote:
|
|
03-12-2011, 09:23 AM | #5 |
Addict
Posts: 239
Karma: 1280000
Join Date: Oct 2010
Location: USA
Device: None
|
First cover the case where there may be a space (or two or three) between the ending punctuation and the ^p: change [space]^p to ^p globally and repeat a few times. Then change .^p to .... globally. Repeat for each mark: !>!!!!, etc.
Now change all ^p to space or newline, as you need. Now change all !!!! etc back to !^p. Scan text to proof. |
03-12-2011, 10:05 AM | #6 | |
Member
Posts: 12
Karma: 10
Join Date: Feb 2011
Device: Kindle 3
|
Quote:
The main problem is the text I am editing is in a different language than my office installation so I can't use grammar check in proofing tools, but as long as I reviewed the text I couldn't see any errors other than ! problem. As you seem like an expert in wildcards, can you please write how can I remove the page numbers that had mixed with the sentences? |
|
03-12-2011, 10:35 AM | #7 | ||
Addict
Posts: 239
Karma: 1280000
Join Date: Oct 2010
Location: USA
Device: None
|
Quote:
Quote:
No expert, someone will post a 12 character regex that will do it all. For the page thing, if the page numbers are like "Page x", "Page xx", "Page xxx", you can try find and replace. Turn on regex (click the box) and change " Page [0-9]" to "" (nothing, don't enter the quotes). Repeat with " Page [0-9][0-9]" and "Page [0-9][0-9][0-9]." If you tell Word what language the document is in, or set that language as the default, both the spellchecker and grammar tools should start working. I'm doing this from memory, I haven't used Word in a few years. |
||
Thread Tools | Search this Thread |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Word Macro: Footnotes to inline text ? | Hadrien | Workshop | 17 | 10-08-2011 01:28 PM |
Doc Splitter-Macro or Add-in For Word 2003 | konrad | Workshop | 0 | 03-08-2011 03:43 PM |
Justified word paragraph not wrapping in mobi | wlloydw | Conversion | 0 | 03-05-2011 03:03 PM |
Doc to REB Macro for Word | kbirdz | Fictionwise eBookwise | 0 | 10-27-2010 10:30 PM |
Word Formatting Macro (Stingo's Macro) | Stingo | Sony Reader | 75 | 08-24-2010 05:18 AM |