PDA

View Full Version : Medium Flex Move Question


Jerry62712
11-13-2008, 07:22 PM
I have a bilingual page that has a button to switch between Spanish and English. The problem is this button becomes partially covered when the title is in Spanish. What I would like to do is move the button down a few pixels (and I'm assuming everything below it will also move) when in Spanish.

Here is the canvas and button code:

<mx:Canvas id="formHolder"
borderColor="#0000ff"
borderStyle="inset">

<mx:Text id="bodyFormTopText"
text="Food Stamp Calculator"
width="100%"
textAlign="center"
fontSize="20"/>

<mx:Form id="bodyFormHolder">
<mx:Canvas id="languageSwitchCanvas"
width="100%">
<mx:LinkButton id="languageSwitch"
label="Espanol"
click="swapLanguage()"
right="0" top="0"
fontSize="13"/>
</mx:Canvas>


Any help is greatly appreciated.

chadzilla
11-13-2008, 07:44 PM
In your languageSwitch() function put
languageSwitch.y = languageSwitch.y + 5;

That will move it down 5 pixles

Jerry62712
11-13-2008, 08:00 PM
I tried languageSwitch and I tried bodyFormHolder which worked. I had first tried the canvas, but that didn't work. Thanks for the pointer and we can mark this one as DONE!