Trouble with 'there is a'

Mark Schonewille m.schonewille at economy-x-talk.com
Thu Jan 26 17:19:36 EST 2012


Hi Graham,

161 means "error in source expression". Probably, it is saying that "if there is a folder (the defaultFolder)" can't be parsed into something that makes sense, which is correct because it is only the first part of an if-then-else control structure. If you remove the "if" then LiveCode can parse the string to true or false.

--
Best regards,

Mark Schonewille

Economy-x-Talk Consulting and Software Engineering
Homepage: http://economy-x-talk.com
Twitter: http://twitter.com/xtalkprogrammer
KvK: 50277553

Download the Installer Maker Plugin 1.7 for LiveCode here http://qery.us/za

On 26 jan 2012, at 23:13, Graham Samuel wrote:

> I'm  using LS 5.0.2. on Windows XP (OK, running under Parallels on a Mac). I'm getting unexpected results from the 'there is..' series of functions/commands - the dictionary says they're implemented as functions, which I can understand.
> 
> As a very simple test, in the message box I put:
> 
>   put (if there is a folder (the defaultFolder))
> 
> expecting to get 'true'. Instead I get the totally unexpected result:
> 
>   161,426,1,return (if there is a folder (the defaultFolder))
> 
> I suppose it's my fault, but what does this mean? Just to be clear, 'the default folder' does have a value - it's:
> 
>  C:/Program Files/RunRev/LiveCode 5.0.2
> 
> Puzzled
> 
> Graham





More information about the use-livecode mailing list