|
Post by rikky on May 22, 2020 14:57:48 GMT 1
Hello I'm using a Fossil from yesterday, I believe, or the day before. FUNCTION LENGTH(string$) RETURN LEN(string$) END FUNCTION
bla$ = "abc" PRINT STR$(LENGTH(bla$)) PRINT STR$(LEN(bla$))
response: 0 3 I tested it, but inside the function LEN and ULEN both work. You can print them, and they print the right value. I hope I'm not making a stupid thinking error again. I know I'm famous for that. Rik.
|
|
|
Post by bigbass on May 22, 2020 15:36:09 GMT 1
Hello Rik
Your logic is correct but the syntax needs a small adjustment
Joe
FUNCTION LENGTH(string$) TYPE int LOCAL result TYPE int result = LEN(string$) RETURN result END FUNCTION
bla$ = "abc" PRINT STR$(LENGTH(bla$)) PRINT STR$(LEN(bla$))
|
|
|
Post by rikky on May 22, 2020 16:11:44 GMT 1
Yep, this works.
Thrown away my workaround. Thanks.
|
|