This project has moved. For the latest updates, please go here.

Get Highlited Text, ReplaceText Feature

May 14, 2011 at 8:34 PM

Hi,

First i want to say this is a great project, one of the best i have ever seen, easy to use and professionally coded.

I think two features might be very helpfull for the community.

1. add a ReplaceOnce parameter to ReplaceText function, which will replace the text only once.

2. add a GetFormattedText (or something simmilar) which well return all text formatted in a specific manner. - for example: all text highlited in red.

This will make docx unique in those features, and will help programmers dealing with automatic report generation.

I have implemented this features in my source code, but since i'm not a professional coder , I belive it won't fit the official source code.

Thanks,

Harel.

Coordinator
May 16, 2011 at 7:47 PM

Hi Harel,

Your first feature request should be possible using the find function, it returns the index of each instance of a search phrase. You can then decide to replace as many or as few of these instances as you like using the insert and replace functions.

The second feature you suggested is an excellent idea, DocX needs an easy mechanism for dealing with formatted text. This will be the next area I work on... When I find the time that is.

If you want to post your functions here others might benifit from them. I have not yet decided how to handle text formatting so I wont add them to the source right away. If they prove to be popular functions I will however have no choice :-)

Thanks for your input and time,
Cathal

On 14 May 2011 21:34, "AshwalH" <notifications@codeplex.com> wrote:
> From: AshwalH
>
> Hi,First i want to say this is a great project, one of the best i have ever seen, easy to use and professionally coded.I think two features might be very helpfull for the community.1. add a ReplaceOnce parameter to ReplaceText function, which will replace the text only once.2. add a GetFormattedText (or something simmilar) which well return all text formatted in a specific manner. - for example: all text highlited in red.This will make docx unique in those features, and will help programmers dealing with automatic report generation.I have implemented this features in my source code, but since i'm not a professional coder , I belive it won't fit the official source code.Thanks,Harel.
>
>