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

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

Recommended Posts

Posted
Having a strange problem. This applescript step is only working on SOME computers in our office and not all. The error we get is the path can not be found.
 
On the computers where it does not work, if I enter the full path instead of using 'set x to cell' it DOES work...so the path does exist.
 
So far I have ruled out different versions of FM, FM user/permissions issue, different operating systems or connection type to server.
 
I have done this many scripts and can not figure out why this one is not working. Any help would be much appreciated.
 
set x to cell "mediaprojects_path" of current record
set y to cell "deliveryPackageName" of current record
do shell script "mkdir /Volumes/networkFootage/Digital_Deliverables_Packages/" & x & "/_Delivery_Packages/" & y
Posted

Have you checked the values of x & y on these computers? Perhaps they need shell escaping because they contain spaces, are empty or contain one of

/ : "

 

Does the containing folder for the resulting path exist?

 

There are many ways how this script can fail.

Posted

Yes the path does exist. I am using the same path on a server from all different computers. All computers see it when I enter the values directly without the  variables.

 

I am curious about the : that you mentioned. That did appear on the error message... /Volumes/mypath/: does not exist. I assumed the colon just inserting itself into the error message...am I wrong about that?

Posted

Double checked...there are no colons in the path. Just to be clear this is not a problem in just one script. This is happening in many scripts. I can copy the path out of a FM field, put into a Terminal window and it works fine. This is definitely an FM issue, but I don't know what to adjust since everything seems to be correct. 

Posted

FileMaker refuses for example to import pictures if any of the path elements contains a ':' which will be shown in the Finder as '/'.

 

For unix a '/' is an illegal char in  a file or foldername .

 

For the old MacOS ':' had the same meaning as '/' has for unix.

 

The Finder exchanges the two because people like to name folders with a '/' in it.

 

 

Have you checked shell escaping?

 

?,:,*,",' have special meaning in a shell.

 

Perhaps that last line should be:

 

 

do shell script "mkdir '/Volumes/networkFootage/Digital_Deliverables_Packages/" & x & "/_Delivery_Packages/" & y &"'"
 
If all that fails, go to 360works.com, download the free version of the ScriptMaster Plug-in, get acquainted with it and use it to create new folders. It would at least remove 2 redirections; the shell and applescript.
 
-karsten
Posted

Thanks Karsten I will look at the plugin. This still perplexes me as to why this script stopped working. It had been working for about 6 months and then just stopped. Nothing on our systems has really changed in that time frame either.

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