I am trying to add a calendar component to my application and am 
trying to solve it in the following manner. I am using the Cairngorm 
framework.
 
I created a custom component that extends the TitleWindow. In this 
component, I have a public variable that I set called id. This is 
used to extract data from my ModelLocator for a given month called 
MonthScheduleData.
 
When someone selects a month and a year, I access a mysql database 
and return all of the schedule information for this given month. This 
is returned to flex and it is parsed into the MOnthScheduleData which 
is an array collection (ie each record in the array collection 
cooresponds to a day of the month (getItemAt(0) = 1st day of the 
month).
 
Now in my caingorm control, I loop through the selected month and 
create a custom TitleWindow component and set its ID to the day of 
the month (which is actually day of month - 1 to coorespond with the 
0 based arrayCollection). With each instantiation of these 
TitleWindows, I now add them to a second arrayCollection on the 
ModelLocator called MonthComponentData.
 
Here is the question I have, is it possible to build another custom 
component called CalendarMonth that extends a tileList and add in 
this MonthComponentData as a dataProvider? What I want is to be able 
to dynamically change the month and have each individual day 
components data change, and also I would need the overall calendar 
component to change.

When I create a component and store many of them in an 
ArrayCollection, will they be added to the stage in the TileList? If 
not, is there some way I can get them to be added dynamically so when 
the month changes, the components are rebuilt and the ArrayCollection 
that is bound to the calendar will also change.

Thanks for any help and direction on this question

Don

Reply via email to