Page 2 of 2 FirstFirst 12
Results 16 to 17 of 17
  1. #16
    dniezby is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Apr 2013
    Posts
    183
    I figured it out!!! WOW!

    Okay, so in the original form, the button that opens the pop-up form has this in the OnClick event.

    Code:
    Private Sub SMS_Email_Click()
    DoCmd.OpenForm "SMS Activity", acNormal, , , acFormAdd, 3, ID.Value
    End Sub
    Then in the form I open up I put this code in the OnLoad event.



    Code:
    Private Sub Form_Load()
        If Not IsNull(Me.OpenArgs) Then
            ContactID.Value = Me.OpenArgs
        End If
    End Sub
    Thanks for the discussion that led to this result.

  2. #17
    dniezby is offline Competent Performer
    Windows 10 Access 2016
    Join Date
    Apr 2013
    Posts
    183
    Quote Originally Posted by Missinglinq View Post
    For Option #2 here's an example...I believe I've got your names correct:

    In the Primary Form:

    Code:
    Private Sub Notes_Click()
    
     If Nz(Me.ID,"") <> "" Then
      DoCmd.OpenForm "SMS Activity", , , , , , Me.ID
     Else
      MsgBox "The ID Field Must Be Entered First!"
     End If
    
    End Sub


    In the Secondary Form:

    Code:
    Private Sub Form_Load()
    
        DoCmd.GoToRecord , , acNewRec
        
        If Nz(Me.OpenArgs,"") <> "" Then
          Me.ContactID = Me.OpenArgs
        End If
    
    End Sub

    Linq ;0)>
    Lol, looks like we were replying at the same time. Mine is a little different but it works.

Page 2 of 2 FirstFirst 12
Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 2
    Last Post: 10-25-2016, 04:09 PM
  2. Open a form based on a link in Subreport
    By RapidRepairArnold in forum Reports
    Replies: 6
    Last Post: 12-20-2012, 03:55 PM
  3. Open Form and Link To Specific Record
    By burrina in forum Forms
    Replies: 2
    Last Post: 12-17-2012, 11:09 PM
  4. Replies: 4
    Last Post: 12-21-2010, 11:32 AM
  5. Create an RDP link button on my form
    By BDP in forum Access
    Replies: 1
    Last Post: 09-14-2010, 02:49 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
  •  
Other Forums: Microsoft Office Forums