I can not seem to get rid of this syntax error - hope someone can help out.
the error I am getting is:
Run time Error 3075
Syntax error missing operator in query expression
[AcctHolderID]=name
I have two forms (1) one with a combo box "cbobankacc t" on form "accttransactio nlist"
I am successful to have the value from the combo box generate into a text box of a second form.
second form "accttranslistp assword" and the text box that I am trying to generate the value into is "txtaccthol der.
the value seems to imput in the text box fine but I get the syntax error when I try to run the password script.
I then have a text box "txtpasswor d" that I input the password into and that is when I get the syntax error
If anyone can give me some direction that would be great! Everyone on this site has always been very helpful in the past.
Thanks
Gary
the error I am getting is:
Run time Error 3075
Syntax error missing operator in query expression
[AcctHolderID]=name
I have two forms (1) one with a combo box "cbobankacc t" on form "accttransactio nlist"
I am successful to have the value from the combo box generate into a text box of a second form.
second form "accttranslistp assword" and the text box that I am trying to generate the value into is "txtaccthol der.
the value seems to imput in the text box fine but I get the syntax error when I try to run the password script.
Code:
Private Sub cbobankacct_AfterUpdate()
DoCmd.OpenForm "AcctTransListPassword"
Forms!AcctTransListPassword!txtacctholder = Forms!AcctTransactionList!cbobankacct.Column(1)
End Sub
Code:
Private Sub txtpassword_AfterUpdate()
If IsNull(Me.txtpassword) Or Me.txtpassword = "" Then
MsgBox "You must enter a Password.", vbOKOnly, "Required Data"
Me.txtpassword.SetFocus
Exit Sub
End If
If Me.txtpassword.value = DLookup("Password", "AcctHolder", _
"[AcctHolderID]=" & Me.txtacctholder.value) Then
MyAcctHolderID = Me.txtacctholder.value
DoCmd.Close acForm, "AcctTransListPassword", acSaveNo
DoCmd.RunMacro "AcctHolderMDB"
Else
MsgBox "Password Invalid. Please Try Again", vbOKOnly, _
"Invalid Entry!"
Me.txtpassword.SetFocus
End If
End Sub
Thanks
Gary
Comment