Run parameter query using VBA

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Gerry Goldberg
    New Member
    • Jul 2010
    • 11

    Run parameter query using VBA

    I am trying to learn to user Parameter queries. My simple test query is:
    PARAMETER [Account] CHAR ;
    SELECT * FROM tblAccount WHERE [Account] = "123456"

    In my VBA code, I have determined that I want to run this query with [Account] = "654321"

    How to I put this in code? Does the query have to be stored in QueryDefs?

    Thanks,

    Gerry Goldberg
Working...