Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Problem with SCMove

Featured Replies

  • Newbies

Hello,

I am trying to use the SCMove function to move a file from one directory to another inside my SuperContainer location. Currently my function call looks something like this:


SCMove("WorkingDirectory/UniqueResourceDirectory/","TargetDirectory/"&TABLE::ID)





When I run my script, I get an error, and the supercontainer server says:



Move operation failed: java.io.FileNotFoundException: No SuperContainer file for /WorkingDirectory/UniqueResourceDirectory

No SuperContainer file for /WorkingDirectory/UniqueResourceDirectory



I have also tried my function call like this:





SCMove("WorkingDirectory/UniqueResourceDirectory/file.pdf","TargetDirectory/"&TABLE::ID)

In which case I get the same error but like this:

Move operation failed: java.io.FileNotFoundException: No SuperContainer file for /WorkingDirectory/UniqueResourceDirectory/file.pdf

No SuperContainer file for /WorkingDirectory/UniqueResourceDirectory/file.pdf

I am stumped, as I have tried many variations on the above themes, putting slashes in different places, with and without the file name, etc.

Can someone help? Or possibly provide a working example of how to call SCMove, since the companion plugin documentation does not have one.

Thanks,

Mark

Did you call SCSetBaseURL ( ) first?

Also you are defining the path to a folder, not a file, in the 'from' path

  • Author
  • Newbies

Did you call SCSetBaseURL ( ) first?

Yes. I call it in my onOpen() script for the file.

Also you are defining the path to a folder, not a file, in the 'from' path

Hi. I'm not sure if you are telling me this information or asking me for it, but either way, I have tried both. That is, I have tried pointing to a file (first try) and then just pointing to a folder (second try). Both times, same error message, but with different paths, of course.

Thanks.

Like BCooney suggested, make sure that the baseURL you are setting is the correct one.

Next, make sure a file actually exists in the folder you are passing in: "WorkingDirectory/UniqueResourceDirectory/". If so, that's good. Another small nuance, is whether the former directory requires a "/" prior to. So, have you tried something like:

SCMove( "/WorkingDirectory/UniqueResourceDirectory/" ; "/TargetDirectory/" & TABLE::ID )

I hope this helps. If you have any additional questions or are unable to get this to work with some more trial and error, please do not hesitate to contact me directly at the e-mail address or phone number listed below.

Regards,

Create an account or sign in to comment

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.