G
Guest
Can someone please tell me wut I am doing wrong... :/
I get "Compile Error: Invalid Qualifier" whenever I run the following code:
Private Sub add_customer_Click() <<<<Debugger highlights this yellow<<<<<<
Dim db As DAO.Database
Dim rctCustomersAdd As DAO.Recordset
'*** Create a pointer to the database and a pointer to the table ***
Set db = CurrentDb()
Set rctCustomersAdd = db.OpenRecordset("tblCustomers", dbOpenTable)
' ***************************************Validate the Name field***
If IsNull(name) Or Len(name) = 0 Then
MsgBox "Please Enter a Name"
name.SetFocus <<<<<<<Also "name" is highlighted<<<<<<<<<<<<<
rctCustomersAdd.Close
db.Close
Exit Sub
End If
I get "Compile Error: Invalid Qualifier" whenever I run the following code:
Private Sub add_customer_Click() <<<<Debugger highlights this yellow<<<<<<
Dim db As DAO.Database
Dim rctCustomersAdd As DAO.Recordset
'*** Create a pointer to the database and a pointer to the table ***
Set db = CurrentDb()
Set rctCustomersAdd = db.OpenRecordset("tblCustomers", dbOpenTable)
' ***************************************Validate the Name field***
If IsNull(name) Or Len(name) = 0 Then
MsgBox "Please Enter a Name"
name.SetFocus <<<<<<<Also "name" is highlighted<<<<<<<<<<<<<
rctCustomersAdd.Close
db.Close
Exit Sub
End If