I'm using a DateChooser, and want to show different information in a tooltip as the user rolls over each day. Is there an event that fires as I'm rolling around the calendar that will tell me what day I'm currently over?
It's a little complicated. You're going to need to use the mx_internal namespace. The grid portion of the DateChooser component is a CalenderLayout component in DateChooser.as.
mx_internal var dataGrid:CalenderLayout;
CalenderLayout.as has the mouseMoveHandler. In the handler we have:
var selCell:IUITextField = dayBlocksArray[colIndex][rowIndex];
that gives you the necessary info about which day the mouse is over. You will need to extend DateChooser to use an extended CalendarLayout that exposes the selectedCell.
perhaps:
private function mouseMoveHandler(event:MouseEvent):void
{
...
dispatchEvent(new DayHoverEvent(selCell.text));
}
I guess what I'm trying to say is it's kinda tricky, and it uses mx_internal, which means the variables are subject to change in later versions of Flex.
Hi,
You may want to check out my blog post on this: http://flexmonkey.blogspot.com/2010/06/displaying-color-coded-events-in-flex.html
I've based this on some previous work by Kevin Brammer (http://www.cyberslingers.com/weblog/post/Adding-Calendar-Event-Entries-to-the-Flex-DateChooser-Component.aspx) - it allows you to add a tooltip to individual days and colour code them
Hope it helps,
simon