Results 1 to 8 of 8

Thread: Passing a variable from VB6 to Access

Threaded View

  1. #1

    Thread Starter
    New Member
    Join Date
    Aug 2007
    Posts
    14

    Passing a variable from VB6 to Access

    I'm sure this has been asked before, but couldn't find an answer using the search. What I need is to pass a varable from an inputbox to an access report, but not use it as a "where clause". The record I'll be printing should not be dependant on the value I enter, I just need that value in the corresponding place. The name of the Access report control is "periodche", the inputbox I'll be using is called "periodinp". I guess it will be something similar to this:
    vb Code:
    1. .DoCmd.OpenReport "kvit_plat_mqsto", acPreview, WhereCondition:="[periodche] = " & periodinp
    but as I said, it should not be a where clause and I can't make it up. Thanks in advance!

    I'm using Visual Basic 6 and Microsoft Access 2002.
    Last edited by veseo; Aug 28th, 2007 at 04:08 PM.

Posting Permissions

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



Click Here to Expand Forum to Full Width