I received the following error when trying to publish to Android and iOS from Flash CS6 (Air 3.2):
Application Descriptor File Cannot be Parsed
Searching for a fix yielded that my file is probably invalid, but this is not the case as I can run this project just file from another computer.
Turns out that this problem came up because I was running my FLA out of a network location (i.e, \\Server\path\). Mapping the network drive to an actual drive letter fixed the problem.
I needed to change the background color of the text region of a flash combobox - using AS3 at runtime.
Styles for some reason were not working. The solution was to directly address the textfield property and change its background color. Here's an example:
cbo.textField.textField.background = true;
cbo.textField.textField.backgroundColor = 0xDEDE29;
I tried to customize the combobox ( AS3 ), and everything was working fine by using cbo.setStyle( "embedFonts" ) and cbo.setStyle( "textFormat" ) while testing the movie. However, when I published the SWF, the styles were no longer working.
It seems like setStyle doesn't really work properly for comboboxes for some reason. The solution was to apply the setStyle to the textField inside the combobox, and not to the combobox itself.
For example, this doesn't work:
cbo.setStyle( "embedFonts", true );
cbo.setStyle( "textFormat", tf );
but this works:
cbo.textField.setStyle( "embedFonts", true );
cbo.textField.setStyle( "textFormat", tf );
It seems like FusionCharts does not support changing the color of a trendline via the TRENDVALUES style application. The color always seems to default to the color of the trendline.
The fix to this issue involves modifying the source of the XYPlotChart.as file (you’ll need the source for fusioncharts to be able to do this).
Search the file for the following line (it should be line 1789):
trendFontObj.color = this.trendLines [i].color;
Right afer this line, paste the following code:
if ( this.styleM.getTextStyle (this.objects.TRENDVALUES).color != undefined )
trendFontObj.color = this.styleM.getTextStyle (this.objects.TRENDVALUES).color;
There may be a more “elegant” way of doing this, but the code above will enable you to change the color of trend value lines by using styles in fusioncharts.
Here’s something I wasted like 45 minutes on, and it should be pretty trivial. I needed to make the TextArea component NOT selectable, yet still enabled (need the scrollbar to work).
I started digging around the TextArea.as class, because no matter what I did in my code (such as myTextArea.textField.selectable = false; ), the TextArea was still selectable. It appears that when the TextArea calls the draw() or setSize() methods, it updates the text field in the TextArea to be selectable depending on whether the TextArea is enabled or not.
Clearly, whoever designed the TextArea component didn’t give this much thought. In any case, the way I got around the issue is to attach to the Event.Render event of the text area. Therefore, after the render method is called (and the TextArea is drawn), I can update the textfield to not be selectable. Here is some sample code.You may need to attach to more events than just the render event, but the concept should work.
var DescriptionField:TextArea = getChildByName( "description" ) as TextArea;
DescriptionField.addEventListener( Event.RENDER, onDescriptionRender );
public function onDescriptionRender( evt:Event ):void
var textArea:TextArea = evt.target as TextArea;
textArea.textField.selectable = false;