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

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

Recommended Posts

Posted

Hello

I would like to import a file from another network drive through server scripting during my overnight updates. How do I get the file over to the FMP Server documents folder so Server can do the import? I read the documentation for FMP server, but have no idea how to do it.

Thank you very much.

Posted

Is your server a Mac? If yes, you can use unix scripting to copy the file to the the documents folder, then import it. You can even combine these scripts in FM now, so it'll run the first script then the second one. Look into scp or generally copying files on linux/unix. I have written stuff like this before (from Linux to Mac server so the tape backup can pick up the file) and once it's in place it works like an oiled machine.

Not sure what can be used on Windows.

Also, there are plug-ins you can install and run on the server that can do this. 24u has a folder plug-in and then there's the Troi file plug-in. Look into them.

Posted

command line scripting on Windows will do the same thing. Batch files, PowerShell or VBscript, they will all work.

Posted

The server is Windows. I think I may have used the Troi file plugin years ago. It's a while since I've used the command line, but I know it's just not that hard. I'll give that a shot.

Thanks

  • 2 weeks later...
Posted

Ok, so I'm trying to use a simple batch file to copy the files over.

It's basically a few lines that look like this to copy over each file I want to import:

copy "I:BUYINGBUY37801.TXT" "C:Usersfilemaker.FILEMAKER-SRVDocumentsImportBUY37801.TXT"

It's in the scripts folder and I can schedule it.

If I double click on it, it runs fine, but I get Aborted by User when the server runs it through the scheduler.

How do I get this to work?

Posted

Updated code to move to the correct documents folder:


copy "I:BUYINGBUY37801.TXT" "C:Program FilesFileMakerFileMaker ServerDataDocumentsImportDataBUY37801.TXT"

and now access is denied so the script does not work when run manually or when scheduled

:hmm:

Posted

Finally got it to work. Switched the path to UNC syntax after reading this post and moved the files to the path I got from the get documents path function, so now the scheduled server script runs successfully.

This topic is 4507 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.