Results 1 to 3 of 3

Thread: Calendar form

  1. #1
    Join Date
    May 2014

    Lightbulb Unanswered: Calendar form

    Hi my friends
    Can anyone help me with creating a form is access 2007 that contains a calendar that can filter data?
    What I want it to do is when I click on a date on the calendar, I want it to filter all data that contains the date I picked and show it in a sub form.

    Your help and advise is appreciated In advance
    Many thanks

  2. #2
    Join Date
    Jun 2005
    Richmond, Virginia USA
    Provided Answers: 19
    As is usually the case, there are a number of ways to do this. Assuming that you already have a Form to display the Records:
    1. Place an Unbound Textbox in the Header
    2. Name it TargetDate
    3. Go to Properties - Format
    4. Set Format as Short Date
    5. Add a Command Button to the Header
    6. Name it btnSearchDates
    7. Use the code below in its OnClick event

    Private Sub btnSearchDates_Click()
     Me.Filter = "YourDateField = #" & Me.TargetDate & "#"
     Me.FilterOn = True
    End Sub

    Replace YourDateField with the actual name of the date field that you are filtering on.

    Use the Calendar Icon attached to the Textbox to select your date and click the Command Button.

    Alternatively, you could use something like Allen Browne's Popup-Form based calendar and the same thing:

    Microsoft Access tips: Popup Calendar

    Linq ;0)>
    Last edited by Missinglinq; 05-19-14 at 22:23.
    Hope this helps!

    The problem with making anything that fools are so darn ingenious!

    All posts/responses based on Access 2003/2007

  3. #3
    Join Date
    May 2014

    Thumbs up Calendar form

    Thanks so much for your reply.

    Very useful
    I think what I was looking for was something like Allen Browne's Popup-Form.

    I will have a go at that and keep you posted.

    Many thanks again

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts