Dear macropod,
Thanks for the reply.
I was my mistake that I was applying your above procedure on already processed document.
What I did was first I broke whole document's sentenses into paragraphs and then applied your procedure. Hence I was unable to
detect the new paragraph created by your procedure as the document was already full of paragraphs.
I request you to help me in adding three more things.
1)BEFORE above procedure executes, I want to remove all unnecessary paragraph characters.
The reason behind this is that I have created this document by coverting a PDF. And to maintain line-to-line formatting, PDF
processors add this paragraph at the end of each line. The algorithm would be:
a) Find a paragraph character.
b) If it's previous character is NOT full point ".", then replace the paragraph character with a space.
I would use regular expressions in C# to achieve this.
This procedure should execute BEFORE any instruction in your Sub TextSplitter().
2) I want to split all sentenses to a new paragraph. Already I am using Find and replace feature as
Find "._ " and then repalce with ".^p"
Even this should execute BEFORE any instruction in your Sub TextSplitter() but after the previous instructions are
executed.
3) Finally, your procedure throws "Run time error" after the document processing reaches at end. I would use Try and catch block
in C#.
Also, I want to remove particular objects from complete document such as a horizontal line. We can't use Find and replace for this purpose. Then How to select all Line objects at once and delete?
Thanks for your valuable help.
Last edited by aditya_bokade; 06-30-2012 at 09:02 AM.
Reason: Forgot to mention one point.
|