September 4th, 2008 by Kyle
Tags: , , , ,
Posted in: ActionScript, Flex


Here is the second approach to solving the problem I descibed in this post:

http://blog.flexmonkeypatches.com/2008/09/02/flex-datechooser-background-color-for-smtwtfs-header-solution-1/

This movie requires Flash Player 9

Download a zipfile containing the source to this sample.

Browse the source of this example.

Or continue into the blog entry to see the source:
Read the rest of this post»




1 Comment »

September 2nd, 2008 by Kyle
Tags: , , , ,
Posted in: ActionScript, Flex


I had someone ask me a while back how they could set the background color for the “SMTWTFS header” in the calendar control. This is not built in functionality, but really not that hard to do.
In fact, I found 2 different approaches. The first is below, the second, I will post in a few days after I clean up the code a bit.

(I would like to point out that this is just an approach and may not be production ready code.)

This movie requires Flash Player 9

Download a zipfile containing the source to this sample.

Browse the source of this example.

Or continue into the blog entry to see the source:
Read the rest of this post»




2 Comments »

August 29th, 2008 by Kyle
Tags: , , , ,
Posted in: ActionScript, Flex


The datachooser control doesn’t expose a way to disable the individual year up/down arrows, only the entire year Navigation (via yearNavigationEnabled).

But in looking at the internals of the dataChooser.as class you can get at the Buttons in an unsupported way.

mx_internal var upYearButton:Button;

mx_internal var downYearButton:Button;

These are the mx_internal scoped buttons for the up/down year.
You could technically extend the datechooser class and then create methods to enable/disable these buttons (if they exist).
Then you could enable/disable them using logic based on what you are setting for selectable ranges.

This is what I have done in the following example

This movie requires Flash Player 9

Download a zipfile containing the source to this sample.

Browse the source of this example.

Or continue into the blog entry to see the source:
Read the rest of this post»




1 Comment »