Expand|Select|Wrap|Line Numbers
- Private Sub Command118_Click()
- 'Create var.Dim intChk As Integer
- 'This line counts the number of rec instances in TBLUser.
- intChk = DCount("*", "TBLUser", "[UserID]" = "'" & Forms!FrmCreateNewLaptopProfileForBookings!UserID & "'")
- 'Does the rec exist? If not then open FRMCreateNewUserWhileBooking to add the new user details.
- If intChk = 0 Then 'No?
- DoCmd.OpenForm "FRMCreateNewUserWhileBooking", , , , acFormAdd
- End If
- End Sub
Expand|Select|Wrap|Line Numbers
- Else
- If intChk > 0 Then
- SetFocus Me!Barcode
Many Many thanks for your help and patience with a newbie!!Robert