Hello,
I'm currently using this bit of code previously provided by a helpful someone to open two forms for data entry on one page (i.e. Choose A, choose B, click open and form (built with two blank subforms) opens with FormA next to FormB):
Private Sub Form_Load()
Dim arrSplit As Variant
With Me
If Len(Nz(.OpenArgs)) <> 0 Then
arrSplit = Split(.OpenArgs, "|")
.FormA.SourceObject = arrSplit(0)
.FormB.SourceObject = arrSplit(1)
End If
End With
End Sub
I was looking to slightly modify this on a form where I have subforms within a tabbed control. Meaning I would now like the page to open with four forms - two subforms on each tab. Can someone help me with how to modify the referencing in the code to do this? Right now the button/on click code looks like:
If Me.ComboDiscipline = "ADP" And Me.ComboState = "Alabama" Then
DoCmd.OpenForm "FrmMain", , , , , , "FrmEntryADPField|FrmAlabama"
I'm currently using this bit of code previously provided by a helpful someone to open two forms for data entry on one page (i.e. Choose A, choose B, click open and form (built with two blank subforms) opens with FormA next to FormB):
Private Sub Form_Load()
Dim arrSplit As Variant
With Me
If Len(Nz(.OpenArgs)) <> 0 Then
arrSplit = Split(.OpenArgs, "|")
.FormA.SourceObject = arrSplit(0)
.FormB.SourceObject = arrSplit(1)
End If
End With
End Sub
I was looking to slightly modify this on a form where I have subforms within a tabbed control. Meaning I would now like the page to open with four forms - two subforms on each tab. Can someone help me with how to modify the referencing in the code to do this? Right now the button/on click code looks like:
If Me.ComboDiscipline = "ADP" And Me.ComboState = "Alabama" Then
DoCmd.OpenForm "FrmMain", , , , , , "FrmEntryADPField|FrmAlabama"