Date and Time Picker Control
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
Date and Time Picker Control
Is it just me or does LiveCode not have a standard DTP Control based on a Combo Box?
Re: Date and Time Picker Control
I noticed a lack of response, so I presume that my question was not obvious enough.
I would like to know if it is possible to use a default date picker (as in MS Visual Studio).
I've tried a few things, but without success. Can anyone help me further away?
Thanks,
Mark
I would like to know if it is possible to use a default date picker (as in MS Visual Studio).
I've tried a few things, but without success. Can anyone help me further away?
Thanks,
Mark
- Attachments
-
- Example.png (5.75 KiB) Viewed 8779 times
Last edited by xor on Sun Jan 09, 2011 3:00 pm, edited 2 times in total.
-
- Livecode Opensource Backer
- Posts: 1336
- Joined: Sun Jul 12, 2009 10:53 am
- Location: Bordeaux, France
Re: Date and Time Picker Control
Hi...
attached a stack for you to look at..
be well
Dixie
attached a stack for you to look at..
be well
Dixie
- Attachments
-
- Calendar.zip
- (5.35 KiB) Downloaded 481 times
Re: Date and Time Picker Control
Hi Dixie,
Thanks for your response.
I tried to open the calendar stack using a combo box and the “Use stack panel” property. When I press the combo box the calendar appears. Perfect.
When I try to select a day nothing happens. Or when I try to switch through the months and years the calendar closes.
Do you know how the solve this issues?
Thanks for your response.
I tried to open the calendar stack using a combo box and the “Use stack panel” property. When I press the combo box the calendar appears. Perfect.
When I try to select a day nothing happens. Or when I try to switch through the months and years the calendar closes.
Do you know how the solve this issues?
-
- Livecode Opensource Backer
- Posts: 1336
- Joined: Sun Jul 12, 2009 10:53 am
- Location: Bordeaux, France
Re: Date and Time Picker Control
Mark...
The calendar is a group.. you can't put it into the comboBox, but you can call it from within the menuItems that are listed in the comboBox.
In the example that I have sent, if you select 'calendar' then the group 'cal' will appear, choose 'toolbox' the vis of the group 'cal' will be set to false...
Hope it gives you some ideas about how to sort out your problem...
be well
Dixie
The calendar is a group.. you can't put it into the comboBox, but you can call it from within the menuItems that are listed in the comboBox.
In the example that I have sent, if you select 'calendar' then the group 'cal' will appear, choose 'toolbox' the vis of the group 'cal' will be set to false...
Hope it gives you some ideas about how to sort out your problem...
be well
Dixie
- Attachments
-
- cal2.zip
- (3.83 KiB) Downloaded 411 times
Re: Date and Time Picker Control
@Dixie: thanks for the example, but it is not exactly what I had in mind.
Maybe it is not possible to create a date picker based on a combo box.
Can a date picker can be made through a custom control?
Maybe it is not possible to create a date picker based on a combo box.
Can a date picker can be made through a custom control?
-
- Livecode Opensource Backer
- Posts: 1336
- Joined: Sun Jul 12, 2009 10:53 am
- Location: Bordeaux, France
Re: Date and Time Picker Control
xor...
Can you say what exactly you want to do ?... I'm a little confused ...
Dixie
Can you say what exactly you want to do ?... I'm a little confused ...
Dixie
-
- VIP Livecode Opensource Backer
- Posts: 56
- Joined: Sat Apr 08, 2006 5:28 pm
- Location: Eau Claire, WI
- Contact:
Re: Date and Time Picker Control
Here's dixie's group, stuck into a substack and popped up using the "popup" command. It doesn't actually do the whole thing; I just wanted to show you how to approach solving this. Basically I cleared out the contents of the combo box so there's nothing to pop up, then changed the menuPick handler to a mouseDown handler. I copied dixie's group into a substack, named it "DatePicker" and then set the mouseDown handler in the combo box to pop up the stack at a specific place.
You'd have to modify the code of the actual datepicker stack to do what you want, but at least this should give you some direction...
You'd have to modify the code of the actual datepicker stack to do what you want, but at least this should give you some direction...
- Attachments
-
- Cal2pop.zip
- (3.63 KiB) Downloaded 390 times
Ken Ray
Sons of Thunder Software
Email: kray@sonsothunder.com
Web site: http://www.sonsothunder.com
Sons of Thunder Software
Email: kray@sonsothunder.com
Web site: http://www.sonsothunder.com
Re: Date and Time Picker Control
Dixie: I want to find out if it is possible to have a Date Picker Control based on a Combo Box. Please look at the image that I have attached (second post). Are you still confused?
Ken: Thanks for your example. I need some time to look at and I will let you know a.s.a.p.
Ken: Thanks for your example. I need some time to look at and I will let you know a.s.a.p.
Re: Date and Time Picker Control
Ironically, I have been looking for the same thing as xor.
I started to play around with the date time picker on BvG's web site and modified it.
All credit of the date time picker goes to BvG.
HTH
I started to play around with the date time picker on BvG's web site and modified it.
All credit of the date time picker goes to BvG.
HTH
- Attachments
-
- modifiedBvGDatePicker.zip
- (6.9 KiB) Downloaded 546 times
- Rich
LiveCode 4.6.4
Dell Latitude E6400 running Windows XP SP3 / Mac Pro, Macbook Pro & Mac Mini running OS X 10.6.4
LiveCode 4.6.4
Dell Latitude E6400 running Windows XP SP3 / Mac Pro, Macbook Pro & Mac Mini running OS X 10.6.4
-
- Posts: 57
- Joined: Fri Feb 09, 2018 2:28 am
Re: Date and Time Picker Control
Huge thanks to BvG for hitting the nail on the head. This is one of those 'must-have' controls you would figure everyone would want to have added to the LiveCode toolbox. Big thanks to Richh for going out of his way to find the exact right hammer for this particular nail. Even though you posted this an awfully long time ago, it's a gift that keeps on giving, because I'm going to use it today.