Using a form to query a range of dates for a web access database

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • rich1838
    New Member
    • Dec 2012
    • 21

    Using a form to query a range of dates for a web access database

    I have an access DB that uses a form to query a range of dates in order to provide results. In the critereia for the query date field, I have Between [Forms]![reportcenter]![Text46] And [Forms]![reportcenter]![Text48]. This works perfectly.
    I am now moving this to a web access database. I understand that web queries cannot use forms, so in a macro I entered in the where condition [completeduesque ry]![Pay Date]>= [Text46] <= [Text48.
    I also tried [completeduesque ry]![Pay Date]Between [Text46] AND [Text48.

    I keep getting- You either have an error in your expression or you have attempted to use an undeclared parameter. Check the expression for errors or enter the parameter '[Text46]' in the Query parameters dialog. [Text46] is in the parameters dialog so I'm stumped!
  • NeoPa
    Recognized Expert Moderator MVP
    • Oct 2006
    • 32645

    #2
    I'm not sure what your work is in Rich, but it's not Access (even if talking to an Access database is included in your code somewhere). If you let me know what language you are working in I can move it to the relevant forum for you.

    Comment

    • zmbd
      Recognized Expert Moderator Expert
      • Mar 2012
      • 5501

      #3
      In the critereia for the query date field, I have Between [Forms]![reportcenter]![Text46] And [Forms]![reportcenter]![Text48]
      Just to be sure that we're on the same page... and I'm Chemist with a new infant in the house; thus, a tad slow on the uptake...

      You created a query.
      In design mode of the query, you entered the above quoted text into one of the rows below the date field.

      Is that correct?

      If so, then, you'll find the following worth a careful read:
      Access 2010: How to write expressions for Web queries, forms, and reports

      Also, it would be helpful to know the Version of Office, Access, and the Operating System.

      Comment

      • zmbd
        Recognized Expert Moderator Expert
        • Mar 2012
        • 5501

        #4
        I just ran across this information that you might find usful too:
        Build an Access database to share on the Web

        Comment

        • zmbd
          Recognized Expert Moderator Expert
          • Mar 2012
          • 5501

          #5
          Would you mind posting the steps you took that solved your problem, please?

          Comment

          Working...