These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

Plain text to Rich Text

Biffnet7
Registered: Dec 9 2009
Posts: 36

Is it possible for a JavaScript to change a text Field from Plain text to Rich Text. If the Text Fields in the Form are set to plain text can say a Button be created that will change selected fields to Rich Text? Or maybe change from Rich to Plain text?
 
I have looked everywhere and I have not found script examples for Livecycle.
 
The problem has to do when people paste from Word Docs that use a lot of formatting and different fonts. Users want to be able to remove all formatting when pasting into the Dynamic Form then go back and reformat some of the text.
 
Allen

Allen

My Product Information:
LiveCycle Designer, Windows
maxwyss
Registered: Jul 25 2006
Posts: 255
With PDF forms (aka Acroforms), it would be possible; it would, however, require some additional scripting to get the simple field's contents into the form required by fields with richText set.

Max Wyss.

Biffnet7
Registered: Dec 9 2009
Posts: 36
It doesn't look possible with Forms cereated in Livecycle though. I was hoping to be able to change the properties of a Text box from Plain to Rich Text by a button event.

Thanks for the reply.

Allen

Allen

radzmar
Expert
Registered: Nov 3 2008
Posts: 1202
To allow Rich text in a plain text field use

Textfield.resolveNode("ui.#textEdit").allowRichText = "1";

radzmar
LoveCycle Blog
Documents you need:
LiveCycle Designer ES2 Docs

Biffnet7
Registered: Dec 9 2009
Posts: 36
I'm confused on where to put this script. Can it be part of a button event or could it be part of the text field itself as a calculated script?

Do you hawev any examples you could point me to?

Thanks for the reply.

Allen

Allen