Discussion of the xtools Toolkit

Moderators:xbytor, DavideBarranca, Paul MR

Post Reply

Post by myranalis » Wed Apr 07, 2010 12:05 pm

I am trying to create an action which has a single step which is running a script from a set location. My problem is I am on a windows machine, but I want to create an action that will be run on a mac. When I run the ActionFileFromXML file the path for the script is being set to C:\Macintosh HD\... which is not what I'm after

Is there a way around this? Or to accomplish the same thing in another way?



My action XML below...
Code: Select all<ActionFile key="ScriptMenuMethod.atn" file="/c/DOCUME~1/annaf/LOCALS~1/Temp/ScriptMenuMethod.atn">
   <ActionSet version="16" name="Test" expanded="false" count="1">
      <Action key="1" name="Run Script" expanded="false" count="1">
         <ActionItem key="TEXT" expanded="false" enabled="true" withDialog="false" dialogOptions="0" identifier="TEXT" event="AdobeScriptAutomation Scripts" name="Scripts" hasDescriptor="true">
            <ActionDescriptor key="AdobeScriptAutomation Scripts" count="2">
               <DescValueType.ALIASTYPE key="1785938804" id="1785938804" symname="javaScript" sym="javaScript" path="/MACINTOSH HD/Library/Application Support/Test.jsx"></DescValueType.ALIASTYPE>
               <DescValueType.STRINGTYPE key="1785941363" id="1785941363" symname="javaScriptMessage" sym="javaScriptMessage" string="undefined">

Mike Hale


Post by Mike Hale » Wed Apr 07, 2010 3:24 pm

Xbytor has a script named 'ChangeScriptPaths.jsx' that will change the path in a saved atn file.



Post by xbytor » Wed Apr 07, 2010 4:48 pm

One note: because of the way that File objects are dealt with in PS and stored in ActionDescriptors, you have to convert the action on the user's machine. There is no way that I know of to create an Action file on a PC that contains a valid Mac path. The actual File object is stored in native OS format in the Action file which is what causes these path portability problems.




Post by myranalis » Wed Apr 07, 2010 11:13 pm

bugger. to date I've been begging a mac person to create these actions for me to get around the problem. I was really hoping I could do it myself - but i guess i'd better practice my begging



Post by xbytor » Thu Apr 08, 2010 1:09 am

Use an installation script that builds the Action file on the end users machine.

Post Reply