larrydavid
Programmer
Hello,
I have two forms which need to pass a value to a field on another form that open AfterUpdate():
Dim stDocName As String
Dim stLinkCriteria As String
If [refund reason] = "MCR" Then
Me.ComboChkReturnSource.RowSource = "tbl_Test_Source"
'Pass and populate the TESTVALUE in the Manual Request form.
'The opened form will grab the TESTVALUE value from this calling form.
stDocName = "frm_MCR_Input"
If IsNull(Me.TESTVALUE) = False Then
DoCmd.OpenForm stDocName, acNormal, , , acFormEdit, acWindowNormal
Else
MsgBox ("Please enter a valid TESTVALUE to proceed to Manual Check entry")
End If
Else
Me.ComboChkReturnSource.RowSource = "tbl_Test_Source_2"
End If
In the form that receives these values, I have this statement in the OnLoad():
Private Sub Form_Load()
DoCmd.GoToRecord , , acNewRec
Me.TESTVALUE.Value = [Form_frm_TEST_123].TESTVALUE Or _
Me.TESTVALUE.Value = [Form_frm_TEST_XYZ].TESTVALUE
End Sub
When I use the above method the application just hangs on "Calculating..."
I read an a couple of posts on using OpenArgs, but from what I read it was an error prone approach. If someone could show me a better way to handle this I would greatly appreciate it.
Thanks,
Larry
I have two forms which need to pass a value to a field on another form that open AfterUpdate():
Dim stDocName As String
Dim stLinkCriteria As String
If [refund reason] = "MCR" Then
Me.ComboChkReturnSource.RowSource = "tbl_Test_Source"
'Pass and populate the TESTVALUE in the Manual Request form.
'The opened form will grab the TESTVALUE value from this calling form.
stDocName = "frm_MCR_Input"
If IsNull(Me.TESTVALUE) = False Then
DoCmd.OpenForm stDocName, acNormal, , , acFormEdit, acWindowNormal
Else
MsgBox ("Please enter a valid TESTVALUE to proceed to Manual Check entry")
End If
Else
Me.ComboChkReturnSource.RowSource = "tbl_Test_Source_2"
End If
In the form that receives these values, I have this statement in the OnLoad():
Private Sub Form_Load()
DoCmd.GoToRecord , , acNewRec
Me.TESTVALUE.Value = [Form_frm_TEST_123].TESTVALUE Or _
Me.TESTVALUE.Value = [Form_frm_TEST_XYZ].TESTVALUE
End Sub
When I use the above method the application just hangs on "Calculating..."
I read an a couple of posts on using OpenArgs, but from what I read it was an error prone approach. If someone could show me a better way to handle this I would greatly appreciate it.
Thanks,
Larry