Apache Flex

Apache Flex is a highly productive, open source application framework for building and maintaining expressive web applications that deploy consistently on all major browsers, desktops and devices (including smartphones, tablets and television). It provides a modern, standards-based language and programming model that supports common design patterns suitable for developers from many backgrounds. Flex applications can be deployed to the Adobe Player in the browser, Adobe AIR on desktop and mobile devices or to native Android, iOS, Windows or Mac applications.

Share tech news, updates, or what's on your mind.

Sign up to Post

I need some expert help with this item editor problem. I have the following advanced datagrid control and it is working well using a combobox as an in-line editor, however I need to swap the combobox for a checkbox which seemed straight-forward enough,however, I need the checkbox item editor / rendererer to do the following:

1. When the checkbox is selected the data in the cell needs to change to "true" as it does with the combobox.
2. Checkbox item editor/renderer needs to display the true or false value as selected or not selected, just as the combobox does.
3. Checkbox must not display in grouping header field. It must only display in the children of the grouping collection. (grouping collection is not shown in the code). I tried setting the depth in the datagrid and it still displayed a checkbox in the row(s) containing the grouping field.

For some reason when I change the in-line control to a checkbox and set the       
editorDataField="selected" the cell  the datagrid is not changing the data to the selected value.
I have a "save" button that commits all the changes made to the datagrid to the database and it works beautifully if I use a combobox as an in-line control.

I can get it to dis0play the cell data value by using the item editor and setting editorDataField="selected"

            <fx:Component id="inlineEditor">
                              <mx:ComboBox >
Hi guys,

I am trying to access a function in my class file (.as file)

I am using this code which isnt working

the trace displays [object Game]

Game is the name of my file Game.as


if (this.parent != null)
var p:MovieClip = this.parent as MovieClip;

Open in new window

Here is my function

public function goToLeaderBoard() : void 
			trace("hit function");

Open in new window

Suggestions please :D

Hi guys,

I have the following set up

a movie clip in my library called "brigetStack", this is set for export on first frame in linkage etc....

So the class is called brigetStack

I have this at the top of my file

private var brigetStackMC : MovieClip = new brigetStack();

Open in new window

I call it and add it like this
				this.brigetStackMC = null;
				this.brigetStackMC = new brigetStack();
				this.brigetStackMC.name = "brigets";

Open in new window

The movie clip brigetStackMC has 4 symbols instanced inside and is 30 frames long,

THere is a stop on frame 1, however when i add it to screen as shown above it autoplays and ignores the stops.

Any help / suggestions welcome

I have a program that is creating a web mapping service for our company.  I just recently restarted my server/testing PC and I now get the error below.  Anyone have any idea on how I should go about trying to fix this issue?

Failed to start the server machine xxxxxxx. Error while starting AppServer. Required port '4,000' already in use.'

Thanks in advance.  

We have a user who is using Access 2010 and is getting a prompt for a password no matter what she does.  Even if it is a new database she gets asked for the password.  I've never seen this except on a single database.  How do you turn this feature off?
Hi guys,

I am trying to add a swf to the main time line from within a child swf,

I use this code in my main SWF and it works

function clickedNoBtn(e:Event):void
	//This creates a new instance of the loader object and adds it to the stage.
	var movieNO = MovieClip(Load_No.content).gotoAndPlay(2);
	trace("no button clicked");
	this.noBtn.removeEventListener(MouseEvent.CLICK, clickedNoBtn);

Open in new window

In my child swf i try this and it fails

function clickedYesHand(e:Event):void


Open in new window

Please help

what does this mean ?

Google Maps API for Flash has been officially deprecated

does this mean this will also include flash builder ( flex ) or only the flash ?
Hi guys,

How can I add social media icons to a flash movie, I want the twitter counter also,

I know I can call the post etc using external interface, is it possible to have the counter?

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" 

			private function grpFunc(data:Object, column:AdvancedDataGridColumn):String
				// add check for the presence of the properties here
				return data[gc.grouping.label] + " (" + data["summary"] + ")";
	<mx:Array id="arr">
			<mx:Object From="Phill" Subject="GMC-1 Release" Date="12/08/06" CC="Jim"  Profit="69" />
			<mx:Object From="Phill" Subject="GMC-1 Release1" Date="12/08/06" CC="Jim"  Profit="31" />
			<mx:Object From="Harry" Subject="GMC-1 Release3" Date="November 2, 2006" CC="Ram"  Profit="10" />
			<mx:Object From="Barb" Subject="GMC-1 Release4" Date="12/08/06" CC="Anant"  Profit="20" />
			<mx:Object From="Amit" Subject="GMC-1 Release2" Date="12/07/06" CC="Jim"  Profit="28" />
			<mx:Object From="John" Subject="GMC-1 Release2" Date="12/07/06" CC="Jim"  Profit="12" />
			<mx:Object From="Amit" Subject="GMC-1 Release21" Date="12/07/06" CC="Jim"  Profit="22" />
      <mx:AdvancedDataGrid id="adg" groupLabelFunction="grpFunc" creationComplete="gc.refresh();"  height="300">
                  <mx:GroupingCollection id="gc" source="{arr}" >
                              <mx:GroupingField name="From" >
                                    <mx:SummaryRow summaryPlacement="group">

