Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 5012 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

I have a backup script that runs when the file is opened which saves a copy of the file.

I want to save the name with a timestamp so I'm setting this variable in the script:

Set Variable [$filename ; "MyDatabseBU_"&Timestamp(Get(CurrentDate);Get(CurrentTime))&".fp7"

Save a Copy as [$filename;copy]






This returns the error




“MyDatabseBU_03-05-2011 3:10:58 PM.fp7” could not be created on this disk.  Use a different name, make more room on the disk, unlock it or use a different disk.

If I change Save a Copy as [filename;copy] it saves a file called "filename" so the path seems correct.

The full path on my Mac is file:../Documents/FM_Backup/$filename

thanks for any pointers,

jim

Posted

First,

Timestamp(Get(CurrentDate);Get(CurrentTime))




is a rather cumbersome way to write:




Get ( CurrentTimeStamp ) 

Next, in Mac OS X at least, a filename cannot contain colons.

Posted

And to add just a bit more to Comment's suggestion:

Set Variable [$filename ; "MyDatabseBU_" & substitute( Get(CurrentTimeStamp); ":"; "-") & ".fp7" ]

Posted

And, of course, this isn't the best way to back up a hosted database, but it's a good technique to use while developing in single user.

This topic is 5012 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.