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 "cbobankacct" on form "accttransactionlist"
I am successful to have the value from the combo box generate into a text box of a second form.
second form "accttranslistpassword" and the text box that I am trying to generate the value into is "txtacctholder.
the value seems to imput in the text box fine but I get the syntax error when I try to run the password script.
Expand|Select|Wrap|Line Numbers
- Private Sub cbobankacct_AfterUpdate()
- DoCmd.OpenForm "AcctTransListPassword"
- Forms!AcctTransListPassword!txtacctholder = Forms!AcctTransactionList!cbobankacct.Column(1)
- End Sub
Expand|Select|Wrap|Line Numbers
- 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