Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / New Users / February 2006

Tip: Looking for answers? Try searching our database.

Help with VB code for Calendar

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Stibbz - 25 Feb 2006 17:31 GMT
I have inputted the code for a calendar however it doesn't work when I use
this validation '=DateAdd("d",7,Date()) And <=DateAdd("m",2,Date())'

The code I used was

Option Compare Database

Private Sub Calendar2_Click()
 Event_Date.Value = Calendar2.Value***
 Event_Date.SetFocus
 Calendar2.Visible = False
End Sub

Private Sub Event_Date_MouseDown(Button As Integer, Shift As Integer, X As
Single, Y As Single)
   Calendar2.Visible = True
   Calendar2.SetFocus
   If Not IsNull(Event_Date) Then
      Calendar2.Value = Event_Date.Value
   Else
      Calendar2.Value = Date
   End If
End Sub

If anyone could help me out with corecting this code so that the calendar
will work with the validation I would be very grateful

The line that the debugger higlights is the starred line above***
Larry Daugherty - 25 Feb 2006 20:45 GMT
maybe   Event_Date.Value = me!Calendar2.Value

Signature

-Larry-
--

> I have inputted the code for a calendar however it doesn't work when I use
> this validation '=DateAdd("d",7,Date()) And <=DateAdd("m",2,Date())'
[quoted text clipped - 24 lines]
>
> The line that the debugger higlights is the starred line above***
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.