Re: invalid syntax
- From: John Vinson <jvinson@xxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 29 Jun 2005 22:58:26 -0600
On Wed, 29 Jun 2005 13:56:06 -0700, MMH
<MMH@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote:
>I am trying to set the status of certain deliverables. I get an invalid
>syntax error with this statment. I am sure I am missing parentheses somewhere
>but I am not sure where.
>
>
>=IIf([Date Rec'd]>[Dute Date],?Past Due?,IIf([Dute Date]<Date(),?Past
>Due?,IIf([Date Rec'd]<[Dute Date],?On Time?,?Pending?)))
>
>
>Thanks
Is it really "Dute Date" as opposed to "Due Date"?
let's take this nested IIF apart:
=IIf([Date Rec'd]>[Dute Date],
?Past Due?, << true branch 1
IIf([Dute Date]<Date(), << false branch 1
?Past Due?, << true branch 2
IIf([Date Rec'd]<[Dute Date], << false branch 2
?On Time?, << true branch 3
?Pending?))) << false branch 3
You might have better luck with the Switch() function - see the online
help in the VBA editor.
John W. Vinson[MVP]
.
- Follow-Ups:
- Re: invalid syntax
- From: MMH
- Re: invalid syntax
- References:
- invalid syntax
- From: MMH
- invalid syntax
- Prev by Date: RE: I'm Getting Postal
- Next by Date: Re: I'm Getting Postal
- Previous by thread: Re: invalid syntax
- Next by thread: Re: invalid syntax
- Index(es):
Relevant Pages
|