How do I make a string comparison switch?
From: Panama Red (complaintdepartment2002_at_yahoo.com)
Date: 05/30/04
- Next message: D. Beckham: "Doubly-Link List Setup????"
- Previous message: Joachim: "Re: question on multidimensional array"
- Next in thread: Chris Smith: "Re: How do I make a string comparison switch?"
- Reply: Chris Smith: "Re: How do I make a string comparison switch?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Sun, 30 May 2004 21:22:51 GMT
Hello,
I want to match a string against a series of different
keywords... here is what Ive tried :
switch(Request) {
case Request.equals("HELLO"):
// Write Results to Monitor
logDisplay.append( "Results: HELLO BACK\n");
break;
}
The compiler tells me I need an int, not a string ... so how do
you do this common task?
- Next message: D. Beckham: "Doubly-Link List Setup????"
- Previous message: Joachim: "Re: question on multidimensional array"
- Next in thread: Chris Smith: "Re: How do I make a string comparison switch?"
- Reply: Chris Smith: "Re: How do I make a string comparison switch?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]