Direct LCB encoding/decoding

LiveCode Builder is a language for extending LiveCode's capabilities, creating new object types as Widgets, and libraries that access lower-level APIs in OSes, applications, and DLLs.

Moderators: LCMark, LCfraser

Post Reply
[-hh]
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 2262
Joined: Thu Feb 28, 2013 11:52 pm
Location: Göttingen, DE

Direct LCB encoding/decoding

Post by [-hh] » Thu Oct 05, 2017 3:31 pm

Instead of doing that by LCS and get it back I'm trying to encode/decode data in LCB.

Code: Select all

use com.livecode.encoding
doesn't work, the module is not available.
Trying to use (part of) the source of encoding.lcb on github doesn't work:

Code: Select all

use com.livecode.foreign
foreign handler ExecEncodeUsingBase64(in pSrc as Data, out rVal as String) \ 
returns nothing binds to "<builtin>"
compiles but results in an LCB error "Unable to bind foreign handler ..."

Trying to use "unsafe"-context also doesn't help.
What's wrong? What can I do?
shiftLock happens

livecodeali
Livecode Staff Member
Livecode Staff Member
Posts: 192
Joined: Thu Apr 18, 2013 2:48 pm

Re: Direct LCB encoding/decoding

Post by livecodeali » Fri Oct 06, 2017 2:18 pm

Unfortunately there isn't currently a way - the encoding module was left uncompleted pending decisions about string encoding functions I believe... anyway, I've filed a bug because we should be able to get (at least) base 64 encode / decode in there.

http://quality.livecode.com/show_bug.cgi?id=20521

Post Reply

Return to “LiveCode Builder”