• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

[JS][CS3] Script to edit script

Participant ,
Mar 03, 2010 Mar 03, 2010

Copy link to clipboard

Copied

HI

I have made a script that passes values into another script and re-saves the new script.  This works fine, but I really need to save as a binary version.

Is this possible?

Cheers

Roy

TOPICS
Scripting

Views

576

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

LEGEND , Mar 03, 2010 Mar 03, 2010

I don't think so.

I would use a different strategy. Write the values to a separate file

and read those in your script.

Harbs

Votes

Translate

Translate
LEGEND ,
Mar 03, 2010 Mar 03, 2010

Copy link to clipboard

Copied

I don't think so.

I would use a different strategy. Write the values to a separate file

and read those in your script.

Harbs

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Participant ,
Mar 03, 2010 Mar 03, 2010

Copy link to clipboard

Copied

Ah yes, didn't think of that.  That would work fine.

Thanks Harbs!

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guide ,
Mar 03, 2010 Mar 03, 2010

Copy link to clipboard

Copied

Harbs is right, but if your need is to update some litteral or numeric values in a jsxbin where you have preformatted fields, it is possible to directly encode and re-inject the data within, using elaborately the File.seek and File.write methods with your encoder. You'll find a few clues about this technique here: http://www.indiscripts.com/post/2009/11/can-indesign-script-rewrite-itself

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Mar 03, 2010 Mar 03, 2010

Copy link to clipboard

Copied

I forgot about that post of yours. Really cool stuff!

The fact of the matter is, I think writing small text files is a lot

easier that messing with the script code. You can also use

app.insertLabel very effectively.

Harbs

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guide ,
Mar 03, 2010 Mar 03, 2010

Copy link to clipboard

Copied

LATEST

Yep! For most projects jsxbin injection is expensively complex and there is no reason to use it. Actually I only use this technique to watermark a script on the fly from PHP.

@+

Marc

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines