A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » New Users
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

#Error in Iff statement



 
 
Thread Tools Display Modes
  #1  
Old November 13th, 2007, 06:48 PM posted to microsoft.public.access.gettingstarted
[email protected]
external usenet poster
 
Posts: 2
Default #Error in Iff statement

I am receiving a #Error message when I change the PName field to the
following
=IIf(Len([PName]=2),"-None Selected-",[PName]) in my report. The
PName is just a joining of Last and First Name with a comma and space
in between. I would like the report to say "-None Selected-" if No
Name was entered.
Any suggestions?

  #4  
Old November 13th, 2007, 09:02 PM posted to microsoft.public.access.gettingstarted
[email protected]
external usenet poster
 
Posts: 2
Default #Error in Iff statement

On Nov 13, 1:58 pm, "J_Goddard via AccessMonster.com" u37558@uwe
wrote:
you have a closing bracket in the wrong place in the LEN function. Try this:

IIf(Len([PName]) =2 ,"-None Selected-",[PName])

John

wrote:
I am receiving a #Error message when I change the PName field to the
following
=IIf(Len([PName]=2),"-None Selected-",[PName]) in my report. The
PName is just a joining of Last and First Name with a comma and space
in between. I would like the report to say "-None Selected-" if No
Name was entered.
Any suggestions?


--
Message posted viahttp://www.accessmonster.com



That worked! THANKS!


 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 05:51 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.