Results 1 to 7 of 7
  1. #1
    snipe's Avatar
    snipe is offline Competent Performer
    Windows 7 64bit Access 2010 32bit
    Join Date
    Sep 2013
    Posts
    287

    How to set up a form that show past 6 months of data for a specific person + more


    Hey guys,

    I haven't had too much experience with advanced form creation.

    I am redesigning the payroll program that is 10 years old and entirely based in Excel. I have imported about 12 months of the data, for our 250 salesmen. The data has about 25+ fields, but only 10 are inputted by a human.

    The Main Menu form has a store selection, pay period selection (default value of the most recent), and salesperson selection. After these are chosen, the user hits the Submit button. This will bring up the input form.


    This is where I need the help. I want the input form to display the past 6 months of data for the selected salesman, but have it not be editable. Below that, I want an input area for the current pay period.

    I'm guessing that past 6 months will be done with a subform (which I have zero experience with), but I don't know how to get it only show specific data.

  2. #2
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    You can use a subform based on a query with a criteria on the date field of:

    Between DateAdd("m", -6, Date()) And Date()

    Set the appropriate properties on the Data tab of that subform's properties to make it read only.
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  3. #3
    snipe's Avatar
    snipe is offline Competent Performer
    Windows 7 64bit Access 2010 32bit
    Join Date
    Sep 2013
    Posts
    287
    Ah nice. I think I got it figured out. Appreciate the help!

  4. #4
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    No problemo!
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

  5. #5
    snipe's Avatar
    snipe is offline Competent Performer
    Windows 7 64bit Access 2010 32bit
    Join Date
    Sep 2013
    Posts
    287
    So I built a new form. I linked the employee ID in the form to the salesperson selection combo box on the main menu, and disabled edits and additions, and locked/disabled all fields. When I open this form, it works great. It shows the details of the past 12 pay periods.

    I inserted this form as a subform on my data entry form and linked the employee fields (also tried this with out linking anything). When I open the entry form, the subform is blank. What am I doing wrong?

  6. #6
    snipe's Avatar
    snipe is offline Competent Performer
    Windows 7 64bit Access 2010 32bit
    Join Date
    Sep 2013
    Posts
    287
    OH! Got it. All good!

  7. #7
    pbaldy's Avatar
    pbaldy is offline Who is John Galt?
    Windows XP Access 2007
    Join Date
    Feb 2010
    Location
    Nevada, USA
    Posts
    22,521
    Glad you got it sorted out!
    Paul (wino moderator)
    MS Access MVP 2007-2019
    www.BaldyWeb.com

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

Similar Threads

  1. Replies: 1
    Last Post: 02-01-2013, 03:23 PM
  2. clear past data during form open
    By newaccess in forum Forms
    Replies: 1
    Last Post: 01-09-2013, 10:55 AM
  3. Subreport will not show specific data
    By mitchy1111 in forum Reports
    Replies: 1
    Last Post: 05-18-2011, 07:36 AM
  4. Show past records for same user
    By l3111 in forum Database Design
    Replies: 3
    Last Post: 03-03-2011, 10:57 AM
  5. Replies: 1
    Last Post: 01-28-2011, 06:58 AM

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