Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
Calendar again
Hi
I know i can use a calendar in a sheet but can i use a calendar in a userform ? Maybe by a little icon (image) and when clik a form with a calendar pops up? Alvin |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
Calendar again
VBE--Tools--Additional control--Select Calendar control...
-- If this post helps click Yes --------------- Jacob Skaria "alvin Kuiper" wrote: Hi I know i can use a calendar in a sheet but can i use a calendar in a userform ? Maybe by a little icon (image) and when clik a form with a calendar pops up? Alvin |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
Calendar again
If you have a licensed Visual Studio installed then look for MS Date Time
Picker control.. If this post helps click Yes --------------- Jacob Skaria "alvin Kuiper" wrote: Hi I know i can use a calendar in a sheet but can i use a calendar in a userform ? Maybe by a little icon (image) and when clik a form with a calendar pops up? Alvin |
#4
Posted to microsoft.public.excel.misc
|
|||
|
|||
Calendar again
Using the calendar control or datepicker can cause problems if a user doesnot have the control installed. See this 'example' (http://www.sendspace.com/file/edtf8c) -- royUK Hope that helps, RoyUK For tips & examples visit my 'web site' (http://www.excel-it.com/) ------------------------------------------------------------------------ royUK's Profile: http://www.thecodecage.com/forumz/member.php?userid=15 View this thread: http://www.thecodecage.com/forumz/sh...ad.php?t=94578 |
#5
Posted to microsoft.public.excel.misc
|
|||
|
|||
Calendar again
alvin Kuiper wrote:
Hi I know i can use a calendar in a sheet but can i use a calendar in a userform ? Maybe by a little icon (image) and when clik a form with a calendar pops up? Alvin You can use a calendar in a user form. I have one in one of mine. Sorry I cant remember where I got it from but if I dblclick a text box on the user form a calendar pops up and I can insert a date which is then inserted into my spread sheet. By the way the calendar is another UserForm. Maybe if you do a search for userform calendar you will find one. sorry not much help. |
#6
Posted to microsoft.public.excel.misc
|
|||
|
|||
Calendar again
Lynz;338187 Wrote: alvin Kuiper wrote: Hi I know i can use a calendar in a sheet but can i use a calendar in a userform ? Maybe by a little icon (image) and when clik a form with a calendar pops up? Alvin You can use a calendar in a user form. I have one in one of mine. Sorry I cant remember where I got it from but if I dblclick a text box on the user form a calendar pops up and I can insert a date which is then inserted into my spread sheet. By the way the calendar is another UserForm. Maybe if you do a search for userform calendar you will find one. sorry not much help. The example I linked to in my first post does this -- royUK Hope that helps, RoyUK For tips & examples visit my 'web site' (http://www.excel-it.com/) ------------------------------------------------------------------------ royUK's Profile: http://www.thecodecage.com/forumz/member.php?userid=15 View this thread: http://www.thecodecage.com/forumz/sh...ad.php?t=94578 |
#7
Posted to microsoft.public.excel.misc
|
|||
|
|||
Calendar again
Thanks
Is there a way to format the day to dd,mm,yyyy Alvin "Jacob Skaria" skrev: VBE--Tools--Additional control--Select Calendar control... -- If this post helps click Yes --------------- Jacob Skaria "alvin Kuiper" wrote: Hi I know i can use a calendar in a sheet but can i use a calendar in a userform ? Maybe by a little icon (image) and when clik a form with a calendar pops up? Alvin |
#8
Posted to microsoft.public.excel.misc
|
|||
|
|||
Calendar again
Which control are you using.
Once you get the value to a variable; say dtValue Msgbox Format(dtValue,"dd,mm,yyyy") If this post helps click Yes --------------- Jacob Skaria "Lynz" wrote: alvin Kuiper wrote: Hi I know i can use a calendar in a sheet but can i use a calendar in a userform ? Maybe by a little icon (image) and when clik a form with a calendar pops up? Alvin You can use a calendar in a user form. I have one in one of mine. Sorry I cant remember where I got it from but if I dblclick a text box on the user form a calendar pops up and I can insert a date which is then inserted into my spread sheet. By the way the calendar is another UserForm. Maybe if you do a search for userform calendar you will find one. sorry not much help. |
#9
Posted to microsoft.public.excel.misc
|
|||
|
|||
Calendar again
Ron de Bruin has some notes:
http://www.rondebruin.nl/calendar.htm alvin Kuiper wrote: Hi I know i can use a calendar in a sheet but can i use a calendar in a userform ? Maybe by a little icon (image) and when clik a form with a calendar pops up? Alvin -- Dave Peterson |
#10
Posted to microsoft.public.excel.misc
|
|||
|
|||
Calendar again
Everyone has their own style of using calendars.
What I do: To activate a calendar, click on a textbox, double-click a date and have that date put into the textbox... 1) Create a user Form and name it UfCalendar. 2) Put the following code in the form '/==========================================/ Private Sub UserForm_Activate() AXCalendar.Value = Now() End Sub '/==========================================/ Private Sub AXCalendar_DblClick() 'put selected date into registry SaveSetting AppName:="ActiveXCalendar", _ section:="Date", Key:="Value", _ setting:=AXCalendar.Value Unload UFCalendar End Sub '/==========================================/ 3) In the 'MouseDown' method of a textbox called TextBox1, put the following code... '/==========================================/ Private Sub TextBox1_MouseDown(ByVal Button As Integer, _ ByVal Shift As Integer, ByVal X As Single, _ ByVal Y As Single) 'show calendar UFCalendar.Show 'get date from registry and put in textbox Me.TextBox1.Value = GetSetting(AppName:="ActiveXCalendar", _ section:="Date", Key:="Value") End Sub '/==========================================/ -- Hope this helps. If it does, please click the Yes button. Thanks in advance for your feedback. Gary Brown "alvin Kuiper" wrote: Hi I know i can use a calendar in a sheet but can i use a calendar in a userform ? Maybe by a little icon (image) and when clik a form with a calendar pops up? Alvin |
#11
Posted to microsoft.public.excel.misc
|
|||
|
|||
Calendar again
Forgot to say..
Name the Calendar control 'AXCalendar' -- Hope this helps. If it does, please click the Yes button. Thanks in advance for your feedback. Gary Brown "Gary Brown" wrote: Everyone has their own style of using calendars. What I do: To activate a calendar, click on a textbox, double-click a date and have that date put into the textbox... 1) Create a user Form and name it UfCalendar. 2) Put the following code in the form '/==========================================/ Private Sub UserForm_Activate() AXCalendar.Value = Now() End Sub '/==========================================/ Private Sub AXCalendar_DblClick() 'put selected date into registry SaveSetting AppName:="ActiveXCalendar", _ section:="Date", Key:="Value", _ setting:=AXCalendar.Value Unload UFCalendar End Sub '/==========================================/ 3) In the 'MouseDown' method of a textbox called TextBox1, put the following code... '/==========================================/ Private Sub TextBox1_MouseDown(ByVal Button As Integer, _ ByVal Shift As Integer, ByVal X As Single, _ ByVal Y As Single) 'show calendar UFCalendar.Show 'get date from registry and put in textbox Me.TextBox1.Value = GetSetting(AppName:="ActiveXCalendar", _ section:="Date", Key:="Value") End Sub '/==========================================/ -- Hope this helps. If it does, please click the Yes button. Thanks in advance for your feedback. Gary Brown "alvin Kuiper" wrote: Hi I know i can use a calendar in a sheet but can i use a calendar in a userform ? Maybe by a little icon (image) and when clik a form with a calendar pops up? Alvin |
#12
Posted to microsoft.public.excel.misc
|
|||
|
|||
Calendar again
I'm not quite sure why you'd want to store and retrieve something from the
windows registry for getting a date from the user. And I'd use a Label, not a textbox. I'd want all the changes to that date to come from the calendar control. Gary Brown wrote: Everyone has their own style of using calendars. What I do: To activate a calendar, click on a textbox, double-click a date and have that date put into the textbox... 1) Create a user Form and name it UfCalendar. 2) Put the following code in the form '/==========================================/ Private Sub UserForm_Activate() AXCalendar.Value = Now() End Sub '/==========================================/ Private Sub AXCalendar_DblClick() 'put selected date into registry SaveSetting AppName:="ActiveXCalendar", _ section:="Date", Key:="Value", _ setting:=AXCalendar.Value Unload UFCalendar End Sub '/==========================================/ 3) In the 'MouseDown' method of a textbox called TextBox1, put the following code... '/==========================================/ Private Sub TextBox1_MouseDown(ByVal Button As Integer, _ ByVal Shift As Integer, ByVal X As Single, _ ByVal Y As Single) 'show calendar UFCalendar.Show 'get date from registry and put in textbox Me.TextBox1.Value = GetSetting(AppName:="ActiveXCalendar", _ section:="Date", Key:="Value") End Sub '/==========================================/ -- Hope this helps. If it does, please click the Yes button. Thanks in advance for your feedback. Gary Brown "alvin Kuiper" wrote: Hi I know i can use a calendar in a sheet but can i use a calendar in a userform ? Maybe by a little icon (image) and when clik a form with a calendar pops up? Alvin -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Convert date from Gregorian Calendar to Hijri Calendar | Excel Discussion (Misc queries) | |||
find free sharware to include calendar pop or use calendar in cell | Excel Discussion (Misc queries) | |||
how do i export excel calendar info to outlook calendar? | Excel Discussion (Misc queries) | |||
excel calendar - list of names displayed on calendar | Excel Worksheet Functions | |||
import calendar items from excel into outlook calendar | Excel Discussion (Misc queries) |