New Function in 8 - DatePicker() - Use Windows DatePicker to select a date for a date field (Ver. 8.0.0.1180)
No rest for the wicked. Our team of developers consists of Russians, Norwegians, Egyptians and British individuals. It turns out that when the rest of the world fight race and religious wars, we in the engineering and technical businesses only reap the benefits from multiculturalism ;-)
Russians are Orthodox so their Christmas started today, when Norwegians are Protestants so they have been drunk for the last week. Egyptians are mainly Muslim (our are at least) so they have holidays which from our calendar are moving targets but rarely collides with any of ours so in total we always have someone that works.
As a result we can announce that DatePicker() is ready from the Russian team ahead of them going to be away for a week of national drinking (obligatory) when the British and Norwegians are gearing up for the first work week of the new year'.The Egyptians have been going strong and will be going strong for the duration.
We have implemented DatePicker() as a function rather than as a part of the interface. There is both benefits and drawbacks with this solution.
If it was part of the interface you would get a nice little button next to your date filed where you could enable the calender widget. The negative with this is that you would not be able to call it from a DQL or from a formula, action etc.
So we have implemented it as a function so you can call it from anywhere, but you will have to make it look pleasing yourself.
To the right you see a simple implementation.
Here we use two new 8 functions. DatePicker() and SetValu().
The field is simply a Date field and the button to the right is an image with an action. The action is as follows:
We activate the DatePicker() and when we have a return value we simply "push" it into the Date field with SetValu().
You can of course use DatePicker() as part of the derivation for the Date field directly but the nice thing with this solution is:
1. The date field is unaffected by the DateField() functionality if you don't click the button so everything is as before the keyboard "people".
2. You get to make the DateField look like a DatePickerField by adding the DatePicker image next to it.