I would agree, but I have become fond of constants, especially in objects where
code is similar but need certain things to be different. For instance I have a
button bar which opens for edit, creates new form, deletes data, saves data
etc. I copy this bar to each of my forms. The code in most
g stack
> "fastJSONlib"
> end releaseStack
>
> note that using "is among" and "is not among" is not optional otherwise you
> end up in an infinite loop
>
>
>
> -
> ---
> Greg (pink) Miller
> mad, pink and dangerous to code
>
using stack
"fastJSONlib"
end releaseStack
note that using "is among" and "is not among" is not optional otherwise you
end up in an infinite loop
-
---
Greg (pink) Miller
mad, pink and dangerous to code
--
View this message in context:
http://runtime-revolution.
Thanks Ali, that's a nice idea.
But just in case anyone else does the same as me (i.e. copy/paste it
without looking too hard :-) :
there should NOT be an 'else' clause in there right now it will
either set the variable OR do the initialization, when in fact it should
do BOTH or
One simple way to make this slightly nicer would be to make sure all your
initialisation happens in a separate handler eg (doLibraryInitialization),
and use your script local lock in the libraryStack handler
> local sIHaveBeenInitialized
> on librarystack
> if sIHaveBeenInitialized is empty
On 5/13/17 6:29 PM, Alex Tweedly via use-livecode wrote:
all initialisation would be done in the librarystack handler
that handler would also set a script-local variable to avoid repeated
initialisation
so something like
local sIHaveBeenInitialized
on librarystack
if sIHaveBeenInitialized
I'm starting to make more use of library stacks (partly because I'm
trying to switch away from revIgniter to a CGI-based solution to allow
me to do more work & debugging in the IDE).
And now I'm looking for best-practice and/or suggestions for how to use
library stacks. The not-q
Forget it… too long a day.. .I needed another segment my path…
sorry for the noise
Amazing how hard this is for me… I must be super dense or something is really
missing in the docs.
OK , so you say we don't need to use "go" to get stacks into memory
I have this in my loader stack
put (
Amazing how hard this is for me… I must be super dense or something is really
missing in the docs.
OK , so you say we don't need to use "go" to get stacks into memory
I have this in my loader stack
put ( getPathForSharedLibraries() & "itemMetadataParser.livecodescript") into
tMediaParser
But LiveCode is not C. In LiveCode an array is a value, not a special kind of
variable.
put "abcd" into cup 1 of that egg carton in the box labeled
"alphabetBlocks"
(I know, Dar sees the world funny.)
> On Jul 9, 2016, at 1:20 PM, Richard Gaskin wrote:
J. Landman Gay wrote:
> On 7/9/2016 1:39 PM, Richard Gaskin wrote:
>> After all, how does one express an array in English? :)
>
> "Egg carton". Devin taught me that while brandishing a prop at one of
> our teaching sessions.
>
>put "abcd" into cup 1 of eggcarton "alphabetBlocks"
http://runtime-revolution.278305.n4.nabble.com/Getting-Library-Stacks-into-Memory-tp4706461p4706515.html
Sent from the Revolution - User mailing list archive at Nabble.com.
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to su
On 7/9/2016 1:39 PM, Richard Gaskin wrote:
After all, how does one express an array in English? :)
"Egg carton". Devin taught me that while brandishing a prop at one of
our teaching sessions.
put "abcd" into cup 1 of eggcarton "alphabetBlocks"
At first I thought it was some kind of yolk
Mark Wieder wrote:
> On 07/09/2016 10:13 AM, Richard Gaskin wrote:
>
>> One might even say it becomes the "parent script" of the control.
>>
>> If only we had a word to describe that unique role clearly... ;)
>
> Ah... the problems of trying to set up a one-to-one correspondence
> between
On 07/09/2016 10:13 AM, Richard Gaskin wrote:
One might even say it becomes the "parent script" of the control.
If only we had a word to describe that unique role clearly... ;)
Ah... the problems of trying to set up a one-to-one correspondence
between technical terms and natural language.
Mark Wieder wrote:
> On 07/08/2016 10:57 PM, J. Landman Gay wrote:
>> I seem to remember inserting the script of a stack into back at some
>> point in the past.
>
> Probably also worth pointing out here that if you assign a behavior
> to a control, the behavior acts as a backscript to that
On 07/08/2016 10:57 PM, J. Landman Gay wrote:
I seem to remember inserting the script of a stack into back at some
point in the past.
Probably also worth pointing out here that if you assign a behavior to a
control, the behavior acts as a backscript to that control.
--
Mark Wieder
I seem to remember inserting the script of a stack into back at some point
in the past. I know for sure you can start using the stack which is
effectively the same thing.
The main thing is that you don't need to "go" there to load the stack into
RAM. Just putting it in use does that, as does
On 07/08/2016 12:48 AM, J. Landman Gay wrote:
insert the script of the stack into front or back
Now *that* would be an interesting addition to the language
"...surprise me, Trebek..."
--
Mark Wieder
ahsoftw...@gmail.com
___
use-livecode
Jacque wrote: "insert the script of the stack into front or back"
The dictionary implies that this can only be done with an "object" , hence the
assumption (probably wrong) that one needs to have the stack open…
I assume you mean that we can do it like this now with script only stacks
insert
Subject: Re: Getting Library Stacks into Memory
To: How to use LiveCode
<use-livecode@lists.runrev.com<mailto:use-livecode@lists.runrev.com>>
These almost sound like undefined errors with the group name as the object
hint.
Mobile apps can only have one window at a time, and each &q
These almost sound like undefined errors with the group name as the object
hint.
Mobile apps can only have one window at a time, and each "go" replaces the
previous window. If you go to an invisible stack you'll see black. In
general don't use "go" for that kind of thing, just using the stack
Our new app was loading nicely on the iPhone.. .we externalized a lot of code
to scripts that are meant to be used in front, back and as behaviors… with the
go stack
cmd
logInfo "Loading frontscript" && tStackPath
go stack (getPathForSharedLibraries() & tStackPath)
insert the script of
I’ve found that when LiveCode saves the stack script file, it adds a
Byte Order Mark (BOM) to denote the file is UTF-8 encoded. If the BOM
is not present when you start using such a library stack, the engine
will treat it as being natively encoding. I have found that to be true
with both the IDE
On 23 Apr 2015, at 15:59, Mark Waddingham m...@livecode.com wrote:
You can save the stack in the normal way but the only thing it will save will
be the stack script - the file on disk is just a UTF-8 text file.
I’ve found that when LiveCode saves the stack script file, it adds a Byte Order
--
View this message in context:
http://runtime-revolution.278305.n4.nabble.com/Fwd-Plain-text-library-stacks-tp4691383p4691608.html
Sent from the Revolution - User mailing list archive at Nabble.com.
___
use-livecode mailing list
use-livecode
On 2015-04-23 20:41, Michael Doub wrote:
Mark, It appears that when you programmatically create a script only
stack and save it. The engine auto inserts the first line: script
stackname.I see that when I look at the file with a text editor.
When I edit the script of the stack in
Ah, I see. Thanks.
And may I say, your presence on this list, even if only occasional, is much
appreciated.
-- Peter
Peter M. Brigham
pmb...@gmail.com
http://home.comcast.net/~pmbrig
On Apr 24, 2015, at 2:11 PM, Mark Waddingham wrote:
1. No - substacks are part of the parent stackfile when
1. No - substacks are part of the parent stackfile when on disk so they only
make sense as normally saved (binary) stacks.
2. Yes - script only stacks are stacks. The script only part only pertains to
the on disk format which is a text file.
Sent from my iPhone
On 24 Apr 2015, at 19:06,
I just updated the MasterLibrary to allow you to create a Script Only
Stack and insert functions and commands with just a few clicks.
https://www.dropbox.com/s/3wpwn3hfbmpl7sk/MasterLibrary.livecode?dl=0
-= Mike
On 4/23/15 2:58 PM, Thierry Douez wrote:
Absolutely,
that's what Peter was
Questions about these script-only stacks:
1. can they be made substacks of another stack?
2. can you do start using stack… with them?
-- Peter
Peter M. Brigham
pmb...@gmail.com
http://home.comcast.net/~pmbrig
On Apr 24, 2015, at 12:41 PM, Michael Doub wrote:
I just updated the MasterLibrary
So, script stackname must be at the 1st line of the textfile.
Ah yes - that is indeed the case - it is quite picky, for two reasons.
The first was that the main use-case I had in mind when implementing it
was to replace IDE stacks which were only scripts and thus they would be
edited in the
Doesnt' work here with LC 6.7.4 or LC 7.0.4.
What exactly isn't working?
The feature has actually been in the engine (albeit in nascent form)
since around 6.6.4 / 6.6.5 IIRC.
I originally hacked it together because of the issues we'd had keeping
the core standalone builder stacks for iOS
Hmm,
had a blank 1st line and script stackname as the second one.
So, script stackname must be at the 1st line of the textfile.
And now it works beautifully :)
Regards,
Thierry
2015-04-23 16:50 GMT+02:00 Mark Waddingham m...@livecode.com:
Doesnt' work here with LC 6.7.4 or LC 7.0.4.
What
Hi Peter,
Which version of LC are you using ?
Doesnt' work here with LC 6.7.4 or LC 7.0.4.
Thanks,
Thierry
Thierry Douez - http://sunny-tdz.com
Maker of sunnYperl - sunnYmidi - sunnYmage
2015-04-23 15:34 GMT+02:00 Peter W A Wood
That is something to be aware of.
The purpose of a script only stack is to be text on disk... Password protection
requires binary output, so in that case you might as well just use a normal
stack.
Mark
Sent from my iPhone
On 23 Apr 2015, at 17:49, Peter Haworth p...@lcsql.com wrote:
Not
Mark, It appears that when you programmatically create a script only
stack and save it. The engine auto inserts the first line: script
stackname.I see that when I look at the file with a text editor.
When I edit the script of the stack in livecode the script stackname
line is missing.
I’m curious—can these plain text stacks be used by LC Server just like a
regular stack as a library?
Devin
Devin Asay
Office of Digital Humanities
Brigham Young University
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit
Absolutely,
that's what Peter was showing in his sample code.
Regards,
Thierry
Thierry Douez - http://sunny-tdz.com
Maker of sunnYperl - sunnYmidi - sunnYmage
2015-04-23 20:56 GMT+02:00 Devin Asay devin_a...@byu.edu:
I’m curious—can these
2015-04-23 18:26 GMT+02:00 Mark Waddingham m...@livecode.com:
So, script stackname must be at the 1st line of the textfile.
Ah yes - that is indeed the case
Thanks Mark for your explanations.
In fact,
I started by putting some comments in the first lines
then dropped them but leaving one
Not sure if this is a problem or not but it appears that any password I set
on the stack isn't retained. If I remove the stack from memory and re-open
it, the password isn't retained. I guess just something to be aware of
rather than a problem.
Pete
lcSQL Software http://www.lcsql.com
Home of
On 2015-04-23 07:37, Peter W A Wood wrote:
Is it possible to load a Library stack in plan text format from another
stack?
Yes - although we've not explicitly published details on the feature yet
:)
However, if you want to play around with it then from the message box
try:
create script
Many thanks, Mark.
On 23 Apr 2015, at 15:59, Mark Waddingham m...@livecode.com wrote:
On 2015-04-23 07:37, Peter W A Wood wrote:
Is it possible to load a Library stack in plan text format from another
stack?
Yes - although we've not explicitly published details on the feature yet :)
Great. I can now refactor all those libraries.
On Thu, 23 Apr 2015 at 11:44, Peter W A Wood peterwaw...@gmail.com wrote:
Many thanks, Mark.
On 23 Apr 2015, at 15:59, Mark Waddingham m...@livecode.com wrote:
On 2015-04-23 07:37, Peter W A Wood wrote:
Is it possible to load a Library
Here is a very simple server script and a very simple “text” library script
that show just what I was hoping.
The Library Script:
script TextLib
function TL.compare pFirst, pSecond
return pFirst = pSecond
end TL.compare
The Server Script:
#!path
” library
stacks. I searched the forum and clicked relevant threads without being able
to find the post that I remember.
Is it possible to load a Library stack in plan text format from another stack?
Peter
___
use-livecode mailing list
use-livecode
to load “plain text” library
stacks. I searched the forum and clicked relevant threads without being able
to find the post that I remember.
Is it possible to load a Library stack in plan text format from another
stack?
Peter
___
use
I remember reading a message to the effect that one of the recent releases to
the LiveCode engine included an enhancement to load “plain text” library
stacks. I searched the forum and clicked relevant threads without being able to
find the post that I remember.
Is it possible to load a Library
I'm writing a web service. I'm trying to activate a library stack using this
code:(line numbers are included just in email)
15:if there is a file (lib/DB_Library.livecode) then
16: start using stack (lib/DB_Library.livecode)
17:end if
the code finds the stack file but it won't start I'm getting
Ralph DiMola wrote:
I'm writing a web service. I'm trying to activate a library stack
using this code:(line numbers are included just in email)
15:if there is a file (lib/DB_Library.livecode) then
16: start using stack (lib/DB_Library.livecode)
17:end if
the code finds the stack file but
-livecode-boun...@lists.runrev.com] On Behalf
Of Richard Gaskin
Sent: Tuesday, November 18, 2014 8:24 PM
To: use-livecode@lists.runrev.com
Subject: Re: LiveCode server and library stacks
Ralph DiMola wrote:
I'm writing a web service. I'm trying to activate a library stack
using this code:(line
I was thinking of using a substack with the visible
set to false to store preferences for a standalone.
If I am correct you can do this and then not make
a standalone out of the substaack and then you
are able store them in a custom property. If this
is a good approach should I make a new object
Using a library stack for the first time and wondering the best practices
for where to locate it. Application support folder, same folder as the
application using it, somewhere else?
Pete
lcSQL Software http://www.lcsql.com
Home of lcStackBrowser http://www.lcsql.com/lcstackbrowser.html and
On 9/27/2014, 6:31 PM, Peter Haworth wrote:
Using a library stack for the first time and wondering the best practices
for where to locate it. Application support folder, same folder as the
application using it, somewhere else?
I always make them substacks. That way they are always available
Not the way you are doing it. Only the STACK script is in the message path. Not
every script of every object IN the stack!
That being said, you could certainly insert the script of every card of the
library stack, but that might be messy. An alternative might be to put all the
handlers in the
this message in context:
http://runtime-revolution.278305.n4.nabble.com/Best-Practice-for-Library-Stacks-tp4675854p4676032.html
Sent from the Revolution - User mailing list archive at Nabble.com.
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please
What you are calling Scripts are actually Handlers. A Script is the entire
chunk of code, containing 0 or more commands and/or functions, which belongs to
an object. A handler is everything between and including an on/command/function
statement and it’s corresponding end statement.
In the
Hello,
I have a library stack which consists all my common functions and commands.
Calculations, text manipulation, getting device info, update procedures, etc.
Stack’s script is close 5000+ line of code.
I wanted to organize it and put related handlers into the script of respective
cards.
Hi Ender,
Stacks in use receive messages at stack level, not at card level.
Use a button for each part of your library and use backscripts and frontscripts.
--
Best regards,
Mark Schonewille
Economy-x-Talk Consulting and Software Engineering
Homepage: http://economy-x-talk.com
Twitter:
m.schonewi...@economy-x-talk.com
Date: February 13, 2014 at 13:19:32
To: How to use LiveCode use-livecode@lists.runrev.com
Subject: Re: Best Practice for Library Stacks
Hi Ender,
Stacks in use receive messages at stack level, not at card level.
Use a button for each part of your library
You can have more Library stacks loaded (via start using) than you can
insert back scripts or front scripts. The numbers used to be 50 library
stacks and 15 front and 15 back scripts. I am not sure if that has
changed with recent releases. This may or may not make a difference for
you depending
Paul Dupuis wrote:
You can have more Library stacks loaded (via start using) than you can
insert back scripts or front scripts. The numbers used to be 50 library
stacks and 15 front and 15 back scripts. I am not sure if that has
changed with recent releases.
It seems that it has.
I'd been
Ender Nafi wrote:
Is there any difference, especially performance-wise, between these two
approaches:
1. Library code is in the library stack’s script and it’s activated by
_start using stack “libraryCode”
2. Library code is distributed to different buttons of a card of the main stack
and
the
handlers contained within a single button?
Bill
William Prothero
http://es.earthednet.org
On Feb 13, 2014, at 6:50 AM, Richard Gaskin ambassa...@fourthworld.com
wrote:
Paul Dupuis wrote:
You can have more Library stacks loaded (via start using) than you can
insert back scripts or front
Earthednet-wp wrote:
I like the idea of putting libraries into buttons, then copying
them into the front script at startup. When you say there is a
limit of some number of scripts, what counts for a script? Is
a single script counted as all the handlers contained within a
single button?
I couldn’t decide which line to quote from Richard’s posts;
You know, because of the 15kb limit of list :)
In short, I’ve learned much.
For my situation, using library stacks is less convenient.
And the possibility of hooking chained behaviors to the backscripts seems very
promising.
I already
Richard-
Thursday, February 13, 2014, 7:46:16 AM, you wrote:
There used to be limits; it remains to be seen if there still are, or if
the Dictionary entry for scriptLimits just needs to be updated.
Last time I looked in the code, the script limits were commented out.
--
-Mark Wieder
Richard,
My question was probably too elementary, but what I was really asking is:
Do all of the handlers in a single button script count as a single script, or
is a single handler in the button script counted as a script, for purposes of
scriptLimits.
If only 10 front scripts were allowed, the
Earthednet-wp wrote:
Richard,
My question was probably too elementary, but what I was really asking
is:
Do all of the handlers in a single button script count as a single
script, or is a single handler in the button script counted as a
script, for purposes of scriptLimits.
There was no
Wasn't the ten lines of 'do' commands a very old demo version thing?...
Designed to keep testers from do-ing too much without buying the product?
And wasn't it removed long ago?
Questions, questions, questions...
~Roger
On Feb 13, 2014 12:11 PM, Richard Gaskin ambassa...@fourthworld.com
wrote:
70 matches
Mail list logo