Open in new window

In the following example I have a spark label that is binded to the average value of 4 other Numeric Steppers.  This work fine apart from (depending on the values) i'm getting results with too many decimal place's.

<s:Label text="{(numericStepper1.value + numericStepper2.value + numericStepper3.value + numericStepper4.value)/4}"/>

Open in new window

For example i'm getting:

Instead I want:
I've seen some dashboard examples but most of them are old.  I really like this one but have no clue how to convert it to 4.6 from 2.0  I'm pretty new at this.  Does anyone know of any good dashboard downloads that I can use as a starting template?  


I was able to convert this one so far with help from a converting page.  However, I like the way you can choose the chart view or data view in the previous example.  



I have a flash swf that loads several xml files, do I need to create a cross domain policy for each IP address that the xml file is loaded from?

 <?xml version="1.0"?>
	    <!DOCTYPE cross-domain-policy SYSTEM "http://www.macromedia.com/xml/dtds/cross-domain-policy.dtd">
	    <allow-access-from domain="123.456.789.000" />
	<allow-access-from domain="www.mywebsite.com" />
	<allow-access-from domain="sub.mywebsite2.com" />

Open in new window

hi guys

I am looking for a regular expression which will check if there are
any alphabets in a string of numbers.  
i am using

public function isValidNumber(s:String):Boolean{
return Boolean(s.match(/^[0-9]+$/));

if i enter s = 55e or s = 6567y  it returns false which is fine
but when i enter
s = 99.99
it returns false.

When decimal numbers example 99.99 is entered i want it to return true but when
99.aa is entered i want it to return false.

any idea how i can change my above function ?

It seems totalTime is missing in spark videoPlayer

How can I retrieve the length of a movie in s:videoPlayer component ?

(it also seems onMetaData is missing)
For the following code:

<?xml version="1.0"?>
<!-- dragdrop\SimpleListToListMove.mxml -->
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
	<mx:Text id="txtName" x="247" y="24" width="181" enabled="true" text="course1"/>
	<mx:Label x="137" y="24" text="Course Name:" textAlign="right"/>
	<mx:Text id="txtDesc" x="247" y="77" width="269" enabled="true" text="description1"/>
	<mx:Label x="157" y="76" text="Description:" textAlign="right"/>


Open in new window

since these two text fields are set as enabled="true", why is the user not able to edit the text field?

I'm moving data to these fields from a database to allow the user to edit the data before sending it back to PHP.  Should I be using a different control?   Is there a way to create a border automatically around text fields like this?


I'm teaching myself Adobe Flex 4.6 (FlashBuilder) and am picking up the coding method fine, but having trouble when I hit a runtime error.

For example, I have an app on a tabbed control that has a datagrid on each tab pulling MySQL data for display.  Rather than having all this code in the main file, I created separate components for each datagrid and dropped them into each tab.

Everything worked fine until I converted the last datagrid display into a component and put it on the top tab and removed the corresponding code in the main file.  That grid displays properly, but now when I click on any of the other tabs to show those grids I get the following runtime error:

ReferenceError: Error #1065: Variable _Componenets_teacherGridWatcherSetupUtil is not defined.
      at global/flash.utils::getDefinitionByName()
      at Componenets::teacherGrid()[C:\Users\Gary\Adobe Flash Builder 4.6\FlexPHPMysqlUpdateAdv\src\Componenets\teacherGrid.mxml:4]
      at mx.core::Container/createComponentFromDescriptor()[E:\dev\4.y\frameworks\projects\mx\src\mx\core\Container.as:4294]
      at mx.core::Container/createComponentsFromDescriptors()[E:\dev\4.y\frameworks\projects\mx\src\mx\core\Container.as:4183]
      at mx.core::Container/createDeferredContent()[E:\dev\4.y\frameworks\projects\mx\src\mx\core\Container.as:4214]
      at mx.containers::ViewStack/instantiateSelectedChild()[E:\dev\4.y\frameworks\projects\mx\src\mx\containers\ViewStack.as:1260]
      at …
Hi experts:
I have an array in Actionscript 3.  

private var myArray:Array = [  [1.2,3.4],

I would like to be able to get the first element, the point 1.2, 3.4, in a loop.  When I try this I get a large error.  

I would like to do this:
    for (var i:uint; i < myArray.length; i++) {
        point = myArray[i,0];
        point2 = myArray[i,1];


As the title suggest I'm looking for the fastest, cleanest most efficient way of merging 2 ArrayCollections.  I've seen several solutions on the internet but its not clear which is the best method.


I have created a class that extends Sprite.  This class loads external display assets (2 images) into itself and is then used to display these assets on the screen.  My display works fine, but when I try to programatically address the width and height of the object, the values are always zero.  ?
I can resize the object by using scaleX & scaleY, but I have no control over the width or height variables, as they are always mysteriously zero.

I have attached my code, along with the refernced display assets.  The main class is PrintStuffDS and the class in question is Product.

I have included trace statements to show the problem.

Please advise. :)
I was able to stream from FlashMediaEncoder to Ipad device (html5 video)

FME--->FMS---->IPAD : ok

Now I try to stream from flash player (flash11 with H264) to ipad but nothing happens.

Is it possible to stream from flashplayer (on PC, flash11) to IPAD ?

FlashPlayer11 (H264)--->FMS----->IPAD ?

Any link / clue  for that ?

We are creating a game in AS3, in which the player may not leave a certain area, to be decided just before the level starts.  We are having some problems with a circular area, however.  Our game is a 2D, top down shooter, with the background scrolling to give the sensation of movement.  We have barriers at the edge of each level, signified by a line the player cannot cross.  The idea is that rather than the player hitting the barrier, their velocity is transferred so that they seem to "glide" along it.  This way, they are never stuck.

Our square/rectangle levels work fine, as the player can glide along any side perfectly well upon approaching it, as the velocity for one axis is transferred to the other.  Obviously with a circular area, we have to do something different, as circles have no sides for us to be able to tell where they hit.  At the moment, I have used hitTestPoint with the boundary line to see if it touches the player, and if it does, then stop the player crossing.  This isn't enough, however, and doesn't feel as solid as we would like.

Is there a better way to keep a player within a circular area, and how can we make the player glide along the boundary of the circle?
flex project theme
Flex4.5 allows to choose some ready to go "Project themes".
Here is the screensjot of "sky".

My question is: WHERE IS IT STORED in your flex project: There is no CSS file created, nothing added to my project !

My goal is to propose an application where user can RUNTIME choose between themes like : sky, cobalt, graphite.

Is that possible ?
hi guys

I have in my actionscript

private var count:Label;
Count.text   = value["column1"] as String;

I want to check Count.text is a positive number greater than or equal to zero.

Is there a easy way to do that?

I'm having trouble getting a drop-down list to display the values from an ArrayCollection.  The dropdown displays [object][object],[object][object] etc..  This would normally indicate that the label isn't set - but I can't see what is happening wrong.

This is the trace of my ArrayCollection:

  filterFunction = (null)
  length = 1
  list = (mx.collections::ArrayList)#1
    length = 1
    source = (Array)#2
      [0] (mx.collections::ArrayCollection)#3
        filterFunction = (null)
        length = 4
        list = (mx.collections::ArrayList)#4
          length = 4
          source = (Array)#5
            [0] (Object)#6
              label = "LIFE_LAPSE_MASS_SHOCK"
            [1] (Object)#7
              label = "MKT_FX_SHOCK_DN_DKK_EUR"
            [2] (Object)#8
              label = "MKT_SPD_WIDENING_SHOCK"
            [3] (Object)#9
              label = "N_LIFE_LAPSE_MASS_SHOCK"
          uid = "A68C2B85-91F0-E15F-CFF5-900BA52F1BB6"
        sort = (null)
        source = (Array)#5
    uid = "81D0DA94-1B86-6CDB-DB5D-900BA53314CE"
  sort = (null)
  source = (Array)#2

I'm getting the arraycollection from a web service :
scenAC = new ArrayCollection(ArrayUtil.toArray(event.result.Streams._WEBOUT.Value.TABLE.SCENARIOS));

and setting the dataprovider and label:


<s:DropDownList  id='scendd' x="139" y="20" width="163"  enabled="false"/>

Any …
Hello :)

been at this about 4 hours, looking to set the background of a spark spinner list to transparent :)  I've tried backgroundAlpha which does not seem to work and editing the skin for the class any help is greatly appreciated.

Apache Flex

Apache Flex is a highly productive, open source application framework for building and maintaining expressive web applications that deploy consistently on all major browsers, desktops and devices (including smartphones, tablets and television). It provides a modern, standards-based language and programming model that supports common design patterns suitable for developers from many backgrounds. Flex applications can be deployed to the Adobe Player in the browser, Adobe AIR on desktop and mobile devices or to native Android, iOS, Windows or Mac applications.

Top Experts In
Apache Flex