Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import org.codehaus.groovy.scriptom.*
- //
- // 引数として渡されたJSファイルのチェック
- //
- boolean ng=false
- if( args.size()<1 ){ ng=true }
- else if( new File(args[0]).exists()==false ){ ng=true }
- if(ng){
- System.exit(0)
- }
- //
- // ExtendScriptの実行
- //
- Scriptom.inApartment
- {
- def myJS = new File(args[0]).text
- int lang = 1246973031 // javascript
- //def indapp = new ActiveXObject('InDesign.Application')
- //def indapp = new ActiveXObject('InDesign.Application.CS4_J')
- def indapp = new ActiveXObject('InDesign.Application.CS3_J')
- indapp.doScript(myJS, lang )
- }
Add Comment
Please, Sign In to add comment