krishnak
01-03-2008, 11:59 AM
Hi All,
I am writing a code for formating a Word document with the following conditions:
1. Remove the spaces or tabs at the beginning of the paragraph.
2. If the paragraph is bulleted (or numbered), retain the bullet (or number), but remove the tab space after the bullet.
The first part is easy. I modify the string of the paragraph text until the first character is not a space or a tab (32 or 9). I may also add other characters (like ! ) later.
For the second part, how do I recognize a bullet by its character code?
In one of the articles of MSDN library (CleanString method), it was mentioned that code 183 represents a bullet, but when I introduce that character code in a string, a space is added. When I run a script to determine the first character of the paragraph text, I get the character code of the first letter of the text bypassing the bullet and the tab space.
Thanks for any suggestions.
- Krishna
I am writing a code for formating a Word document with the following conditions:
1. Remove the spaces or tabs at the beginning of the paragraph.
2. If the paragraph is bulleted (or numbered), retain the bullet (or number), but remove the tab space after the bullet.
The first part is easy. I modify the string of the paragraph text until the first character is not a space or a tab (32 or 9). I may also add other characters (like ! ) later.
For the second part, how do I recognize a bullet by its character code?
In one of the articles of MSDN library (CleanString method), it was mentioned that code 183 represents a bullet, but when I introduce that character code in a string, a space is added. When I run a script to determine the first character of the paragraph text, I get the character code of the first letter of the text bypassing the bullet and the tab space.
Thanks for any suggestions.
- Krishna