Revision: 17129
Updated Code
at August 24, 2009 11:24 by myhd
Updated Code
#!/opt/local/bin/perl -w # ^^^ your hashbang may vary use strict; use warnings; `/usr/bin/osascript <<-HereDoc tell application "Adobe InDesign CS4" do script " // start your javascript code controlling InDesign here var myObject = app.selection[0]; // grabs selected object in INDD alert(myObject); // show object kind // javascript code ends here " language javascript end tell HereDoc`;
Revision: 17128
Updated Code
at August 24, 2009 11:21 by myhd
Updated Code
#!/opt/local/bin/perl -w use strict; use warnings; `/usr/bin/osascript <<-HereDoc tell application "Adobe InDesign CS4" do script " // start your javascript code controlling InDesign here var myObject = app.selection[0]; // grabs selected object in INDD alert(myObject); // show object kind // javascript code ends here " language javascript end tell HereDoc`;
Revision: 17127
Updated Code
at August 24, 2009 11:18 by myhd
Updated Code
#!/opt/local/bin/perl -w use strict; use warnings; `/usr/bin/osascript <<-HereDoc tell application "Adobe InDesign CS4" do script " // start your javascript code cintrolling InDesign here var myObject = app.selection[0]; // grabs selected object in INDD alert(myObject); // show object kind // javascript code ends here " language javascript end tell HereDoc`;
Revision: 17126
Updated Code
at August 24, 2009 11:17 by myhd
Updated Code
#!/opt/local/bin/perl -w use strict; use warnings; `/usr/bin/osascript <<-HereDoc tell application "Adobe InDesign CS4" do script " // start your javascript code cintrolling InDesign here var myObject = app.selection[0]; // grabs selected object in INDD alert(myObject); // show object kind // javascript code ends here " language javascript end tell HereDoc`;
Revision: 17125
Initial Code
Initial URL
Initial Description
Initial Title
Initial Tags
Initial Language
at August 24, 2009 11:12 by myhd
Initial Code
#!/opt/local/bin/perl -w use strict; use warnings; `/usr/bin/osascript <<-HereDoc tell application "Adobe InDesign CS4" do script " var myObject = app.selection[0]; alert(myObject); " language javascript end tell HereDoc`;
Initial URL
Initial Description
This example demonstrates a way to control Adobe InDesign from Perl. Tested on MacOS X 10.5.7 and INDD.
Initial Title
Perl to InDesign CS4 example (OS X)
Initial Tags
javascript, mac, osx, perl, design
Initial Language
Perl