Cloning cards

Joe Lewis Wilkins pepetoo at
Thu Nov 18 11:11:23 EST 2010

Hi Richard,

I'll save this approach as a plan "B"; for now, I think, I'll just create a brand new, expandable Main Stack that I can use when the user needs to create new forms. I think I can probably do this by just creating a dummy empty stack and, then, when I need additional copies of a Form, instead of cloning that Form in the sub-stack, I'll copy it, go to the dummy stack and paste it. That may also make the sequencing of Forms easier. Your suggestion, though I'm sure it is great, appears to be a bit too complex for me at this time. Plus, it is always a good idea to have a Plan B around. (smile) My problem is: if I don't think of something, I sometimes have trouble understanding how someone else's way of doing things works. It's a "my brain" problem we all face in our declining years. The "old dog - new tricks syndrome" if you will. I'm still struggling with the custom properties concept. (smile) Thanks...

Joe Wilkins 

On Nov 18, 2010, at 7:54 AM, Richard Gaskin wrote:

> Joe Lewis Wilkins wrote:
> > My dilemma, now, is that this sub-stack is already part of the
> > standalone, so splitting it off as another stack file may not
> > be so easy. OTOH, it may also solve an issue I now have
> > communicating between that "sub-stack" and the main stack in
> > the standalone.
> Maybe not so bad - consider trying this:
> Rename the existing substack something like "SubstackNameTEMPLATE", when add this when you need to create a savable document:
>  -- Make the savable stack:
>  clone stack "SubstackNameTEMPLATE"
>  set the name of it to "SubstackName"
>  -- Now to save it in some writable location:
>  set the filename of it to MyDataPath()
>  save stack "SubstackName"
> In a central library you can use this handy function to find the path to the file for saving or opening:
> function MyDataPath
>   switch the platform
>   case "MacOS"
>     put specialFolderPath("asup") into tPath
>     break
>   case "Win32"
>     put specialFolderPath(26) into tPath
>     break
>   case "Linux"
>     put specialFolderPath("home")&"/Documents" into tPath
>   end switch
>   --
>   put "/MyAppName/" after tPath
>   if there is not a folder tPath then
>     create folder tPath
>     if the result is not empty then
>        answer "Error: "& the result
>        exit to top
>     end if
>   put "MyDocumentName.myExtension" after tPath
>   return tPath
> end MyDataPath
> The above is off-the-cuff and untested, but I've written similar handlers often so hopefully it will be at least mostly working and somewhat helpful. :)
> --
> Richard Gaskin
> Fourth World
> LiveCode training and consulting:
> Webzine for LiveCode developers:
> LiveCode Journal blog:
> _______________________________________________
> use-revolution mailing list
> use-revolution at
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:

More information about the use-livecode mailing list