R
Rick
Hi,
I need to extract some data from a string being passed. I was wondering
what would be the best way of doing this. For example, I have two
strings: "SWITCH1CLOSE" and "GATE1OPEN"
I need to take out the SWITCH part of out of the string, the "1" and the
"close". Similarly, I need to take out GATE, 1 and open from the second
string. Should I use the "strstr" function for comparing the substrings
GATE, CLOSE, OPEN etc? I can't use the tokenizing function here so I'm
not sure what would be the best way of doing this. Any suggestions would
be great! Thanks
Rick
I need to extract some data from a string being passed. I was wondering
what would be the best way of doing this. For example, I have two
strings: "SWITCH1CLOSE" and "GATE1OPEN"
I need to take out the SWITCH part of out of the string, the "1" and the
"close". Similarly, I need to take out GATE, 1 and open from the second
string. Should I use the "strstr" function for comparing the substrings
GATE, CLOSE, OPEN etc? I can't use the tokenizing function here so I'm
not sure what would be the best way of doing this. Any suggestions would
be great! Thanks
Rick