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

Script needed

patra
Registered: Oct 19 2006
Posts: 270

I have a botton that links to a specific site...
Is it possible when a user click on the botton (On Mouse Enter event) the font color to change from
(176,0,0) to (153,204,255) for example!
Bottons borders and bockground fill are set to NONE.

Thanks

My Product Information:
LiveCycle Designer, Windows
pddesigner
Registered: Jul 9 2006
Posts: 858
Download the Adobe LiveCycle Designer Scripting Basics Manual. There are several good scripts in the last chapter titled - Examples of Common Scripting Tasks.

This is one from, Page 104 that could solve your problem.

Scripting for adding a blue border around a selected field

To add the blue border around the selected field, add the following scripts to each text field:

For example, add an enter event to the Name field:
Name.border.edge.color.value = "0,0,255";

For example, add an exit event to the Name field:
Name.border.edge.color.value = "255,255,255";For example, add a mouseEnter event to the Name field:
Name.border.edge.color.value = "0,0,255";

For example, add a mouseExit event to the Name field:
Name.border.edge.color.value = "255,255,255";

My favorite quote - "Success is the ability to go from one failure to another with no loss of enthusiasm.

patra
Registered: Oct 19 2006
Posts: 270
Thanks very much for your help!
This which I really prefer is to change the button's font colour no the border or anything else!
I have set Button's borders edges and background fill to NONE.
Is it possible?

THANKS
pddesigner
Registered: Jul 9 2006
Posts: 858
I'm guessing the objective of this is to determine if someone has clicked the button. I don't believe you can change the buttons font but I know you can change the buttons fill color.

If this will work for you, here's the JavaScript for a button (MouseUp, MouseDown, or click) action:

Button1.fillColor = "150,130,33"

Note: You can have more than one JavaScript for a form element.

My favorite quote - "Success is the ability to go from one failure to another with no loss of enthusiasm.