measure the actual page for each page size in the listbox

Hi guys,.

I'm trying to write a script that lists all the pages in the ListBox with 2 additional columns: width and height

and stuck when trying to get the limits of pages for each page in the document.

My result looks like this now:

pagedimensions.jpg

script no matter what I'm trying to get only the size of the 1st page and fill in all items.

My code to get the size of the page above is:

myDoc = app.activeDocument;

page var = myDoc.pages [0];

...

function myRealHeight() {}

var Pbound = page.bounds;

var pH = Pbound [2] - Pbound [0];

var realHeight = [];

for (j = 0; j < myDoc.pages.length; j ++) {}

realHeight.push (pH);

}

Return realHeight;

}

I have tryied a few different ways but but always returned [object Page] or higher.

I'm newbie in scripts, and if someone could help me will be great.

Thank you

(let me know if other parts of the code are required)

Try this (sorry not tested).

var myDoc = app.activeDocument;

...

function myRealHeight() {}

var realHeight = [];

for (j = 0; j< mydoc.pages.length;="" j="">

page var = myDoc.pages [j];

var Pbound = page.bounds;

var pH = Pbound [2] - Pbound [0];

realHeight.push (pH);

}

Return realHeight;

}

Tags: InDesign

Similar Questions

  • Creating application for different screen sizes?

    Hello.  I recently created a Flash Professional help AS3 .apk file (probably obvious in this forum, but I wanted to be clear).  I tested it on a Tablet Android from ASUS.  However, I realized that even if I had the app to look good on this tablet, there are other tablets out there with many different sizes that could have the strange gaze of app.

    I searched on Google for advice on this, but a lot of it is not sensible.  Is there a fairly easy way to get your application to 'read' the Tablet dimensions and fits these dimensions?  I know I could do a different file for each screen size, but does not require put several files different app on the app store?  It sounds ridiculous.  Any tips?

    Try this to see if the results using different screen sizes:

    stage.scaleMode = StageScaleMode.SHOW_ALL;

  • How many profiles is there for each camera?

    When I develop my Nikon D700 raw files, I have the choice of a number of profiles such as Adobe Standard, camera Vivid, Portrait of camera neutral camera and different modes of DX2.

    However, with the raw files from my Olympus E - P1, I see only one profile; - Adobe Standard.

    None of the E - P1 as Vivid modes, silent, natural or Monotone seem to be emulated by Adobe.

    Is that correct and how do I know which profiles Adobe has actually produced for each camera?

    Ian

    Is that correct and how do I know which profiles Adobe has actually produced for each camera?

    Yes, not all cameras have camera-specific profiles. For the most part it is Canon and Nikon and a few others. Take a look at yto our camera raw profiles directory, you will see all of the profiles here. On Vista, you can find it here C:\ProgramData\Adobe\CameraRaw\CameraProfiles\Camera.

  • How to print a PDF file that contains mixed paper sizes (letter and legal) to make my printer choose the correct tray for each page?

    I followed the instructions here:

    Print mixed pages sizes | Acrobat, Reader

    But it did not work!  I use a Mac OSX 10.9.3, reader 10.1.10

    I discovered that, apparently, this plan just does not work on the Mac version of Adobe Reader software.  Thank you, Adobe, for a crappy experience.

  • Zoom in print - preview mode is for the display of the page size or the size of the content on the page?

    Print - Zoom preview.

    When I zoom it changes the size of the page on displays on the screen and it also changes the font size of the displayed text.

    Is this a bug or I'm doing something wrong.

    Either way, I need both the features...
    i.e., I want to change the size of the page, as it is displayed and I also want to be able to change the size of the content of the page - but I'd like to separate selection in box / controls for each.

    Print preview is a scale control, than the 'ladders' everything on the page, text and images. The paper size and margins are not changed when the 'balance', these controls are elsewhere. Basically, a scale of 50% will use half of the sheets of paper to print a Web page, it would be to shrink or 100% to adjust.

    Who answers your question fully?

  • I do my job to the computer on a MAC computer. I want to create a document using Pages and then convert the document to PDF and send a group email. I want to send the PDF using the pdf for each receiver icon must click the icon to open t

    I do my job to the computer on a MAC book PRO. I want to create a document using Pages and then convert the document to PDF and send a group email. I want to send the PDF using the pdf for each receiver icon must click the icon to open the document. My problem is the document does not show the icon, but rather the document is already open. I spoke with 2 Apple. 'Experts' care and can help me. Can someone tell me what to do?

    It's a question of how the recipients e-mail programs deal with attachments. Many e-mail programs will open all the files they can handle, including files jpg and PDF, by default, and if the recipient has not changed that there is nothing you can do about it. The only solution is to the compress first, then it will be delivered as an attachment, allowing the recipient to decompress and open it.

  • How to resize my screen? I do not see the menu f or at the bottom of web pages unless I have 'restore down' for a smaller size of the window.

    I do not see the menu f or at the bottom of web pages unless I have 'restore down' for a smaller size of the window.

    The problem is when you maximize the window - it is even bigger than the available surface? Or the problem is that normal windows are always too big and have to manually resize?

  • How to print 1 page for each line of the numbers worksheet

    Hello... I am trying to print reports of year-end per person and number.

    Is it possible in number to print 1 page for each row of a spreadsheet of numbers?

    Or suggestions?

    Thank you.

    Hi cm,

    This looks like a work of fusion and mailing.

    The merge document would create in Pages, and the cells of merger on this document référenceriez cells in the table in the document numbers.

    See the documentation Pages (on the Help menu) for instructions on the conduct of merger and mailing.

    To do this in only numbers, you would need to put in place a 'table of declaration' on a separate sheet (in the same document as the table containing information) which would accept a customer number (or other key ID for each individual) then use it to determine the line of the main table to retrieve information about this pattern.

    A more precise answer requires a more specific desription of your table structure and the desired form of the instruction to take.

    Kind regards

    Barry

  • [ADF, JDev 12.1.3] How to display multiple records on the same page... not in a table but they appear a form for each record

    Hallo,

    I need to create a page that displays the records of a VO, but I would not use a table.

    Instead, I would like to display a form for each record to be displayed.

    Forms must appear one above the other and each form should have 2 buttons: one to remove the file/form itself and one to add a new file/form.

    When you press the button Add a new empty form should be dynamically added to the page (so that the user can fill) and created related record.

    When REMOVE button is pressed the form (which contains the operated button) should be disappear and the record shuould be deleted.

    Creations and destruction must be applied only if the user clicks a button on CONFIRMATION / COMMIT.

    Maybe this http://digilander.libero.it/flattit82/OTN_FILES/MultiFormPage.png picture can help to understand what I want to do.

    You kindly help me?

    Thank you

    Federico

    Hi Federico

    I was saying that your page layout can be achieved using af: table

    See this image:

    This provision is af:table (I think same as yours), just add a column in the table and put all the fields in this column then correct layout allows to design as a provision on the form or group layouts

    I'm not saying it's the best approach, but you can try this

    Thank you

  • Is there a way to automatically assign the first fields of each page for each participant?

    I send you a document to three people to sign and each person needs to initial each page. Is it possible to automatically add an initial field on each page for each participant, or do I have to drag the initial field to each page for each participant?

    It is a unique document, BTW.

    Hello Joannaw75509803,

    You must manually add each original field at the location in the document and also, if you wish, you can use text tags that you add to the document before downloading in EchoSign and form fields would be created automatically. This is the same documentation:

    https://helpx.Adobe.com/document-cloud/help/adding-Esign-services-agreement-fields.html

    Kind regards

    -Usman

  • Can I paste the same Code of Google Analytics on the desktop, Tablet and phone pages on my site, or create a new property for each?

    Can I paste the same Code of Google Analytics on the desktop, Tablet and phone pages on my site, or create a new property for each?

    I generated the code and created the property in GA I placed the code in the HTML < head > page properties metadata of my MUSE desktop file.  I am past the same code in the same place for the page of the Tablet and phone or do we get new code?

    I'm assuming that the code is the same for all pages of the Web site as long as they are within the same domain?

    I'm trying to confirm.

    Thank you!

    Yes, you will need this same code applied to all pages you want to track. Simplest is to add to your Master Pages rather than individual pages.

  • I have a downloaded .pdf file. When I click on a page (this happens for each page) he follows me to a link open my browser. How should you remove that? I tried to delete all the hyperlinkes but remained! Thank you.

    I have a downloaded .pdf file. When I click on a page (this happens for each page) he follows me to a link open my browser. How shoul delete who? I tried to delete all the hyperlinkes but remained! Thank you.

    After seeing a few screenshots of the file I think I see what's happening now. There is a watermark diagonal URL through the page that is converted to a link automatically by the application. Disable it go to Edition - Preferences - general and uncheck the box that says "create links from URLS".

  • Performance issue on the page size for CARS

    The cluster we use 8 k page size and a 24 GB RAM under windows 2003.

    We have read on the site of Don Burleson, "for optimum performance, the size of the page on an oracle cluster should be 4 k. Is this right statement, Oracle cluster have better performance with 4 k pages.

    Thank you

    read this on metalink: using large memory on 64-Bit Windows systems ID 422844.1 Pages

    then decide for yourself.

    Published by: Paul R @ NL February 9, 2010 02:49

  • BlackBerry Bold 9000 BlackBerry Smartphones - adding a folder to the home page for each e-mail address

    I have four e-mail addresses on my BlackBerry.  On the desktop, I have a folder in the form of an envelope that says 'Messages' and in which are all messages to all my email addresses are placed.  I have another folder in the form of an envelope with a small globe below showing one of my email addresses, and it includes the messages that came to this address.  Before I had my BlackBerry repaired, I got "mail" general plus four separate files with small globes on them for each of my email addresses.  Please, can someone tell me how to recover these other records yet?

    Go to Setup email. As soon as it opens, press the menu key and select Return Service books.

  • Batch to change the page size of InDesign documents

    I have about 300 documents in InDesign (2014 cc, Mavericks) a page of various page sizes. Each page is wider than 4 inches and 4 inches larger than the content of the page. The content is in middle of the page - actually make a margin of 2 inches (but with no margin guides) around the content. What I need to do, is get the page of all documents will have to be a specific page size, 7,125 "x 9.75".

    I was able to accomplish this by putting all the docs in a book, make a master page 7,125 "x 9.75" on a doc, synchronize the other docs and then opening each doc and apply the master page. The last piece was a bit a lot of work and I would like to avoid it in the future.

    Could write a script that opens some InDesign documents (in or not in a book) and changes the various sizes of page to the necessary size? I've never written scripts before, so no idea if it's possible or how to do it.

    I put the following on another forum and got help, but it took that I have control over the creation of the original documentation. And I did not. "Is there a way to globally apply a master page to all pages of all documents in a book?

    Any help is greatly appreciated.

    Hello

    What is your requirement

    var myFolder = Folder.selectDialog("Select the Folder contains Indesign Files")
    
    var myFiles = myFolder.getFiles("*.indd")
    
    alert("Total Indesign Files: " + myFiles.length)
    
    for(i=0; i
    

    Concerning

    Siraj

Maybe you are looking for

  • Fiddler 2 do not trust

    Yet once again the internal tabs of firefox start page, except troubleshhot go to untrusted message even. When you go to allow the exception and look issuer cert, his www.fiddler2.com and then further on he says root of Fiddlers. There is no sign of

  • where can I find my iPad on the computer backup

    iTunes cannot save a backup on my computer because the existing backup file is injured. How can I find this file injured among all backupfiles from my iphone + ipad?

  • Satellite A300 weird noise for 1-2 seconds

    From time to time, once a week or twice, my laptop makes a strange noise, a short for like 1-2 second as a scratch or programs that kill the virus.I don't know how to explain it exactly the noise but it's strange, Ju. I noticed that it seems that whe

  • OfficeJet Pro 8600 desktop shortcut does not open

    Het all. I just replaced my old HP 4180 with a new Officejet Pro 8600. We have three computer that connects to it, and the shortcut on the desktop to open the software of the printer communication does not work only on your laptop. I used the install

  • can I use the same product key once I formatted my hard drive using a vista upgrade disc?

    can I reuse the same product code already used on one computer on another that I put that hard drive and is no longer using vista on this computer, but want to update another?