473,799 Members | 2,942 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Auto Update Month in Calendar

I am currently using the Active X Calendar object in a form to select
the dates. The problem I am having is when the month changes the
calendar continues to display the previous month. How can I set this
to change automatically? Access 2000.
Nov 12 '05 #1
4 2319
Hi Rudy,

Set the value of the calendar to today's date in the Form Load event
Private Sub Form_Load()
MyCal.Value = Date

End Sub

Don

"rudy" <rc******@satx. rr.com> wrote in message
news:8b******** *************** **@posting.goog le.com...
I am currently using the Active X Calendar object in a form to select
the dates. The problem I am having is when the month changes the
calendar continues to display the previous month. How can I set this
to change automatically? Access 2000.

Nov 12 '05 #2
I am new to adding code, can you tell me if the code you provided is
simply copied or additional references to form names or object names
need to be included? I copied the code as indicated and I get an
error that highlights the 'MyCal.Value = Date' section.

Thanks,
Rudy

"Don Leverton" <le************ ****@telusplane t.net> wrote in message news:<4qWqc.396 4$g71.3524@clgr ps13>...
Hi Rudy,

Set the value of the calendar to today's date in the Form Load event
Private Sub Form_Load()
MyCal.Value = Date

End Sub

Don

"rudy" <rc******@satx. rr.com> wrote in message
news:8b******** *************** **@posting.goog le.com...
I am currently using the Active X Calendar object in a form to select
the dates. The problem I am having is when the month changes the
calendar continues to display the previous month. How can I set this
to change automatically? Access 2000.

Nov 12 '05 #3
Hi Rudy,

You'll have to either rename your ActiveX Calendar from the default (usually
something like "ActiveXCtl 3") to "MyCal" or substitute that default name of
the calendar into the code.

i.e.
Private Sub Form_Load()
ActiveXCtl3.Val ue = Date

End Sub

"rudy" <rc******@satx. rr.com> wrote in message
news:8b******** *************** ***@posting.goo gle.com...
I am new to adding code, can you tell me if the code you provided is
simply copied or additional references to form names or object names
need to be included? I copied the code as indicated and I get an
error that highlights the 'MyCal.Value = Date' section.

Thanks,
Rudy

"Don Leverton" <le************ ****@telusplane t.net> wrote in message

news:<4qWqc.396 4$g71.3524@clgr ps13>...
Hi Rudy,

Set the value of the calendar to today's date in the Form Load event
Private Sub Form_Load()
MyCal.Value = Date

End Sub

Don

"rudy" <rc******@satx. rr.com> wrote in message
news:8b******** *************** **@posting.goog le.com...
I am currently using the Active X Calendar object in a form to select
the dates. The problem I am having is when the month changes the
calendar continues to display the previous month. How can I set this
to change automatically? Access 2000.

Nov 12 '05 #4
Thanks alot Don, it worked!

"Don Leverton" <le************ ****@telusplane t.net> wrote in message news:<Je7rc.850 $gx1.830@clgrps 12>...
Hi Rudy,

You'll have to either rename your ActiveX Calendar from the default (usually
something like "ActiveXCtl 3") to "MyCal" or substitute that default name of
the calendar into the code.

i.e.
Private Sub Form_Load()
ActiveXCtl3.Val ue = Date

End Sub

"rudy" <rc******@satx. rr.com> wrote in message
news:8b******** *************** ***@posting.goo gle.com...
I am new to adding code, can you tell me if the code you provided is
simply copied or additional references to form names or object names
need to be included? I copied the code as indicated and I get an
error that highlights the 'MyCal.Value = Date' section.

Thanks,
Rudy

"Don Leverton" <le************ ****@telusplane t.net> wrote in message

news:<4qWqc.396 4$g71.3524@clgr ps13>...
Hi Rudy,

Set the value of the calendar to today's date in the Form Load event
Private Sub Form_Load()
MyCal.Value = Date

End Sub

Don

"rudy" <rc******@satx. rr.com> wrote in message
news:8b******** *************** **@posting.goog le.com...
> I am currently using the Active X Calendar object in a form to select
> the dates. The problem I am having is when the month changes the
> calendar continues to display the previous month. How can I set this
> to change automatically? Access 2000.

Nov 13 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
6978
by: bb | last post by:
any way to prevent displaying the previous and next months in the calendar control? i have tried just blanking the text out in the dayrender IsOtherMonth and also dynamically changing the FirstDayOfWeek to day 1 of the month. but neither works properly. (the boxes still appear just with no text in them) i want the calendar to start on day 1 of month and end on Day 31 (with acceptable trailing blanks between day 31 and the end of that...
1
3436
by: John Davis | last post by:
I am writing a program that allows user to select the date in a calendar, and it will update the text fields automatically. I created 2 forms. The first form has 2 text fields (start date and end date), and 2 buttons. When the user clicks the button, it will invoke the calendar form. Here's the code fragment for the first form: Private Sub Command1_Click() Dim instanceCalendarForm As CalendarForm Set instanceCalendarForm = New...
34
9301
by: prosoft | last post by:
When I use Dim myDTFI As DateTimeFormatInfo = New CultureInfo("he-IL", True).DateTimeFormat Dim strhmon1 As String = (myDTFI.GetMonthName(hmon1)) MsgBox(strhmon1) I get the local name of the gregorian month. How do I get the local name of the local month ? Tia
4
6700
by: Jason Chan | last post by:
How can I get the month and year a calendar control current displaying? My problem is I want to load a list of event to a calendar so that it display difference style if there a event for a day. My initial idea is load all events from database and store it in a DataTable. In the DayRender event, loop thr the DataTable and see if it equal to e.Day and alter the style if that is. However when the event table is large, it hurt...
0
1906
by: larry | last post by:
I am in the process of rewriting one of my first PHP scripts, an event calendar, and wanted to share the code that is the core of the new calendar. My current/previous calendar processed data dates only, this code is intended to use more thrifty event descriptions (3rd saturday, last tuesday, etc.) as well as traditional one-of dates. The core here here is quite spartan, no table logic or or db cruft included (I figure you have our own...
6
3272
by: Zeba | last post by:
Hi, I have a page with a calendar and two datalist items - one containing month values and the other, year values. Depending on the month/year value chosen ( in text/string format ) I should be able to display the correct month of the calendar. I thought it would be possible to use the OnSelectedIndexChanged attribute of the dropdown list to call a javascript function that sets the month value of the calendar...Something like :
7
3830
by: ajaydesai | last post by:
I have JavaScript code to dispaly two month calendar days at a time, but i have a problem both month that disaplay at a time have same days (for example May and June has same days, June and July have same days etc.) Instate of correct days. Here is my code from 3 files. *************************************************************************************** calendr.js file: isIE = (document.all ? true : false); isDOM =...
5
2599
by: =?Utf-8?B?bWFib25k?= | last post by:
Hi Using a month calendar control so that my user can select a start and end date for a range that will be used in a SQL query. Problem.....if user selects a date in one month and then scrolls to the next month the "date" moves with the scroll......i.e. click on 3rd Feb and then move to March, without any further selection being clicked the selected date has become 3rd March....
2
2640
by: sirdavethebrave | last post by:
Hi guys - I have written a form, and a stored procedure to update the said form. It really is as simple as that. A user can go into the form, update some fields and hit the update button to update the information which is stored in a SQL database. In testing we noticed that the form was updating correctly but the update mechanism was also updating the first record of the table in the sql database every time. No error messages are on...
0
9685
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9538
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10249
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10219
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
7563
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5584
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4138
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3755
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2937
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.