start using stack

Klaus major-k klaus at major-k.de
Thu May 23 09:38:21 EDT 2013


Hi Alex,

Am 23.05.2013 um 15:20 schrieb Alex Tweedly <alex at tweedly.net>:

> OK, I have to confess I'm confused :-(
> 
> I thought you were trying to run a script on LC server (on-rev) and having trouble getting "start using stack" to work.
> 
> But the testing stack below is actually a desktop stack which does a "go stack URL ..." ??
> So - if the rest of this reply is misguided - let's step back and describe the problem & stacks in question again.
> 
> Anyway - the problem with this test stack ( goStackURL.livecode ) is ....
> 
> ON mouseUp
>   put empty into field "info" of this card
>   go stack URL field "target" of this card in a new window
>   put the result into field "info" of this card
> END mouseUp
> 
> but currently (i.e. as downloaded) the field "target" is empty. I copy/pasted the name of the URL you mentioned
> 
> http://runtime-revolution.278305.n4.nabble.com/file/n4665288/drawings.livecode
> 
> into the field, and it then works OK - the drawings stack is downloaded and run in my IDE.
> 
> BTW - there is then a problem with
>   put the result into field "info" of this card
> 
> I think that's a problem because "this card" is not clear just after the "go stack" - not entirely sure about that.

Yep, after you "go stack URL xyz" THAT stack is the defaultstack and thus field "info" will be presumed 
to be on the current (first) card of the "online" stack. 

So you will need 
1. to set the defautlstack back to the "calling" stack before putting THE RESULT into fld "info"
or 
2. do something like this:

ON mouseUp
  put empty into field "info" of this card
  put the long ID of fld "info" of this cd into tInfoFieldID
  go stack URL field "target" of this card in a new window
  put the result into tInfoFieldID
END mouseUp

> -- Alex.

Best

Klaus

--
Klaus Major
http://www.major-k.de
klaus at major-k.de





More information about the use-livecode mailing list