none
passing parameters in access RRS feed

  • Question

  • It's been awhile since I have worked with access but I have 2 forms, formA and formB. All I want to do is pass 1 value from formA  to be used in the sql query of formB.

    Thursday, March 23, 2017 2:35 PM

All replies

  • There are many ways. The exact one depends on the finer points of your requirements. Since we don't know those, here is a simple one:
    Create the query for formB. In the criteria for some field write:
    Forms!formA!someControlOnFormA


    -Tom. Microsoft Access MVP

    Thursday, March 23, 2017 2:38 PM
  • Hi,

    If FormA is open when you open FormB, then you can simply reference FormA. For example:

    Forms!FormA.TextboxName

    Hope it helps...

    Thursday, March 23, 2017 2:38 PM