Unfortunately no, the best you can do is either do something on loose focus, or you could do something on gain focus that sets a field, that an on interval al then starts checking for 'changes', and does something, but you don't have an 'on date selected' execute option like you do with Menus or something along those lines
On or Lose Focus was what I was afraid of. I've never been a big fan of those events because it thows users off.I'll have to cook something up.
As was noted, there is currently no firing condition that does this.
On Menu Drop (who cares if it is a menu or a popup or a xxx, it is the same concept) is something that SHOULD be available for Dates and Times and Timestamps where the "picker" dialog is used.
Now, there is an RFE for this capability already in the system and there are people pushing pretty hard to get this particular one into the product...
I have strong hopes for this to come in a not to distant release (and no, this is not an announcement that it is in a particular release).
Unfortunately, that doesn't help you for now, but maybe in the future at another time when you need it, it will be there....
Is there also an RFE for an option to turn off 'BC' checkbox on Date only fields?....kuz I've never personally came across the need for that particular option, and have had issues with it being an option
Yes there is. HOWEVER.....
I personally don't want to do that option and don't like the RFE.
The RFE I do like much better is to add the concept of min/max date values to the date field defintiion so that you can specify min/max dates if desired. A side effect of this would be that if there were no BC dates possible, that checkbox would not appear. The end result of this is to allow you to eliminate BC if desired and to provide boundaries for dates so that you don't get dates that are not appropriate. If you just wanted to eliminate BC, you could set the min date to the year 1.
Now, both RFEs are in the system and I am expressing a personal opinion above about which I like better and think offers much more complete functionality. That does not control what RFE may end up being implemented at some point in the future.
I do happen to know that the same people who think that the firing condition working for date drop think that this idea of limits to date only fields is something that should be done and hopefully sooner rather than later (again, not an announcement of any kind of a future feature or availability of a capability).
I tried first to attach an event on the "OK" button of the "date/time" selector but sadly it has alrady a click() event and a stopbubbling so no joy.
So I attached a "change" event on the datetime field itself and it worked.
And yes, I know.. It's dirty.
II°) How I did it?:
So let's say I have a simple form with a date field and I want that once I chose the date something happens (an acl is fired).
So I need:
-> 1 acl that simply displays in a message the new date,
-> 1 acl guide with the acl inside,
-> my form,
I select a date:
So if you select the date/time using the button and click "OK" it'll be fine.
If you enter the date/time manually, it'll fire only when it'll lose focus.
That's pretty awesome Laurent
Pretty simple actually, problem will be maintenance and remembering it's there
Nice one Laurent
To hide the the "BC" check box, until/if Doug's solution is delivered, you can change this line in ClientCore.js :
this.mShowBC = true;
(change it to "false", obviously)
This is at least for 7.5 <= MT <= 8.0
Well that pretty much sums it up lol
I don't mind the Java Script (im a C# guy myself). For the record I redesigned the workflow to not need an Event handeler for the date picker BUT what you have posted will come in handy for greater functionality, thanks Laurent!
Sure, that was fun ^_^
Always interesting how to hack in and add a couple of new stuff
Hopefully Sylvain made his documents