Page 1 of 1

split journal

Posted: 2004-11-06 08:24:19
by clagio
it's possible to split journal message?
example:

clagio: var1 var2 => journal message

var x= var1
var y= var2

Posted: 2004-11-08 14:09:29
by clagio
noone know? :)

Posted: 2004-11-08 14:15:42
by AGRS
I can't understand correct what you want to do.

Posted: 2004-11-08 14:29:03
by clagio
i have this line in journal :

clagio: hello world

i want to give as value to var1 = "hello" and to var2 = "world"

at this moment i can only give to var1 the value "clagio: hello world"

with easyuo it's possible, but i need to use only injection

:)

Posted: 2004-11-08 14:32:04
by Sfagnum
clagio wrote:i have this line in journal :

clagio: hello world

i want to give as value to var1 = "hello" and to var2 = "world"

at this moment i can only give to var1 the value "clagio: hello world"

with easyuo it's possible, but i need to use only injection

:)
you must do it yourself

Posted: 2004-11-08 14:44:19
by AGRS
Var TextAll="hello world"
Var TextLeft=Left(TextAll, 5) ; Hello
Var TextRight=Right(TextAll, 5) ; World

Posted: 2004-11-08 14:45:46
by clagio
how? there are function to split or analyze text string? i didn't see anything in the documentation..

Posted: 2004-11-08 14:48:00
by Sfagnum
clagio wrote:how? there are function to split or analyze text string? i didn't see anything in the documentation..
use functions:
Len
Mid
Left
Right

Posted: 2004-11-08 14:51:28
by clagio
AGRS wrote:Var TextAll="hello world"
Var TextLeft=Left(TextAll, 5) ; Hello
Var TextRight=Right(TextAll, 5) ; World


wonderful.. how does these function work? Left and Right..the side where it start to count..
the first parameter is the string, that's ok, the second, is the number of words where from it start to scan..


good! :)

there are other parameter, or other function like these to manage string?

Posted: 2004-11-08 14:51:58
by clagio
ok thank you, very much :)

Posted: 2004-11-08 14:57:09
by AGRS
Left(string,symbol_count)
Right(string,symbol_count)
Mid(string,position,symbol_count)

Posted: 2004-11-08 15:00:38
by Sfagnum
AGRS wrote:Left(string,symbol_count)
Right(string,symbol_count)
Mid(string,position,symbol_count)
во блин, пока я расписывал... да проверял написание, ты ответил как всегда лаконично :)

Posted: 2004-11-08 15:02:26
by Yoko
i=0
while fullstr[i]<>" "
i=i+1
wend

newstr=left(fullstr,i)

....

etc, etc