Calendar in SubForm

I am trying to implement a calendar via a subform. I found this demo on the msdn. However I don't want the text box to be updated when the Month and Year increment and decrement buttons are pressed. I only want to update the text box when the date is actually clicked. I am not sure what I need to modify to fix this.
CalendarDemo.zip
threeiengAsked:
Who is Participating?
 
conagramanConnect With a Mentor Commented:
wait i take that all back : ) i got it


ok i added a global integer variable "wasClicked"
 in the handleselected function i set that variable "wasClicked" to =1
last in the calendarForm_DateChanged sub i put an if then statement.


yea!...


CalendarDemo.mdb
0
 
Rey Obrero (Capricorn1)Commented:
0
 
threeiengAuthor Commented:
This will be used in Access 2010 so it cannot use the Calendar Control since its not supported in 2010.
0
Cloud Class® Course: Certified Penetration Testing

This CPTE Certified Penetration Testing Engineer course covers everything you need to know about becoming a Certified Penetration Testing Engineer. Career Path: Professional roles include Ethical Hackers, Security Consultants, System Administrators, and Chief Security Officers.

 
Rey Obrero (Capricorn1)Commented:
it really helps when you give all the information in the original post.
saves time and effort
0
 
threeiengAuthor Commented:
Sorry for leaving that out.  I asked what needs to be modified in the uploaded database so I didn't think Access version was important.
0
 
conagramanCommented:
threeieng-

just delete the arrow buttons on the formCalendar
0
 
conagramanCommented:
here is your database. i did a couple things to it

like i said before i deleted the arrows but i also got rid of the list box and set the properties of the date textbox to:
enabled =false
locked = true
i did this to keep the default calendar from poping up

in the calendar form i set the key down event to
keycode = 0
this way the user will have to click on the date


CalendarDemo.mdb
0
 
conagramanCommented:
i guess thats what you want to do?
0
 
threeiengAuthor Commented:
The user will still need to ability to increment or decrement the month and year though.
0
 
conagramanCommented:
threeieng

the answer to your question is your current calendar in your uploaded database can not be modified to do what you want it to do.

what i have found is that you will need to use a different calendar. this calendar will not function the way you want it to.  you would need to be able to access the onclick event of the form frmCalendar. if you put code into the onclick event of your current calendar it wont get fired because every control already has an onclick event.

keep in mind when you click in your birthday textbox the little built in calendar will pop up and acts like you have described. just giving you an option.
im sure there are other calendars out there that will work.
0
 
threeiengAuthor Commented:
Thank you very much for going the extra mile conagraman!!
0
 
conagramanCommented:
: )
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.