Home All Groups Group Topic Archive Search About

When building a WYSIWYG HTML editor, which MS control is the best to use?

Author
19 May 2009 2:58 AM
Number Eleven - GPEMC!
Which Microsoft control is the best for building a WYSIWYG (x)HTML editor?

The options I've seen to date include

1. Using the Rich Text Box and converting Rich Text to (x)HTML & back.
2. Using the WebBrowser Object with the ActiveX document design mode on.
3. ?something? tapped into the MSXML services?

Are there any other possible options based on Microsoft controls and
services available to VS2005?

The burning question for me is which is the best MS control for building a
WYSIWYG editor for HTML and/or XHTML and why?

Thanks in Advance...

'============OBSERVATIONS============'
Option 1 would be a lot easier if:

a) The Rich Text Box had a HTML stream option and separated bold and strong,
italic and emphasis - but perhaps I ask too much!
b) The Rich Text Box not only could return SelStart and SelLen for a
selection in plain text but also the SelStart and SelLen figures
corresponding to the rich text.
c) The Rich Text Box had a test for whether text is hidden or not eg.

\pard Here we have the \i first \i0 paragraph \v with this hidden comment in
the middle \v0 and that is all it appears to say.\par Here is the second
parag...

d) The Rich Text Box did not automatically convert group RTF eg.

       {\b   ... {\i   ...   }}{\i   ...   }

and well-formed RTF eg.

       \b   ...   \i   ...   \i0\b0\i   ...   \i0

to overlapping/flagged RTF eg.

       \b   ...   \i   ...   \b0   ...   \i0

Is there a way of turning off these automatic conversions between styles of
RTF?

'_________________________________________'
Option 2 would be easier if there was either:

a) It had a generic tag/format placement function that neither violates the
document's "well-formedness" nor upset the carat, selection, or focus.
or
b) It had SelStart and SelLen returns for both plain text and mark-up


Thanks in advance of your comments and suggestions....
____________________________________________________________
Timothy Casey GPEMC - Eleven is the num***@timothycasey.info to email.
Philosophical Essays: http://timothycasey.info
Speed Reading: http://speed-reading-comprehension.com
Software: http://fieldcraft.biz; Scientific IQ Test, Web Menus, Security.
Science & Geology: http://geologist-1011.com;http://geologist-1011.net
Technical & Web Design: http://web-design-1011.com
--
GPEMC! Anti-SPAM email conditions apply. See www.fieldcraft.biz/GPEMC
The General Public Electronic Mail Contract is free for public use.
If enough of us participate, we can launch a class action to end SPAM
Put GPEMC in your signature to join the fight. Invoice a SPAMmer today!

Author
19 May 2009 1:24 PM
gillardg
i don't have the answer to your question but if you plan to use RichTextBox
then you may need this to convert  rtf to html
it's working good and convert images too :)

http://www.codeproject.com/KB/recipes/RtfConverter.aspx

"Number Eleven - GPEMC!" <eleven_is_the_num***@timothycasey.info> a écrit
dans le message de groupe de discussion :
4a12200b$0$7111$afc38***@news.optusnet.com.au...
Show quoteHide quote
> Which Microsoft control is the best for building a WYSIWYG (x)HTML editor?
>
> The options I've seen to date include
>
> 1. Using the Rich Text Box and converting Rich Text to (x)HTML & back.
> 2. Using the WebBrowser Object with the ActiveX document design mode on.
> 3. ?something? tapped into the MSXML services?
>
> Are there any other possible options based on Microsoft controls and
> services available to VS2005?
>
> The burning question for me is which is the best MS control for building a
> WYSIWYG editor for HTML and/or XHTML and why?
>
> Thanks in Advance...
>
> '============OBSERVATIONS============'
> Option 1 would be a lot easier if:
>
> a) The Rich Text Box had a HTML stream option and separated bold and
> strong,
> italic and emphasis - but perhaps I ask too much!
> b) The Rich Text Box not only could return SelStart and SelLen for a
> selection in plain text but also the SelStart and SelLen figures
> corresponding to the rich text.
> c) The Rich Text Box had a test for whether text is hidden or not eg.
>
> \pard Here we have the \i first \i0 paragraph \v with this hidden comment
> in
> the middle \v0 and that is all it appears to say.\par Here is the second
> parag...
>
> d) The Rich Text Box did not automatically convert group RTF eg.
>
>       {\b   ... {\i   ...   }}{\i   ...   }
>
> and well-formed RTF eg.
>
>       \b   ...   \i   ...   \i0\b0\i   ...   \i0
>
> to overlapping/flagged RTF eg.
>
>       \b   ...   \i   ...   \b0   ...   \i0
>
> Is there a way of turning off these automatic conversions between styles
> of
> RTF?
>
> '_________________________________________'
> Option 2 would be easier if there was either:
>
> a) It had a generic tag/format placement function that neither violates
> the
> document's "well-formedness" nor upset the carat, selection, or focus.
> or
> b) It had SelStart and SelLen returns for both plain text and mark-up
>
>
> Thanks in advance of your comments and suggestions....
> ____________________________________________________________
> Timothy Casey GPEMC - Eleven is the num***@timothycasey.info to email.
> Philosophical Essays: http://timothycasey.info
> Speed Reading: http://speed-reading-comprehension.com
> Software: http://fieldcraft.biz; Scientific IQ Test, Web Menus, Security.
> Science & Geology: http://geologist-1011.com;http://geologist-1011.net
> Technical & Web Design: http://web-design-1011.com
> --
> GPEMC! Anti-SPAM email conditions apply. See www.fieldcraft.biz/GPEMC
> The General Public Electronic Mail Contract is free for public use.
> If enough of us participate, we can launch a class action to end SPAM
> Put GPEMC in your signature to join the fight. Invoice a SPAMmer today!
>
>