Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
If statement problem
Message
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
If statement problem
Miscellaneous
Thread ID:
00951318
Message ID:
00951318
Views:
40
I have a stored procedure which is invoked by an IF statement, shown below:

IF INLIST(SUBSTRC(mainkey,AT('*',mainkey),8),'*AW2002*','*SS2002*')

The if statement works great if any of my records contain 'AW2002' or 'SS2002'.
What I would like to do is now reverse the statement so that if it does equal AW2002 or SS2002 then the stored procedure will not work!! I have tried:

IF INLIST(!SUBSTRC(mainkey,AT('*',mainkey),8),'*AW2002*','*SS2002*','*AW2003*'

&

IF not INLIST(SUBSTRC(mainkey,AT('*',mainkey),8),'*AW2002*','*SS2002*','*AW2003*'

This does not work, does anybody have any ideas please?
Neil Lewis
IT R&D Manager
Velmore Ltd
Next
Reply
Map
View

Click here to load this message in the networking platform