"template" stack in custom property
Hi friends, I have done this a lot in the past, but currently got stuck with this in LC 9.5 I store a stack in a custom property and open it via script like: ... put "NewJob_" & the seconds into tName go invisible stack (the cTemplateStack of this stack) ## Works so far, the stack is in -> the openstacks ## However NOTHING that comes after that line will ever get executed? ## restarted LC a couple of time, no dice... ## Even the BREAKPOINT is being ignored!? breakpoint answer "asfasdasdasdasdasd" ... What's wrong with this? Any hints much appreciated! Best Klaus -- Klaus Major https://www.major-k.de kl...@major-k.de ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: "template" stack in custom property
Hi all, I found a workaround by creating two handlers and use them with a little dealy. > Am 02.08.2019 um 14:59 schrieb Klaus major-k via use-livecode > : > > Hi friends, > > I have done this a lot in the past, but currently got stuck with this in LC > 9.5 > I store a stack in a custom property and open it via script like: > ... > put "NewJob_" & the seconds into tName > go invisible stack (the cTemplateStack of this stack) > ## Works so far, the stack is in -> the openstacks > > ## However NOTHING that comes after that line will ever get executed? > ## restarted LC a couple of time, no dice... > > ## Even the BREAKPOINT is being ignored!? > breakpoint > answer "asfasdasdasdasdasd" > ... ... put "NewJob_" & the seconds into tName send "do_the_rest" to me in 1 go invisible stack (the cTemplateStack of this stack) ... command do_the_rest ## rename template stack ## etc... end do_the_rest Too funky!? Best Klaus -- Klaus Major https://www.major-k.de kl...@major-k.de ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: "template" stack in custom property
Hi all, in case someone is interested. > Am 02.08.2019 um 16:00 schrieb Klaus major-k via use-livecode > : > > Hi all, > > I found a workaround by creating two handlers and use them with a little > dealy. > >> Am 02.08.2019 um 14:59 schrieb Klaus major-k via use-livecode >> : >> >> Hi friends, >> >> I have done this a lot in the past, but currently got stuck with this in LC >> 9.5 >> I store a stack in a custom property and open it via script like: >> ... >> put "NewJob_" & the seconds into tName lock messages ## Now every line in the handler is being executed. >> go invisible stack (the cTemplateStack of this stack) >> ## Works so far, the stack is in -> the openstacks >> >> ## However NOTHING that comes after that line will ever get executed? >> ## restarted LC a couple of time, no dice... >> >> ## Even the BREAKPOINT is being ignored!? >> breakpoint >> answer "asfasdasdasdasdasd" >> ... looks like this only happens if the stack in the CP does have a "pre-/openstack" handler!? If I add "lock messages" everything works as advertised. This does not happen if I go to a stack on my HD!? Oh my... :-/ Best Klaus -- Klaus Major https://www.major-k.de kl...@major-k.de ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: "template" stack in custom property
On 8/2/19 12:56 PM, Klaus major-k via use-livecode wrote: Hi all, in case someone is interested. Am 02.08.2019 um 16:00 schrieb Klaus major-k via use-livecode : Hi all, I found a workaround by creating two handlers and use them with a little dealy. Am 02.08.2019 um 14:59 schrieb Klaus major-k via use-livecode : Hi friends, I have done this a lot in the past, but currently got stuck with this in LC 9.5 I store a stack in a custom property and open it via script like: ... put "NewJob_" & the seconds into tName lock messages ## Now every line in the handler is being executed. go invisible stack (the cTemplateStack of this stack) ## Works so far, the stack is in -> the openstacks ## However NOTHING that comes after that line will ever get executed? ## restarted LC a couple of time, no dice... ## Even the BREAKPOINT is being ignored!? breakpoint answer "asfasdasdasdasdasd" ... looks like this only happens if the stack in the CP does have a "pre-/openstack" handler!? If I add "lock messages" everything works as advertised. This does not happen if I go to a stack on my HD!? Oh my... :-/ I have seen many instances where the IDE does not recognize the defaultstack. Yesterday I had two stacks open, I clicked on one to bring it to the front, and the message box title bar correctly said it was the target stack for messages. But every command I put in the message box threw an error. I asked it what the defaultstack was and it answered correctly. But I couldn't get commands to work until I added a full path to the stack and used the send command: send "myMessage" to this card of stack "otherstack" Just typing "myMessage" into the message box always said it couldn't find the handler. It also couldn't find any objects I could see clearly on screen, etc. It was as if the stack wasn't there. Setting the defaultstack manually in the message box also didn't work. The "can't find handler" error, as well as not finding controls or cards, has been around for a while but I see it more oftn in the last few versions of LC 9. I haven't got a repeatable recipe yet so haven't reported it. Anyway, that sounds like what you are experiencing. -- Jacqueline Landman Gay | jac...@hyperactivesw.com HyperActive Software | http://www.hyperactivesw.com ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: "template" stack in custom property
Hi Jaque, > Am 02.08.2019 um 20:24 schrieb J. Landman Gay via use-livecode > : > ... > The "can't find handler" error, as well as not finding controls or cards, has > been around for a while but I see it more oftn in the last few versions of LC > 9. I haven't got a repeatable recipe yet so haven't reported it. > > Anyway, that sounds like what you are experiencing. no, I don't think so, because LC obviously neglects the rest of the script but ONLY if the stack-to-be-opened has a pre-/openstack handler. Works if I add -> lock messages! And this only happens when I open a stack from within a custom property. If I do the same with a stack from my HD, everything works as exspected, so it does not sound like LC is not finding "the defaultstack". > -- > Jacqueline Landman Gay | jac...@hyperactivesw.com > HyperActive Software | http://www.hyperactivesw.com Best Klaus -- Klaus Major https://www.major-k.de kl...@major-k.de ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: "template" stack in custom property
Possibly related to this inability to focus properly is this bug I just filed: Bug 22285 - Can't focus on script window with property inspector custom properties tab open Only showing in LC 9.5. This can really create havoc if you don’t watch where the characters you are typing or pasting actually end up. Peter Bogdanoff ArtsInteractive > On Aug 2, 2019, at 11:30 AM, Klaus major-k via use-livecode > wrote: > > Hi Jaque, > >> Am 02.08.2019 um 20:24 schrieb J. Landman Gay via use-livecode >> : >> ... >> The "can't find handler" error, as well as not finding controls or cards, >> has been around for a while but I see it more oftn in the last few versions >> of LC 9. I haven't got a repeatable recipe yet so haven't reported it. >> >> Anyway, that sounds like what you are experiencing. > > no, I don't think so, because LC obviously neglects the rest of the script > but ONLY if the stack-to-be-opened has a pre-/openstack handler. > > Works if I add -> lock messages! > > And this only happens when I open a stack from within a custom property. > If I do the same with a stack from my HD, everything works as exspected, so > it does not sound > like LC is not finding "the defaultstack". > >> -- >> Jacqueline Landman Gay | jac...@hyperactivesw.com >> HyperActive Software | http://www.hyperactivesw.com > > Best > > Klaus > > -- > Klaus Major > https://www.major-k.de > kl...@major-k.de > > > ___ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your subscription > preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: "template" stack in custom property
What are the advantage of instantiating the new stack from data in a prop rather than by cloning a substack? ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: "template" stack in custom property
On 8/2/2019 10:33 PM, ambassador--- via use-livecode wrote: What are the advantage of instantiating the new stack from data in a prop rather than by cloning a substack? That was my question too. It is a very different way of storing a stack. I imagine that an: open invisible stack (the cSavedStack of stack "someOtherStack") would be like a open invisible URL in that it has to be loaded into memory, so it it is not the last line of the script, I would expect it should be followed by a "wait with messages" to allow all the new stack messages to fire. ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode
Re: "template" stack in custom property
Hi guys, > Am 03.08.2019 um 17:19 schrieb Paul Dupuis via use-livecode > : > On 8/2/2019 10:33 PM, ambassador--- via use-livecode wrote: >> What are the advantage of instantiating the new stack from data in a prop >> rather than by cloning a substack? > That was my question too. well the first approach is much much cooler than the latter one, innit? :-) Jokes aside, one advantage is that someone else can create that "template" stack, my customer in this case, and since this is a separate stack file it can thus contain substacks, which can be another big advantage in some situations. > It is a very different way of storing a stack. I have never been representative. 8-) > I imagine that an: open invisible stack (the cSavedStack of stack > "someOtherStack") > would be like a open invisible URL Yes. > in that it has to be loaded into memory, so it it is not the last line of the > script, I would expect it should be followed by a "wait with > messages" to allow all the new stack messages to fire. But as I wrote, if I load a stack from my hd, everything works as advertised!? Anyway, I have a nice workaround and a happy customer. Have a nice weekend. Best Klaus -- Klaus Major https://www.major-k.de kl...@major-k.de ___ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode