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

how get dimensions text frames Before Place on Pages? script

Community Beginner ,
Feb 06, 2018 Feb 06, 2018

Copy link to clipboard

Copied

how get dimensions text frames Before Place on Pages?

text frames is into a indd file .

this code get dimensions image Before Place.

var extensionlist = [ 'pdf', 'png', 'tif', 'indd', 'jpeg', 'jpg', 'png' ]; 

if (File.fs == "Windows") 

  selector = []; 

  for (i=0; i<extensionlist.length; i++) 

  selector = '*.'+extensionlist

  selector = selector.join(','); 

  imglist = Folder.myDocuments.openDlg( 'Select images', "Image:"+selector+";All files:*.*", true); 

}

 

if(imglist != null) 

  var sizelist = []; 

 

  for (i=0; i<imglist.length; i++) 

  { 

  r = app.activeDocument.pages[0].place(imglist, [0,0])[0]; 

  sizelist.push ([Math.round(r.geometricBounds[3]-r.geometricBounds[1]), 

  Math.round(r.geometricBounds[2]-r.geometricBounds[0])]); 

  r.parent.remove(); 

  } 

  app.activeDocument.placeGuns.loadPlaceGun(imglist, false); 

  alert (sizelist.join('\r')); 

}

TOPICS
Scripting

Views

315

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
Community Expert ,
Feb 06, 2018 Feb 06, 2018

Copy link to clipboard

Copied

Moving to InDesign Scripting forum

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
Community Expert ,
Feb 06, 2018 Feb 06, 2018

Copy link to clipboard

Copied

I see the topic "text frames" in the title here.

I cannot see a text frame in the provided code.

The provided code is not placing a story with a text frame from e.g. a snippet idms file.

It also does not place a text file.

So do you really mean:

"… how get dimensions text frames Before Place on Pages?"

Sorry. I don't get what you want.

Regards,

Uwe

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
Community Beginner ,
Feb 06, 2018 Feb 06, 2018

Copy link to clipboard

Copied

LATEST

text frames in indesign file .

There are several files indesign, i want merge(arrenge) all file and product one file.

i want script code for arrenge sevral file into one file indd.

ok?

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