Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / New Users / April 2005

Tip: Looking for answers? Try searching our database.

need syntax help - wrong number of arguments in expression

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Newbee Adam - 14 Apr 2005 21:33 GMT
iif([eeloca] In ('AMRL','ECON','LUMB','SCIL','TWIS'), 20050301, [eeloca] In
('BOAS','BUHG','JBHT','LBLK'), 20050401, [eeloca] In
('CARD','FRON','AFTY','STHF'), 20050501, true, 99999999)

TANKS so much - Newbee
Ofer - 14 Apr 2005 21:41 GMT
you missing the other iif inside your iif e.g

iif([eeloca] In ('AMRL','ECON','LUMB','SCIL','TWIS'), 20050301,
iif([eeloca] In
('BOAS','BUHG','JBHT','LBLK'), 20050401, iif([eeloca] In
('CARD','FRON','AFTY','STHF'), 20050501, true, 99999999)))

and the 99999999 or the true are not in place, you have to get rid of one of
them

> iif([eeloca] In ('AMRL','ECON','LUMB','SCIL','TWIS'), 20050301, [eeloca] In
> ('BOAS','BUHG','JBHT','LBLK'), 20050401, [eeloca] In
> ('CARD','FRON','AFTY','STHF'), 20050501, true, 99999999)
>
> TANKS so much - Newbee
John Vinson - 14 Apr 2005 23:28 GMT
>iif([eeloca] In ('AMRL','ECON','LUMB','SCIL','TWIS'), 20050301, [eeloca] In
>('BOAS','BUHG','JBHT','LBLK'), 20050401, [eeloca] In
>('CARD','FRON','AFTY','STHF'), 20050501, true, 99999999)
>
>TANKS so much - Newbee

I think you want to use Switch() rather than Iif() here - IIF takes
only a TRUE or FALSE branch and you have multiple.

                 John W. Vinson[MVP]    
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.