Page 1 of 1 1
Topic Options
#43064 - 2003-07-18 10:05 PM Simple SELECT CASE Question
ElGuapo Offline
Starting to like KiXtart

Registered: 2002-06-19
Posts: 100
Does an OR work with Select Case? I know an AND does. I didn't find anything in the manual or previous BB posts.

SELECT
CASE INGROUP("A) OR INGROUP("B")
? "Do stuff"
ENDSELECT

Top
#43065 - 2003-07-18 10:06 PM Re: Simple SELECT CASE Question
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
Why don't you try it? Would work better though if you had matched quotes.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#43066 - 2003-07-18 10:06 PM Re: Simple SELECT CASE Question
Howard Bullock Offline
KiX Supporter
*****

Registered: 2000-09-15
Posts: 5809
Loc: Harrisburg, PA USA
Sure does.
_________________________
Home page: http://www.kixhelp.com/hb/

Top
#43067 - 2003-07-18 10:07 PM Re: Simple SELECT CASE Question
Les Offline
KiX Master
*****

Registered: 2001-06-11
Posts: 12734
Loc: fortfrances.on.ca
Oh, and you don't need 2 ingroups with the newer KiX. One can do both.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.

Top
#43068 - 2003-07-18 10:29 PM Re: Simple SELECT CASE Question
ElGuapo Offline
Starting to like KiXtart

Registered: 2002-06-19
Posts: 100
I guess a better wording of my question would have been "is OR officially supported?"

I was concerned that OR would work sometimes or be flakey or not supported in future releases.

Also, unless I tried multiple combinations, the subtleties like not needing a 2nd INGROUP in the newer kix would not be known.

I am using 3.61 and will be upgrading to 4.2x this summer.

The missing " was a typo, of course...

Thanks for the replies...

Top
#43069 - 2003-07-18 10:46 PM Re: Simple SELECT CASE Question
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11165
Loc: Boston, MA, USA
You migth want to post your version number together with your question as the answers will depend on the KiXtart version.
_________________________
There are two types of vessels, submarines and targets.

Top
#43070 - 2003-07-18 11:11 PM Re: Simple SELECT CASE Question
Lonkero Administrator Offline
KiX Master Guru
*****

Registered: 2001-06-05
Posts: 22346
Loc: OK
I wonder, what got you thinking that OR might be unsupported?
like it was added to manual just for fun or something... [Confused]
_________________________
!

download KiXnet

Top
#43071 - 2003-07-21 09:55 AM Re: Simple SELECT CASE Question
Richard H. Administrator Offline
Administrator
*****

Registered: 2000-01-24
Posts: 4946
Loc: Leatherhead, Surrey, UK
The simple answer is that any and all valid expressions will work with select.

This means that you may use any of the logical or mathematical operators, constants, variables and functions in your expression.

The expression is evaluated, and the result checked.

If the result is a non-zero number then it will be true and the Case statements will be executed. If it is a non-empty string then it will be true and the Case statements will be executed

Top
#43072 - 2003-07-21 03:18 PM Re: Simple SELECT CASE Question
Sealeopard Offline
KiX Master
*****

Registered: 2001-04-25
Posts: 11165
Loc: Boston, MA, USA
And a list of valid expressions is even listed in the KiXtart Manual.
_________________________
There are two types of vessels, submarines and targets.

Top
Page 1 of 1 1


Moderator:  Jochen, Allen, Radimus, Glenn Barnas, ShaneEP, Ruud van Velsen, Arend_, Mart 
Hop to:
Shout Box

Who's Online
0 registered and 302 anonymous users online.
Newest Members
Sir_Barrington, batdk82, StuTheCoder, M_Moore, BeeEm
17886 Registered Users

Generated in 0.06 seconds in which 0.025 seconds were spent on a total of 12 queries. Zlib compression enabled.

Search the board with:
superb Board Search
or try with google:
Google
Web kixtart.org