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

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

Recommended Posts

  • Newbies
Posted

Good day,

I have a FileMaker solution that utilizes SuperContainer to hold attachments that are linked to specific jobs. When we first implemented SC, we attached the items to the job rather than the customer, and have since realized that attaching them to the customer is the better way to handle it.

For example, attachments are now held in a folder "/job/type_of_attachment/job_number/attachment_id/filename.pdf"

I'd like to move those files so that they're held by customer (in a different table). So I'd like the file path to change to "customer/customer_number/type of attachment/attachment_id/filename.pdf"

Really all that's changing is the path name. Jobs and Customers share a relationship via the Customer Number, so I was able to write a script that wrote the customer number to a variable, and then ran SCMove, replacing the old path with the new.

The problem is that while the script indicates that SCMove was successful, the file has not moved. It remains in its original location.

Am I not understanding how SCMove is intended to be used? Does anyone know a better way to do this?

Your help is greatly appreciated.

Best,

Shane Grimsley

Posted

Well there are two things that stand out here. The first one is you shouldn't ever make a folder with the name of the file you are storing in it. What I think is the more likely case, however, is that you are trying to move the file by name with SCMove(), which is not how SCMove works. SCMove moves the file, but it goes one step further than the path you specify. For example, if filename.pdf is the file you want to move and it's in the attachment_id folder, your SCMove should end with .../attachment_id/ because SCMove is going to move the file that's inside the attachment_id folder.

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