Pop Up Calendar

sdzc

Registered User.
Local time
Yesterday, 21:46
Joined
Mar 27, 2004
Messages
46
I have a question that I hope you guys can help answer as recently found this forum and it has helped me already.
I am an Access beginner, but have designed and redesigned several databases using the tools available within Access for Forms/Tables/Queries, etc. I am very limited when it comes to VBA/Code stuff.

My question: I have downloaded several Calendar functions from this site (thanks Mile-O-Phile), but cannot :confused: get them to work in my database. I know I have to do more than just import the forms and modules, but I cannot figure it out. What do I have to change in the module or form to get my database to recognize the calendar?

I should also add that I am using Access 2K.

I thank you in advance for any help!!!
 
Last edited:
Follow the code in the 2 attachments for clues. When you start using VBA dont be afraid to type in what you think will work even if you are not sure of the syntax. When you compile the code, any errors will be highlighted.

Dave
 
Hi and thanks for post this Calendar mod. It Great.

I have used it in my database with no errors.

I would like to use it just as a popup calendar but when I do I get an error that states "invalid use of Null". Is there a way to stop this happening without screwing up the intended use.

Kind regards.


Dereck
 
Where is the variable declared?
1...
Change the code from Dim ..... as date to Dim .... as Variant.
A variant will handle nulls.
2....
Be sure you have error handling. If you are confident put on the second line of the procedure:
On Error Resume Next
This will skip the line the error is in and carry on.
3...
Correct Error Handling:

Private Sub cmdButton_Click
On Error Goto Err_cmdButton_Click

'Code that produces a null error (Err.Number 94)

Exit_cmdButton_Click:
Exit Sub

Err_cmdButton_Click:
Select Case Err.Number
Case 94 '(Null)
Resume Exit_cmdButton_Click
Case Else
Msgbox Err.Number & " - " & Err.Description
Resume Exit_cmdButton_Click
End Select

End Sub


HTH
Dave
 
Thanks Dave, I will give it a try.

Keep safe and well.

Kind Regards

Dereck
 

Users who are viewing this thread

Back
Top Bottom