J
JDP
I am trying to open a form from a command button.
This works fine.
Private Sub Go_To_Healthcare_Invoice_Click()
On Error GoTo Err_Go_To_Healthcare_Invoice_Click
Dim stDocName As String
Dim stLinkCriteria As String
Dim Service_Code As String
stDocName = "Healthcare Invoice Number Form and supp"
stLinkCriteria = "[Invoice_No]=" & "'" & Me!
[Invoice] & "'"
DoCmd.OpenForm stDocName, , , stLinkCriteria
....
I am trying to oepn one of several forms based upon the
value set for Service_Code. When I modify the code, he
button does not work. I want to get the code working for
the default condition before adding ELSEIF statements.
If "[Service_Code]" = "Consol" Then
stDocName = "Healthcare Invoice Number Form and
supp"
stLinkCriteria = "[Invoice_No]=" & "'" & Me!
[Invoice] & "'"
DoCmd.OpenForm stDocName, , , stLinkCriteria
End If
Thank you in advance, and any help would be appreciated.
This works fine.
Private Sub Go_To_Healthcare_Invoice_Click()
On Error GoTo Err_Go_To_Healthcare_Invoice_Click
Dim stDocName As String
Dim stLinkCriteria As String
Dim Service_Code As String
stDocName = "Healthcare Invoice Number Form and supp"
stLinkCriteria = "[Invoice_No]=" & "'" & Me!
[Invoice] & "'"
DoCmd.OpenForm stDocName, , , stLinkCriteria
....
I am trying to oepn one of several forms based upon the
value set for Service_Code. When I modify the code, he
button does not work. I want to get the code working for
the default condition before adding ELSEIF statements.
If "[Service_Code]" = "Consol" Then
stDocName = "Healthcare Invoice Number Form and
supp"
stLinkCriteria = "[Invoice_No]=" & "'" & Me!
[Invoice] & "'"
DoCmd.OpenForm stDocName, , , stLinkCriteria
End If
Thank you in advance, and any help would be appreciated.