Quantcast
Channel: LiveCode Forums
Viewing all articles
Browse latest Browse all 669

LiveCode Builder • Reading Characters from a string

$
0
0
I am attempting to read the first three characters of a string inside a library extension written in Livecode Builder. My test handler is below and I have tried various different versions without luck.

CODE:

public handler calLibraryVersion() returns Stringvariable tOsSystem as Stringvariable tTest as Stringput the operating system into tOsSystem  -- "mac of Calendar Library"get char 1 to 3 of tOsSystemput the result into tTestreturn "Library version 1.14.58-7 on OS : " & tTestend handler
The dictionary entry for RangeCharOf contains this code snip:

CODE:

get char 5 to 10 of tString // Evaluates chars 5 to 10
My handler runs but returns the full version of tOsSystem.

What have I missed?

Statistics: Posted by Simon Knight — Sat Jul 13, 2024 11:15 am



Viewing all articles
Browse latest Browse all 669

Trending Articles