Forum Replies Created
-
AuthorPosts
-
Kasyan Servetsky
MemberThis works for me:
grep tab {findWhat:”\d+”, position:Position.SUPERSCRIPT} tab {appliedCharacterStyle:”Superscript”}
Kasyan Servetsky
MemberA few days ago I wrote a similar script.
Kas
Kasyan Servetsky
MemberYes, there is. Check out this script.
Kas
February 22, 2012 at 3:31 am in reply to: Batch opening multiple text boxes in InDesign CS 5.5 #61671Kasyan Servetsky
MemberNovember 24, 2011 at 12:04 am in reply to: Resize graphic frames with an Object style applied #61147Kasyan Servetsky
MemberHi Mike,
Try to add this line:
app.findChangeObjectOptions.objectType = ObjectTypes.GRAPHIC_FRAMES_TYPE;
It corresponds to the “Type: Graphic Frame” option in the “Object” tab of the “Fing/Change” dialog box. Most probably it is set to a wrong type e.g. “Text Frame” at the moment and the script finds nothing.
Hope this helps.
Kasyan
November 5, 2011 at 2:15 pm in reply to: How access both InDesign and Photoshop in one script? #61007Kasyan Servetsky
MemberYeah, the bridgetalk chapter in JS tools guide is confusing. Moreover, it contains many typos so many examples doesn't work. I recommend you to download Bridge SDK:
https://download.macromedia.com…..in_001.zip (Windows)
https://download.macromedia.com…..ac_001.dmg (Mac)
It contains several working examples of sending bridgetalk from Bridge to InDesign, Photoshop, etc (the same approach works for all applications). They are quite simple and well commented so this is a good starting point for you.
Here is another (simple) example: https://kasyan.ho.com.ua/bridge…..bject.html
You can find more examples with detailed explanations on adobe scripting forum.
Here is another example: a simple resize images script: kasyan.ho.com.ua/downloads/simple_resize_script.zip
Kasyan
November 5, 2011 at 4:07 am in reply to: How access both InDesign and Photoshop in one script? #61004Kasyan Servetsky
MemberArrrgh… Something went wrong with the last link.
kasyan.ho.com.ua/downloads/automate_pdf_export_6.zip
November 5, 2011 at 4:02 am in reply to: How access both InDesign and Photoshop in one script? #61003Kasyan Servetsky
MemberI wrote a number of such scripts. A few of them you can find on my site. For example, Resize images for Power Switch and Resize images.
– can I call a Photoshop action from the InDesign script?
Yes, you can. Here's an example. It displays available in Photoshop sets and the actions for each set in the dialog box and calls the selected action in line #205:
if (eval(myRunAction) == true) app.doAction(myAction, mySet);
Hope this helps.
KasyanKasyan Servetsky
MemberHere I posted some links that might be useful for baby-scripters. I started scripting in 2004. Before I had nothing to do to programming. I tried all the three scripting languages: Visual Basic, Apple Script and JavaScript. In my opinion, the best choice is JavaScript — it's cross-platform, and you can find more support on scripting forums because it's the most popular. Though knowing other languages helps me a lot too.
In conclusion, I want to say an important thing: absolutely everybody can write scripts — just invest some time and effort into learning and you'll get your investment back hundredfold.
Regards,
KasyanKasyan Servetsky
MemberHere is an example:
text tab {findWhat:””, bulletsAndNumberingListType:ListType.BULLET_LIST}tab {changeTo:””, appliedParagraphStyle:”Paragraph Style 1″}tab … and so on…
Tested in CS5.5 for Windows.
Kasyan Servetsky
MemberHi Bill,
I just checked the InDesign CS2 Scripting Reference and yes, theoretically it should work. However, I can't check this in practice — don't have CS2 any more.
Regards,
KasyanKasyan Servetsky
MemberThanks, Jongware.
Before I tried to use pre-tags to enclose code in HTML editor, but this had no effect. Now I see that I should use code-tag inside pre-tag.
Kasyan Servetsky
MemberJongware, how did you post the code with the 'Select code' button?
Kasyan Servetsky
MemberThe forum software spoils the code: before the closing parentheses it replaced inch marks with quotes. If you change them back to parentheses, it should work. Here I posted the script to avoid problems with coping and pasting to/from the forum.
-
AuthorPosts