Learning Employee Directory Series

10 sec read

Employee Directory is an AIR sample application from which I learned a lot. (try it) Here I post some of what I learned here.

1. introduction
2. structure
2.1 singleton
2.2 command
2.3 Cairngorm
3. ui
3.1 style
3.2 size
3.3 component
4. flow
5 events
5.1 event bubble
5.2 event clone
6 modify ED for your own purpose: custom field

related links

How much money did I make from an app?

Xu Cui
27 sec read

Handy programs to visualize NIRS data (2): plotTopoMap

Xu Cui
37 sec read

Flash 3D video demo

Racer Ostrova Zombie
Xu Cui
0 sec read

10 Replies to “Learning Employee Directory Series”

  1. Thanks a lot for breaking this robust app down!

    I downloaded the source code and did not know where to start, but thanks to you I now have a better understanding of it all.

    One question I do have is: How can I go about making the ED sync/refresh the database every time I make changes to the “employee.csv.zip” file?

    I keep changing the data in the csv.zip files, but it isn’t reflected when I run the app.

    Thx again!


  2. Hi, Chris,

    After you change csv.zip, try delete ED folder from your application storage directory. On my computer, it is
    C:\Documents and Settings\Xu Cui\Application Data\employeedirectory\

    You should see the change. I checked this on my computer.

  3. Thanks for the quick response, Cuiixu!

    Would you happen to know what folder that would be on a Mac?



  4. Once installed, does the Air App updated itself when the data changes? Or do you have to uninstall and re-install it every time you make changes to the list of employees?



  5. Really appreciate your breakdown of this. I was also having problems with the data not refreshing and just found the problem, if anyone’s interested. In the file


    The database name is specified as “employeedirectoryM6.db” and once you run the program this file just hangs around in your AppData folder, which is why deleting the folder refreshes the data. However there’s a better way to force the refresh by adding a moveToTrash()to
    the DatabaseConnectionManager method, like so

    dbFile = File.applicationStorageDirectory.resolvePath( DBPATH );

    This way the file gets refreshed every time without having to re-install. Hope this helps someone else.

  6. I ran in trouble after installing new field and now i can’t refresh any data…

    My question to XuCui is… Did you work around the embedded refresh button[i+logo method]?

    my problem is triggered when I try to refresh the DB using the i+logo method.
    [InsertEmployeeDataCommand : : An error occurred executing the SQL : 3115 :]

  7. @Joel

    BTW Joel’s way worked like a charm and actually fixed my error:3115 ?!?!
    As crazy as it sound once the ..M6.db was refreshed the Error (that i ve been researching for solution for over 4 days) miraculacy disappeared.

    that makes me think that my …M6.db was corrupted in some ways and was just making everything go basurk!!!

    Kudos Joel!

  8. Shot in the dark, i know you it’s getting old, but i almost finished my app and it’s working fine…

    I am trying to make everything neater..and there’s something that bug me real bad about the pictures from ED…

    Why the hell do every pictures are jagged? i can’t have all member of my directory with lazy eyes and forehead cropped out like freaks.

    Have you notice that? did you look around, any insight on what cause that?

    Anyways any comment would be appreciated.


Leave a Reply to C.B. Cancel reply
