Results 1 to 2 of 2
  1. #1
    Join Date
    Apr 2012

    Unanswered: Command Button to Open a New form


    I have a form called VOLUNTEERS DETAIL, and the concept is to use the form to enter the volunteers info. Then I want a command button at the bottom of the form so that when you click it, it will open a different form called SHIFTS. I can use the DoCmd.OpenForm method easily, however, I want the SHIFTS form to open to the Record that was open in the VOLUNTEERS DETAIL form. The two forms connect on the field called VolunteerID.

    This is the code I have so far...I'm not quite sure that the OpenArgs should be.

    Private Sub Assign_Shifts_Click()
    DoCmd.OpenForm "Shifts", acNormal, , , , acDialog, ""

    End Sub

  2. #2
    Join Date
    Mar 2009
    Provided Answers: 14
    DoCmd.OpenForm "Shifts", , , "VolunteerID=" & Me.VolunteerID, , acDialog
    Have a nice day!

Tags for this Thread

Posting Permissions

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