Cairngorm View Locater : Change view based on Change in Command

I was making changes to view based on collection change event till i found out that Cairngorm Event and Cairngorm Event dispatcher go very well like a normal event dispatcher.
To change a view based on the result listen by command, write a Event Meta Tag, Create a Event and dispatch it in result handler of command as show in figure.

Command

Command

And listen this event in main File on initialize as shown in the figure

Main.mxml

Main.mxml

dispatched event is captured in function and based on this change can be made to View of Cairngorm.

Regards,
Ranjit Sail

Advertisements
    • fares
    • May 31st, 2011

    very nice trick ! I was facing the same problem 🙂 i’m gonna try it out right now !
    thanks

  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: