473,385 Members | 1,587 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

how to write the condition

Hi,

I am new to access and learning. Can you see how I can make this check without giving me #error when running it. It will value it as #error on the report.
Expand|Select|Wrap|Line Numbers
  1.  
  2. =IIf((InStr(1,[Sig_Aux_Info],"ICU ")>0) Or (InStr(1,GetSigAuxDrugCode([ITN],[PMP],"DRUGCODE_INFO"),"MSG QUALIFY")>0 And Trim([IV_METHOD_CODE])="10") Or (InStr(1,GetSigAuxDrugCode([ITN],[PMP],"DRUGCODE_INFO"),"MSG QUALIFY")>0 And Trim([NRS_STATION])="PSYH" And Trim([PHM_ORDERS!LATIN_DIR_ABBR])="REPLACE"),"Can't reorder on this form","____________ | ____________")

Expand|Select|Wrap|Line Numbers
  1.  Trim([NRS_STATION])="PSYH"  
I would like to check more stations to include SICU, MICU, etc. When I added those in as
Expand|Select|Wrap|Line Numbers
  1.  Trim([NRS_STATION])=("PSYH" or "SICU" or "MICU")
after running the report, the field value as #error.

Thanks
Feb 12 '07 #1
1 1582
MMcCarthy
14,534 Expert Mod 8TB
Try this ...

Expand|Select|Wrap|Line Numbers
  1.  
  2. =IIf((InStr(1,[Sig_Aux_Info],"ICU ")>0) 
  3. Or (InStr(1,GetSigAuxDrugCode([ITN],[PMP],"DRUGCODE_INFO"),"MSG QUALIFY")>0 
  4. And Trim([IV_METHOD_CODE])="10") 
  5. Or (InStr(1,GetSigAuxDrugCode([ITN],[PMP],"DRUGCODE_INFO"),"MSG QUALIFY")>0 
  6. And Trim([NRS_STATION]) IN ("PSYH","SICU","MICU")
  7. And Trim([PHM_ORDERS!LATIN_DIR_ABBR])="REPLACE"),
  8. "Can't reorder on this form",
  9. "____________ | ____________")
  10.  
Mary
Feb 12 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

7
by: Patrick Useldinger | last post by:
Hi, I think I found a bug in the write method of file objects. It seems as if before writing each block, a check was done in order to verifiy that there is enough space left for the *whole*...
6
by: haynesc | last post by:
Hi, I'm having a problem where when trying to open a file in write mode, I get an IOError stating no such file or directory. I'm calling an external program which takes an input file and...
8
by: Greg Brant | last post by:
my script is document.write("<!-- #include virtual\"http://www.where-ever.com/whatevere.html\" -->") but in the html (view source) i get ---------------------------------------------------...
5
by: nicolas_riesch | last post by:
Does someone know if the module pytz (http://sourceforge.net/projects/pytz/) is thread-safe ? I have not seen it explicitely stated, and just wanted to be sure, as I want to use it. That's...
0
by: aredo3604gif | last post by:
I have coded a serie of singly linked lists in ANSI C which I have to use. The lists are then stored in a serie of buckets with chained hash table technique. In the various lists there are nodes...
4
by: Anil Aksay | last post by:
I need to put a breakpoint when a particular memory location is written. To be more specific I want to know when 0 is written onto that memory location. Is there a way to do it in vc7? Regards,...
7
by: Chris | last post by:
Hi, On a webform do I have a label, a textBox (txtName) and a submit-button (all asp server controls) : Upon pressing the button do I write the entered name in the html-output stream (at...
11
by: Michael Powe | last post by:
How can I make an XHTML-compliant form of an expression in this format: document.write("<scr"+"ipt type='text/javascript' src='path/to/file.js'>"+"</scr"+"ipt>"); this turns out to be a...
2
by: antonyliu2002 | last post by:
I do not quite understand the race condition. As I posted a couple of days ago, I create a PDF on the fly in my web application at regular intervals. Users will be able to download the PDF...
4
by: sahil | last post by:
Hello frends i am learning c language, I want to make a program which count occurence of each element in an array .I write following code for it but ity is not giving me desired result.pls help me....
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.