Results 1 to 5 of 5
  1. #1
    Join Date
    May 2003
    Posts
    14

    Unanswered: Passing Multiple Fields

    I want to pass two data fields (Id Number & Job Number) from one form
    to another. Any suggestions will be appreciated.

    Thanks In advance.

  2. #2
    Join Date
    Sep 2003
    Location
    MI
    Posts
    3,713
    You can pull the data from those fields from the called form or you can use the OpenArgs parameter of the OpenForm method (depending on Access version ... )

  3. #3
    Join Date
    May 2003
    Posts
    14
    Originally posted by M Owen
    You can pull the data from those fields from the called form or you can use the OpenArgs parameter of the OpenForm method (depending on Access version ... )
    Thanks for your reply. I tried that with the following:

    stLinkCriteria = "[RV_IDNumber]=" & "'" & Me![CM_IDNumber] & "'" & "[RV_JobNumber]=" & "'" & Me![CM_JobNumber] = " & " '"

    DoCmd.OpenForm stDocName, , , stLinkCriteria, , , Me![CM_IDNumber] & [CM_JobNumber

    and in the called program under the event Activate, I put the following:

    Me!RV_IDNumber = Left$(strArgs, InStr(0, strArgs, ";") - 0)
    Me!RV_JobNumber = Left$(strArgs, InStr(1, strArgs, ";") - 1)

    It's not working. I'm not sure if I have then formatted right.

  4. #4
    Join Date
    Oct 2003
    Location
    Roanoke, Va
    Posts
    445
    Originally posted by calprof
    Thanks for your reply. I tried that with the following:

    stLinkCriteria = "[RV_IDNumber]=" & "'" & Me![CM_IDNumber] & "'" & "[RV_JobNumber]=" & "'" & Me![CM_JobNumber] = " & " '"

    DoCmd.OpenForm stDocName, , , stLinkCriteria, , , Me![CM_IDNumber] & [CM_JobNumber

    and in the called program under the event Activate, I put the following:

    Me!RV_IDNumber = Left$(strArgs, InStr(0, strArgs, ";") - 0)
    Me!RV_JobNumber = Left$(strArgs, InStr(1, strArgs, ";") - 1)

    It's not working. I'm not sure if I have then formatted right.
    Try

    stLinkCriteria = "[RV_IDNumber] = " & Me.[CM_IDNumber] & " And [RV_JobNumber] = " & Me.[CM_JobNumber]

    DoCmd.OpenForm strDocName, , , stLinkCriteria

  5. #5
    Join Date
    May 2003
    Posts
    14
    Originally posted by basicmek
    Try

    stLinkCriteria = "[RV_IDNumber] = " & Me.[CM_IDNumber] & " And [RV_JobNumber] = " & Me.[CM_JobNumber]

    DoCmd.OpenForm strDocName, , , stLinkCriteria


    Thanks! I'll give it a try.

Posting Permissions

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