我通过.bat脚本调用.jsx脚本(.bat是我的用户必备的启动脚本)。 .jsx正在启动具有特定颜色设置的Photoshop。在.jsx运行之后,.bat不会继续。
我可以手动退出Photoshop,然后.bat会继续。任何人都有任何想法如何允许.bat在调用.jsx后继续进行?
.bat脚本:
"C:\Program Files\Adobe\Adobe Photoshop CS6 (64 Bit)\Photoshop.exe" "path\PS_Color_Settings.jsx"
.jsx脚本:
setColorSettings();
function setColorSettings() {
var desc = new ActionDescriptor();
var ref = new ActionReference();
ref.putProperty( charIDToTypeID( "Prpr" ), stringIDToTypeID( "colorSettings" ) );
ref.putEnumerated( charIDToTypeID( "capp" ), charIDToTypeID( "Ordn" ), charIDToTypeID( "Trgt" ) );
desc.putReference( charIDToTypeID( "null" ), ref );
var colorSettingsDesc = new ActionDescriptor();
colorSettingsDesc.putString( stringIDToTypeID( "workingRGB" ), """sRGB IEC61966-2.1""" );
colorSettingsDesc.putEnumerated( stringIDToTypeID( "policyRGB" ), stringIDToTypeID( "policy" ), charIDToTypeID( "Cnvr" ) );
colorSettingsDesc.putBoolean( stringIDToTypeID( "askMismatchOpening" ), true );
colorSettingsDesc.putBoolean( stringIDToTypeID( "askMismatchPasting" ), true );
colorSettingsDesc.putBoolean( stringIDToTypeID( "askMissing" ), true );
desc.putObject( charIDToTypeID( "T " ), stringIDToTypeID( "colorSettings" ), colorSettingsDesc );
executeAction( charIDToTypeID( "setd" ), desc, DialogModes.NO );
}
.jsx运行并且photoshop启动后,.bat脚本停止运行并且不会继续执行后续步骤。我试过插入一个' GOTO'和一个'结束'在调用.jsx之后,似乎没有任何东西让.bat脚本回到正轨。有什么想法吗?
答案 0 :(得分:1)
尝试START
命令(如@Squashman建议的那样):
In [63]: fn = r'D:\temp\.data\1.fwf'
In [64]: df = pd.read_fwf(fn, header=None)
In [65]: df
Out[65]:
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
0 SiC4+ e- C2 c-SiC2 1.500000e-07 -0.5 0.0 2.0 0.0 logn 8 10 280 3 746 1 1
1 SiC4+ e- C l-SiC3 1.500000e-07 -0.5 0.0 2.0 0.0 logn 8 10 280 3 747 1 1
2 O e- O- NaN 1.500000e-15 0.0 0.0 2.0 0.0 logn 8 10 280 3 744 1 1
3 S e- S- NaN 5.000000e-15 0.0 0.0 2.0 0.0 logn 8 10 280 3 745 1 1
这样的事情(为了便于阅读而扩展)
START "title" [/D path] [options] "command" [parameters]