April 2, 201114 yr Hello, I need to copy a directory and its content to an external drive. I've seen and experimented the CopyFile function of Scriptmaster. Two questions : Is there a way to adapt it to copy a directory by passing in src /Volumes/Data/Desktop/Xtine/for example ? If not is it possible to say copy all files (equivalent of use jokers *.*) ? Thanks for your answers ? Noël
April 2, 201114 yr We are actually looking for same thing but we'd also like something that can compare the backup to the source (essentially looks at the backup folders and files and when there are changes in the source, update only what has changed - like a smart update backup function). Any thoughts? Hello, I need to copy a directory and its content to an external drive. I've seen and experimented the CopyFile function of Scriptmaster. Two questions : Is there a way to adapt it to copy a directory by passing in src /Volumes/Data/Desktop/Xtine/for example ? If not is it possible to say copy all files (equivalent of use jokers *.*) ? Thanks for your answers ? Noël
April 4, 201114 yr Noel, You can use a combination of the List All Files In Directory, List all Files Recursively, and Move or Rename File modules along with FileMaker scripting to do what you are looking for. JLC, There is not currently a module to do this that comes with scriptmaster. If you would like us to write an additional module or make a custom plugin for you to do this, please send an email to [email protected] along with details about what you need it to do and we will send you a quote.
April 4, 201114 yr Author Noel, You can use a combination of the List All Files In Directory, List all Files Recursively, and Move or Rename File modules along with FileMaker scripting to do what you are looking for. I'll try to understand and perhaps build he solution you describe... but I'm at a small level ! Noël
April 4, 201114 yr JLC, I was wrong actually. There is a Get File Modification Date module which you could use for checking to see if a file has been modified since you last checked it.
April 10, 201114 yr The lazy way ... Commons-IO-2.0.1.Jar // Usage : CopyDirectory ( fm_source ; fm_destination ) // 2011_04_10 // v1 // jar : Commons-IO-2.0.1.Jar @ http://commons.apache.org/io/ import org.apache.commons.io.FileUtils source = new File( fm_source ); destination = new File( fm_destination ); try { FileUtils.copyDirectory( source , destination ) return 1 } catch (IOException e) { return e }
Create an account or sign in to comment