Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
combos and dates
Hello
I am trying to create three combos (day, month and year) i could just enter each day, each month and each year i want to the user to have the options to use. However i am sure i have seen some code which only allows the correct day to be shown depending on the month and year selected. can anyone help with this? I would also like todays date to be shown as the default day, month and year but have no idea how to go about it. at the moment im just using the =now() option to get todays date and not giving the user an option to select different. Any help would be great! Thanks as always! Shorty |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
combos and dates
Shorty,
You can use the Microsoft Date and Time Picker control 6.0 (sp4) in Excel 2000. It defaults to todays date and looks like a combo box. When you click the down arrow a calendar pops up below the combo box allowing you to click left and right buttons to go back or forward a month at a time. You can find it in the control toolbox under the "More controls" button that looks like a hammer and wrench with three dots underneath them. -- Billy Rogers Dallas,TX Currently Using Office 2000 "Shorty" wrote: Hello I am trying to create three combos (day, month and year) i could just enter each day, each month and each year i want to the user to have the options to use. However i am sure i have seen some code which only allows the correct day to be shown depending on the month and year selected. can anyone help with this? I would also like todays date to be shown as the default day, month and year but have no idea how to go about it. at the moment im just using the =now() option to get todays date and not giving the user an option to select different. Any help would be great! Thanks as always! Shorty |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
combos and dates
Thanks for that, ive had a look in there but cant find the date and
time picker, is there anyway to download this option or just to insert the VB code for it? im using excel 2000 but dont know what SP it is. Thanks, Shorty |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
combos and dates
found the file i need to download at:
http://support.microsoft.com/kb/297381/en-us however once i put the Microsoft Date and Time Picker control 6.0 on the worksheet, i cant select any information and the drop down/calendar wont load up, any suggestions? Shorty |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
combos and dates
quick note for the above post, the Microsoft Date and Time Picker
control 6.0 is SP6 will this make a difference? |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
combos and dates
Shorty,
I'm not sure if this is the problem, but when you place the control on the sheet you autmatically go into design mode. In order to use the control you need to exit design mode by clicking the icon on the control toolbox toolbar that looks like a green triangle with a pencil. To link the control to a cell, make sure you are in design mode and right click and select properties and set the linked cell property to a cell address. I'm not sure about differences with sp6. -- Billy Rogers Dallas,TX Currently Using Office 2000 "Shorty" wrote: quick note for the above post, the Microsoft Date and Time Picker control 6.0 is SP6 will this make a difference? |
#7
Posted to microsoft.public.excel.programming
|
|||
|
|||
combos and dates
I have tried to link the control to a cell, It shows the date in the
linked cell which is great. Though for some reason i still can not change the value in the date box. I have linked it to a cell, set min and max dates and enabled the check box. here is the code i get when double clicking on the date box Private Sub DTPicker1_CallbackKeyDown(ByVal KeyCode As Integer, ByVal Shift As Integer, ByVal CallbackField As String, CallbackDate As Date) End Sub Should be some more code in here? |
#8
Posted to microsoft.public.excel.programming
|
|||
|
|||
combos and dates
You don't need to add any code to be able to select a date. There should be
a calendar that pops up when you click the down arrow. If that's not working I don't know what is wrong. The only thing I can think of is that you need to make sure you aren't in design mode. The code that comes up when you click the control in design mode is fine. It's just a shell for adding code. there is another calendar control "Calendar Control 9.0" . It basically does the same thing except the calendar stays visible, it doesn't hide after you select a date. -- Billy Rogers Dallas,TX Currently Using Office 2000 "Shorty" wrote: I have tried to link the control to a cell, It shows the date in the linked cell which is great. Though for some reason i still can not change the value in the date box. I have linked it to a cell, set min and max dates and enabled the check box. here is the code i get when double clicking on the date box Private Sub DTPicker1_CallbackKeyDown(ByVal KeyCode As Integer, ByVal Shift As Integer, ByVal CallbackField As String, CallbackDate As Date) End Sub Should be some more code in here? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
table of # of rows with unique combos of values in 4 separated col | Excel Worksheet Functions | |||
Comparing two combos/cells to return a value | Excel Worksheet Functions | |||
Entering combos without converting it to dates? | Excel Discussion (Misc queries) | |||
too many combos | Excel Programming | |||
one sub for many Combos in different way | Excel Programming |