Hello Access Monsters,
I have a table with three columns. "CostCenter", "ProjectNumber", "GLCode"
On my form I have three texboxes, "txtCostCenter", "txtProjectNumber" and
"txtGLCode".
the AfterUpdate event of the txtCostCenter runs the following code.
Me.txtProjectNumber = DLookup("ProjectNumber", "tblList", "CostCenter =" & Me.
txtCostCenter)
Me.txtGLCode = DLookup("GLCode", "tblList", "CostCenter =" & Me.txtCostCenter)
This works perfectly, however, sometimes the user may not have the CostCenter
so he will enter the ProjectNumber. Thus I have the AfterUpdate event of the
"txtProjectNumber" set to the following.
Me.txtGLCode = DLookup("GLCode", "tblList", "ProjectNumber =" & Me.
txtProjectNumber)
When entering the ProjectNumber I get the syntax error '3075' "syntax error
in number in query expression 'ProjectNumber = 4190740.1570003.00'
All my project numbers come in that format. Is it the format of the data
causing this?
--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...ccess/200709/1