Saving stack to file

Deploying to Mac OS? Ask Mac OS specific questions here.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
Bruce Underwood
Posts: 8
Joined: Thu Oct 23, 2008 12:10 pm
Contact:

Saving stack to file

Post by Bruce Underwood » Sun Feb 15, 2009 11:01 am

I am using an i-MAC with OS 10.5.6

I am trying to save a stack using save stack as [filePath] and am getting nowhere. I want to save the stack to my Desktop, or if it is possible, to a DVD-RW disc.

As background, I have created an application named "Recipe Book" in which the user can type her recipes on a form page; When she clicks the INSTALL button, the information is placed on a formatted recipe page. The page looks nice. It has buttons at the bottom for HOME, PRINT and SAVE. The PRINT and HOME buttons work, but I can't get the script right for the SAVE button.

I appreciate any help you can give me.

Thanks

Willie B. Underwood
Bruce Underwood
1457 Nutbush Road
Victoria, VA 23974
bruceu@embarqmail.com
Telephone: (434) 696-5539

asayd
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 107
Joined: Mon Apr 10, 2006 7:02 pm
Contact:

Saving stack to file

Post by asayd » Fri Apr 03, 2009 7:06 pm

Bruce,

Did you ever get this working? From what you posted it looks fine, although you didn't show your actual code. The only reason I can think of why it wouldn't save to a particular place is that you don't have write permission. In this case it will fail silently, but you can capture the error with the result function.

Code: Select all

save this stack as "/folder/mystack.rev"
get the result
if it is not empty then answer it
As a side note, you might find the specialFolderPath function useful for quickly designating platform-appropriate folders for various purposes, e.g., Desktop, Preferences, etc.

Regards,
Devin
Devin Asay
Learn to code with LiveCode University
https://livecode.com/store/education/

Post Reply