Results 1 to 5 of 5
  1. #1
    fluffyvampirekitten is offline Competent Performer
    Windows 7 64bit Access 2013
    Join Date
    Jun 2015
    Posts
    108

    Question How to filter Graph data analysis by date range (Start Date to End Date)

    How can I filter graph data ..


    I want
    1) Button Update Range (of the graph) e.g Start date: Jan 2014 to End Date: Dec 2014
    2.) Then it will automatiacally the analysis thru bar chart.


    Thanks in advance

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    8,466
    Make a report form, frmRpts
    on it are 2 text boxes named, txtStartDate, txtEndDate
    in the query the chart uses, the criteria would have
    select * from table where [date] between forms!frmRps!txtStartDate and forms!frmRps!txtEndDate
    Just to be safe, in the parameters property of the query put : forms!frmRps!txtStartDate as date , (same w end date)

    a list box of reports you want to print, select from the list (your chart) , lstReports

    the button on the form to open the report, docmd.openreport lstReports

  3. #3
    fluffyvampirekitten is offline Competent Performer
    Windows 7 64bit Access 2013
    Join Date
    Jun 2015
    Posts
    108
    Quote Originally Posted by ranman256 View Post
    Make a report form, frmRpts
    on it are 2 text boxes named, txtStartDate, txtEndDate
    in the query the chart uses, the criteria would have
    select * from table where [date] between forms!frmRps!txtStartDate and forms!frmRps!txtEndDate
    Just to be safe, in the parameters property of the query put : forms!frmRps!txtStartDate as date , (same w end date)

    a list box of reports you want to print, select from the list (your chart) , lstReports

    the button on the form to open the report, docmd.openreport lstReports

    Thanks! However , I have a form with a chart on it. Above it is a button to go to another page to allow user to click on the start and end date.
    I tried to apply the same concept of what you have told me .
    However a dialog box keep appearing

    Click image for larger version. 

Name:	Capture.JPG 
Views:	21 
Size:	17.5 KB 
ID:	21676

    Code:
    PARAMETERS [Forms]![Summary_Range]![cboStartRange] DateTime, [Forms]![Summary_Range]![cboEndRange] DateTime;
    TRANSFORM Sum(Summary.No_of_Recordset) AS SumOfNo_of_Recordset
    SELECT Summary.Record_Period
    FROM Summary
    WHERE (((Summary.Record_Period) Between [Forms]![Summary_Range]![cboStartRange] And [Forms]![Summary_Range]![cboEndRange]))
    GROUP BY Summary.Record_Period
    PIVOT Summary.Category;
    For Parameters , I couldn't find the data type "Date"
    Click image for larger version. 

Name:	Capture1.JPG 
Views:	21 
Size:	29.1 KB 
ID:	21677
    Last edited by fluffyvampirekitten; 08-18-2015 at 02:17 AM.

  4. #4
    fluffyvampirekitten is offline Competent Performer
    Windows 7 64bit Access 2013
    Join Date
    Jun 2015
    Posts
    108
    Quote Originally Posted by ranman256 View Post
    Make a report form, frmRpts
    on it are 2 text boxes named, txtStartDate, txtEndDate
    in the query the chart uses, the criteria would have
    select * from table where [date] between forms!frmRps!txtStartDate and forms!frmRps!txtEndDate
    Just to be safe, in the parameters property of the query put : forms!frmRps!txtStartDate as date , (same w end date)

    a list box of reports you want to print, select from the list (your chart) , lstReports

    the button on the form to open the report, docmd.openreport lstReports
    hahaha! I fixed it . Thank you so much for the help!!!! Been trying to solve this prob for a few days already ! Appreciated your help and guidance

  5. #5
    cap.zadi is offline Competent Performer
    Windows 7 32bit Access 2010 32bit
    Join Date
    May 2011
    Location
    KSA
    Posts
    481
    Hi

    Thanks for the post and discussion.

    I have been looking for the same kind of material.

    Can you illustrate lit bit more for better understanding of this?

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 3
    Last Post: 01-21-2015, 02:40 PM
  2. Replies: 12
    Last Post: 01-23-2014, 03:24 PM
  3. Graph date range from query
    By dhicks19 in forum Access
    Replies: 1
    Last Post: 06-29-2012, 12:26 AM
  4. Replies: 15
    Last Post: 04-06-2012, 10:57 AM
  5. Replies: 1
    Last Post: 07-07-2010, 04:22 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums - Senior Forums