Repost: (Urgent) Formating text

  • Thread starter Francesc Blanes
  • Start date
F

Francesc Blanes

Hello,

I'm using a rich text box control.

I have to create a custom button (in jscript) to apply a predefined format
to the piece of text tat is select in the text box. (i.e. red background
color). I have to create another button to reset the format for the selected
text.

I didn´t find how I can do it. Anyone could help me please?

Thank you
 
S

Scott Roberts [MSFT]

Unfortunately, InfoPath doesn't provide any view-side scripting model.
InfoPath's object model is purely based on the data. Therefore, you won't
be able to find the selection in the rich text box. The best you will be
able to do is get the data from the DOM, search for the text you want to
format, and insert the proper XHTML into the data.

- Scott
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top