Dev Project

Steve Messimer steve at messimercomputing.com
Fri Apr 12 09:31:01 EDT 2002


Dar Scott said:

> I want to make a stack to help me in development and I'm not sure
> how to start.
> 
> I want it to act like browse even though pointer (edit) is selected.

Not sure what you mean here.

> I want to know which card and stack I'm working on.

If you create a plug-in you can always get the name of the topStack and the
name or ID of the current card.

example:

put the short name of topStack into fld "objStackName"
put the id of the current card of the topStack into fld "objCardID"
-- I use the id because the plug-in that I am making can't be sure that a
card will always be named.  Of course, depending on what you want to do you
may want to store this info in variables.  I place it in flds because I want
to be sure where the Objects I am making are being created.

> 
> I want to make sure I don't fool with rev stacks.


It sounds like you need to make a plug-in.  This isn't well documented but
is relatively easy to do. Basically you create a stack and drop it in the
plug-ins folder.

 
> I might want to change the text in the rev script edit field.

Do you mean that you want to change one object's script via an event
executed in another Object (eg a btn click )

put the script of btn (fld, cd etc. ) objName into scriptChanger
-- then parse the info and make changes as needed

Completely change the script

on mouseUp
   set the script of grp myGrp to the newScript of me.
end mouseUp

-- In this instance I have created a custom property ( newScript ) to store
an alternative script for the grp myGroup.  Me is the Object that contains
the custom property  and the mouseUp handler. Once you have stored the
script as a custom property you can use it to modify any object's script.

You could also store the text of the handler in a fld and then

set the script of grp myGrp to fld "scriptHolder"

> 
> Dar Scott





More information about the use-livecode mailing list