Answered
Having used this script in pdf documents I created it worked fine and I wanted to use it with a new form prepared with LC.
I placed the following in a Script Object called: color
color.current = new Array ("RGB", 0.5, 1, 0.5);
function gotf_color (classname){
var f = this.getField(event.targetName);
f.fillColor = color.current;
}
function lostf_color (classname){
var f = this.getField(event.targetName);
f.fillColor = color.transparent;
}
In the Field Event enter: gotf_color ("regular");
and in the Field Event exit: gotf_color ("regular");
under exit. When entering the field nothing happens.
Would someone be able to tell me whats wrong with my code?
Here is a sample form by Adobe, it shows how to change field colors in XFA-forms.
[url]http://partners.adobe.com/public/developer/en/livecycle/designer/pdfs/ChangingFieldAndSubformBGColors.pdf[/url]
radzmar
• LoveCycle Blog
Documents you need:
• LiveCycle Designer ES2 Docs