December 6, 20196 yr Newbies Hi, I am after a fairly simple thing yet the new FM18 file features don't seem to do what I want... Goal: I want to import a file for external container storage. I want to change the filename so that it is stored with a job number prefixed to the front. So, all I am really doing is renaming a file. I don't want to use a plugin. That said, we have an ftp plugin and I think it may do this for us so I could do that but I prefer to avoid. I think I could do this: - Import into a global container, export it using a different name to the temporary folder, import it into the correct long term storage field and then delete the contents of the global container. HOWEVER - some of these files are huge (greater than 1 GB) and this then involves an import, an export and an import so I am now moving 3GB instead of 1. So, what I would like to do is this: - Grab the path of the file (BUT it seems there is no script step for this basic thing in the new FileMaker 18 script steps) - Rename the file (temporarily) on the hard disk - Import the file. - Rename it again back to the original name. The sticking point is getting the path. Any ideas? THANKS.
December 6, 20196 yr I am not certain the reservation for using a plugin - I would highly recommend using BaseElements plugin (free) BE_FileMove ( fromPath ; toPath ) will allow you to rename the file.
December 6, 20196 yr 1 hour ago, Chris Van Buren said: - Grab the path of the file (BUT it seems there is no script step for this basic thing in the new FileMaker 18 script steps) I don't understand this step. Grab the path of which file? If you mean a file selected by the user, then there definitely is a script step for this: use the Insert File step to insert the selected file as reference into a variable. I didn't follow the rest of your plan. It seems to me that if you rename the file, then the path you grabbed in step #1 becomes irrelevant.
December 12, 20196 yr Author Newbies On 12/6/2019 at 4:25 PM, comment said: I don't understand this step. Grab the path of which file? If you mean a file selected by the user, then there definitely is a script step for this: use the Insert File step to insert the selected file as reference into a variable. I didn't follow the rest of your plan. It seems to me that if you rename the file, then the path you grabbed in step #1 becomes irrelevant. Yes. Of course. Thanks. I knew there had to be some way. THANKS. Works great.
Create an account or sign in to comment