flex4

How to set skin at runtime in Flex 4

Hi, I have a bunch of custom controls based on a SkinnableContainer. When adding the control at design time, I can specify a skin by using the skinClass attribute on the tag. I need to add some of these elements during runtime, and I can't figure out how to specify the skinClass for my controls. eg. var something:CustomThing = new ...

bin-debug missing the html file cannot rebuild flex4

I cant seem to recreate my Main.html that is necessary to build from in flashbuilder4 I guess I can do it manually at cost of time but what a bore ! I'm sure this shoudl be possible. Clean rebuilds most of this folder and then runnign the project get the error that it cant find Main.html grrrrrrrr ...

Flex RGBA colors in CSS

Hello all, I am trying to style a DataGrid component so that the background is transparent (Flex 4). Rgba colors work fine if I make "alternatingItemColors" an attribute on the component, but if I try to declare it in my css stylesheet, I cannot declare the alpha value. Works (mxml): <mx:DataGrid id="songGrid" width="800" height="529" ...

How can I define custom 'contentGroups' in a custom Flex 4 component?

The spark panel component for example can be written like this And its skin file will handle layout of the contentGroup, controlBarGroup, and titleDisplay. Notice, however that the contentGroup is doesn't appear in the code above and that the controlBarGroup accepts child mxml components. Now say I want to create a c...

flex 4: does remove element also destorys the element?!

Hiya. I dynamically add and remove elements form VGroups. When I create an element and then append it to a VGroup and then remove it from that VGroup, does it destroy the element completely? if not, how can I destroy the element so it won't take space in memory. thanks! ...

Want to pull data from DATABASE using Java And Flex

I Am Completely novice in flex could you just let me know about it plz.I want to access data from a database residing on a particular ip address and also i am not sure how to do it pl let me know how it can be done through flex framework. ...

Flex 4 Gauge Component

Is there such a thing as a good looking Flex 4 Gauge component? The degrafa gauge looks great but it doesn't work with Flex 4 ...

I have a page that contains both Flex and HTML at the same time. How do I make it cross resolution?

Hey guys, In one of my pages, I use a Flex 4 app in a column on the left, and then normal HTML in a column to the right. Is there anyway I can make it so that the ratio between the two columns is the same no matter the resolution? Thanks for reading. ...

flex 4: swfloader - how to mute game completly

Hiya. Ive read some answers here regarding muting swfloader volume but none of the examples would work in flex 4. I tried doinf the following: this._swfGame.source=url; this._swfGame.soundTransform = new SoundTransform(0.0); this would shut down the volume of the preloader, but when the game starts the volume is back to normal. i tr...

Flex 4 descendant pseudo selectors with CSS

Flex 4 offers descendant css selectors and pseudo-selectors like: s|DropDownList:open { font-size: 11; } s|DropDownList #labelDisplay { font-size: 12; } However, if I combine these two an wanted to do something like this, it doesn't seem to work: s|DropDownList:open #labelDisplay { font-size: 13; } Is this possible wit...

Issues with Flex 4 SDK under Flex Builder 3

I have managed to adjust Flex Builder 3 to work with the Flex 4 SDK thanks to this article. However, some strange things are happening. I changed all the namespaces as suggested, but I cannot get anything from the fx: namespace using the Flex Builder code completion, as well as the spark List class. ...

why my ProgressBar can't capture the mouse down event?

I use a custom skin as the track skin, but i can't get the mouse down event protected function application1_creationCompleteHandler(event:FlexEvent):void { pBar.addEventListener(MouseEvent.MOUSE_DOWN, onEvent, true); } protected function onEvent(event:MouseEvent):void ...

Converting a string into a CheckBox

I have a string which is ultimately the id of a CheckBox. What I need to be able to do is to access the CheckBox's properties from the string var myCheckBox:Object; var myString:String; myString = "checkbox_1" myCheckBox = Object(myString); ?!?! ... and then I'd need to get to myCheckBox.selected, and myCheckBox.label etc ...

adobe flash buider (flex4): Error #2025 or Error: addChild() is not available in this class. Instead, use addElement()

Hi, I'm a complete newbie to Flex, so apologies for my dumbness. I've searched for an answer but haven't found anything that seems to be doing the trick. What I'm trying to do: port this example http://www.adobe.com/devnet/air/flex/articles/flex_air_codebase_print.html to Flash Builder 4. All seems to be fine but for one thing. When I ...

FLEX datagrid and XML list content

I have the following XML list: <Queries> <Query id="1">qq</Query> <Query id="2">rr</Query> <Query id="3">ss</Query> </Queries> and I would like to display it in the following datagrid: <mx:DataGrid id="dataGrid" dataProvider="@{Queries.Query}" editable="true" width="500"> <mx:columns> <mx:DataGridColumn heade...

Flex : Adding a click handler on SkinnableDataContainer's items

Hi, I am new to Flex. What I am looking for here is adding a click handler on all the items created by a SkinnableDataContainer. I tried several things that didn't work, and I have no idea what is the right way to do it. <s:SkinnableDataContainer id="teamList" itemRenderer="TeamSummaryRenderer"> <s:dataPr...

Help with creating a custom ItemRenderer for Flex 4

I'm trying to create a custom ItemRenderer for a TileList in Flex 4. Here's my renderer: <?xml version="1.0" encoding="utf-8"?> <s:ItemRenderer xmlns:fx="http://ns.adobe.com/mxml/2009" xmlns:s="library://ns.adobe.com/flex/spark" xmlns:mx="library://ns.adobe.com/flex/mx" autoDrawBackgro...

Strange "INavigatorContent" error compiling in 4.0

I've recently decided to try an upgrade to 4.0. The only error I still can't work out is this one: "The children of Halo navigators must implement INavigatorContent" I seem to be getting it on all my ViewStacks that have validators. <mx:ViewStack xmlns:mx="http://www.adobe.com/2006/mxml"&gt; <mx:NumberValidator id="systolicValidator...

Flex 4 IntelliJ IDEA wrapper html crashes browser

I'm building an Flex 4 application using IntelliJ IDEA 9.0.2 generated sample Flex application. I replace the generated mxml with the following code from the book Hello Flex 4. It simply crashes the browser when I run it. It says "Waiting for fpdownload.adobe.com..." and then crashes! I tried it on both FF 3.5.9 and Chrome 4. Any clues?...

Flex-built SWF's no longer work, error 2048, 2046, 2032

I'm really confused about this problem, and I'm pretty new to Flex. Basically, anything I try to build with mxmlc fails to run now, giving me the above three errors depending on what I do. It was working 30 minutes ago, I've been spending that time trying to figure out what has changed. I redownloaded the Flex SDK, cleared my assetcache,...