LCB

J. Landman Gay jacque at hyperactivesw.com
Fri Jul 29 16:41:26 EDT 2016


On 7/29/2016 2:08 PM, Mike Kerner wrote:
> Is anybody doing anything significant with LCB, yet?  I'm just getting back
> into messing with it after many months of ignoring it...
>

I can't get much to work, significant or not. I apologize for hijacking 
your thread, but the subject was apropos... I agreed to test the LCB 
tutorial before it was given at the conference. I have not been able to 
make it past one of the earliest lessons, and the team is too busy right 
now to respond. I'd like to see if I can get a little farther. Can 
someone tell me what is wrong with this simple example:

***
library community.livecode.jacque.helloworld

metadata title is "Hello World Library"
metadata author is "Jacqueline Landman Gay"
metadata version is "1.0.0"

public handler sayHello(in pNames as String) returns List
   variable tNameList as List
   variable tMessage as List
   variable tElement as String

   split pNames by ","
   put the result into tNameList

   repeat for each element tElement in tNameList
     push tElement onto tMessage
   end repeat
   return tMessage
end handler

end library
***

It will compile with the Test button but when called from LCS this way:

   put sayHello("Adam,Brenda,Craig") into tArray

it errors with the cryptic message:
   execution error at line 2 (extension: error occured with domain) near 
"runtime", char 7

I don't think it's the domain name because earlier versions worked. It 
started erroring after the lesson added the split and repeat loop.

There is a discrepancy in the lessons where at one point it uses "split 
pNames by "," into tNameList". I tried that syntax as well, though it 
isn't in the dictionary, but got the same error.

Does anyone see anything wrong? It is copied verbatim from the lesson, 
right down to the uppercase letters which I wasn't sure were required 
(is LCB case sensitive? The lesson doesn't say.)

-- 
Jacqueline Landman Gay         |     jacque at hyperactivesw.com
HyperActive Software           |     http://www.hyperactivesw.com




More information about the use-livecode mailing list