I have a code that is suppose to work. I have a country (Pays) table and an agent table, I want to change the imputmask of the zipcode (Code Postal) if the country change. I have more than 50 countries in that table so I dont want to use if then 50 times. The country tableis like this:
ID Pays Country CPmask
1 Canada >L0L 0L0;0;_
2 USA 00000-9999;0;_
In my agent form i have a ID Pays field with this code in the after update
Me.Code_Postal.InputMask = DLookup("CPmask", "Pays", "ID Pays=" & Me.ID_Pays)
Can someone tell me what is the error in this code because i got a run-time error 3075: Syntax error (missing operator) in query expression 'ID Pays=1'
Thanks
François
ID Pays Country CPmask
1 Canada >L0L 0L0;0;_
2 USA 00000-9999;0;_
In my agent form i have a ID Pays field with this code in the after update
Me.Code_Postal.InputMask = DLookup("CPmask", "Pays", "ID Pays=" & Me.ID_Pays)
Can someone tell me what is the error in this code because i got a run-time error 3075: Syntax error (missing operator) in query expression 'ID Pays=1'
Thanks
François