Hi!
I am assuming that you will do this in code probably with the click of a button. If so, use this code:
Dim sql As String
Dim rst As DAO.Recordset
sql = "Select ID From Tbl1 Where ID = '" & txtID & "'"
Set rst = CurrentDb.OpenRecordset(sql, dbOpenDynaset)
If rst.EOF = True And rst.BOF = True Then
DoCmd.OpenForm "YourForm", , , , acFormAdd
Else
sql = "ID = '" & txtID & "'"
DoCmd.OpenForm "YourForm", , , , , sql
End If
The code above assumes that your ID field is text, if it is numeric then leave out the single quotes.
hth
Jeff Bridgham
bridgham@purdue.edu