Category Archives: Flex Air

Maximize Air window

Just to make searches easier for the rest of the world. Very, very simple example: This maximizes the window on creation complete. Dirty. More reading about NativeWindow: – NativeWindow – Adobe ActionScript® 3 (AS3 ) API Reference

Array shuffling in ActionScript3

Been wanting to add this post for a while. Pretty simple, really. So imagine you have an array: It can be any size, obviously. And you want to change the position of its items. Several ways to do so – like splicing the array, but i dont recommend it because theres a loss in speed… Read More »

AMFPHP 1.9 problem with PHP 5.4

I was developing an application at work that used amfphp 1.9. All was working until i decided to bring it home to work over the weekend (thats already a bad thing to do right there), and i started getting errors. At work i use windows 7+xampp (with php 5.3.8), at home i use windows 8+xampp… Read More »

Sort an ArrayCollection

If you have an ArrayCollection and need to sort it, heres a quick example: import mx.collections.ISort; import mx.collections.ISortField; var sort:ISort = new Sort(); var sortfieldNome:ISortField = new SortField(“name”,true); // “name” is a field on the arraycollection var sortfieldEmail:ISortField = new SortField(“email”,true); // “email” is another field on the arraycollection sort.fields = [sortfieldNome, sortfieldEmail]; myArrayCollection.sort =… Read More »

Copy ArrayCollection – not as a reference

On my day job, i needed to copy an ArrayCollection to a different var so i could manipulate it without affecting the original. Went with this: arraycollection2 = arraycollection1; With this method, all i did to arraycollection2 was also happening to arraycollection1. to copy arrayCollection1 to arrayCollection2 without making it a reference: arrayCollection2 = ObjectUtil.copy(arrayCollection1)… Read More »

FlashBuilder 4.x Color Scheme/Theme

Spending a lot of time in front of my monitor looking at code on a white background was slowly getting on my nerves. I looked up on changing the flash builder IDE color scheme and came up with some nice alternatives. My life coding life just got much nicer…and darker. This is tested on Flash… Read More »

How to add a line break in a flex TextArea

To add a line break inside the text of a TextArea component in flex we cannot use \n, but instead use ‘&#13;’ (without the quotes). For example: <s:TextArea text=”this text will be on the first line&#13;and this one on the second” …/> will produce a text box with this text: this text will be on… Read More »

Air project doesn’t run. No error.

Didn’t quite know what to use as a title, because the problem sounds a bit too generic. Anyway, on to the problem/solution. The problem was that i was trying to convert an already built/in progress Flex project to Air and it was giving me some grief, since it simply didnt run. No error, nothing. The… Read More »