Results 1 to 2 of 2
  1. #1
    Join Date
    May 2002
    Central California

    Unanswered: DoCmd.OpenReport WhereCondition prblms

    I am trying to utilize two simple where conditions populated by a click on a listbox and on the second one a query window pops up with my selected variable?

    For example I click on a listbox to get the "intPosCrnt" value and then click on another list box to get the "strStat" value. I display the the following string in a label box to see what is happening and it looks great. However, on the DoCmd a window pops up with the value I selected in the second listbox as the query name. Wow, what is happening?

    strTest = "APPosID = " & intPosCrnt & " AND AppPos!Status = " & strStat

    .DoCmd.OpenReport "AppPosStatus", acViewNormal, , WhereCondition:="" & strTest

  2. #2
    Join Date
    Jan 2002
    What's this AppPos!Status in your where condition. I don't think it should be there. Remove AppPos!.


Posting Permissions

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