UtterAccess.com
Thank you for your support!       Follow UtterAccess on Twitter
X   Site Message
(Message will auto close in 2 seconds)

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> Time Picker; Date Picker; Date Time Picker, Office 2003    
 
   
datAdrenaline
post Jul 10 2007, 10:06 PM
Post #1

UtterAccess Editor
Posts: 14,954
From: Northern Virginia, USA



This is a sample of a Time Picker, Date Picker, and Date/Time Picker to compliment the many already here on UA. Even though there are many samples here on UA, I did not find too many with a Time Picker, thus a reason why I am posting this.

The Time Picker and Date/Time Picker use a Slider bar to select the time ... when you slide the bar (similar to a volume control slider, except its horizontal) the Time changes dynamically. The Date Picker portions use the calender control shipped with MS Access.

Developed in A2003 with A2000 file format.

Please PM me with questions or issues.

[Revision 2.0] {Fixed un-recognized constant for A2000}


Edited by: argeedblu on Wed Jul 11 12:04:23 EDT 2007.
Attached File(s)
Attached File  1454668-TimePicker.zip ( 30.82K ) Number of downloads: 1919
 
Go to the top of the page
 
+
WallyH
post Apr 15 2012, 07:36 PM
Post #2

New Member
Posts: 3



This is awesome! One question though. If I wanted to change the double click to a single click how would I go about changing the code around?
Go to the top of the page
 
+
datAdrenaline
post Apr 16 2012, 08:31 AM
Post #3

UtterAccess Editor
Posts: 14,954
From: Northern Virginia, USA



Your would change the event properties and the prototype of the procedures ...

So, currently in the sample if you look at the Event Properties for the controls, you will see that the "On Dbl Click" property is set to "[Event Procedure]". What that does is tell Access that on a double click, call the procedure associated with the event. The event procedure name and calling structure is specific to the event and control name. So with the control named "txtDate", the OnDblClick event has the stub (or prototype) that looks like this:

Private Sub txtDate_DblClick(Cancel As Integer)


So in order to tell Access to react to a click, you would blank out the On Dbl Click event property, then change the On Click event property to [Event Procedure], then you would change the current code stub to this:

Private Sub txtDate_Click()


You would do that for all that you wish to change to a single click. But --- here is my caution, a single click event behavior like you are wishing to implement is often a burden to your users. Also, remember that your users could tab into a control and still not be presented with the dialog box. If you wish to create that type of UI (dialog presented each time the user is in the control) then consider using the On Enter event instead of the On Click event. If you choose to do that, then your code prototypes will look like this:

Private Sub txtDate_Enter()


I hope that helps! Please let me know how it works out for you!
Go to the top of the page
 
+

Reply to this topicStart new topic

 



RSS Go to Top  ·  Lo-Fi Version Time is now: 16th May 2012 - 07:27 PM

Tag cloud: