If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Link Forms with multiple fields
Any ideas why I get a 'Type mismatch' error with this code that I using to
open a second form linking multiple fields? Private Sub cmdUpdatePhone_Click() On Error GoTo Err_cmdUpdatePhone_Click Dim stDocName As String Dim stLinkCriteria As String stDocName = "frmEdit Location Phone Numbers" stLinkCriteria = "[Location Name]=" & "'" & Me![Location Name] & "'" And "[Position Code]=" & "'" & Me![Position Code] & "'" DoCmd.OpenForm stDocName, , , stLinkCriteria Exit_cmdUpdatePhone_Click: Exit Sub Err_cmdUpdatePhone_Click: MsgBox Err.Description Resume Exit_cmdUpdatePhone_Click End Sub -- Message posted via AccessMonster.com http://www.accessmonster.com/Uwe/For...forms/201004/1 |
Thread Tools | |
Display Modes | |
|
|