Change Page size with a Script

I have made artwork in Illustrator that is set up as two page spreads on 1 artboard.
I need to convert this to single page spreads.
I.e. So for half the documents, I need to set the anchor point of the document to top left and half the width of the artboard.
For the other half of the documents, I need to set anchor point to to right and half the width.
Is this possible with scripting?
I have look around online to find ways of accessing the document size and anchor point via scripting, but cannot seem to find any resources.
Thanks for any help that can be offered.
Edit: Also is it possible to create a new artboard with a script and assign it a name?

here you go, this script splits the artboard in two
// carlos canto
// http://forums.adobe.com/message/5380624#5380624
var idoc = app.activeDocument;
var ab = idoc.artboards[0];
var abBounds = ab.artboardRect;// left, top, right, bottom
var ableft = abBounds[0]; // 0
var abtop = abBounds[1]; // 612
var abright = abBounds[2];
var abbottom = abBounds[3];
var abwidth = abright - ableft; // 792 // width
var abheight = abtop- abbottom; // 0 // height
var half = ableft + abwidth/2;
var abright2 = half;
ab.artboardRect = [ableft, abtop, abright2, abbottom];
var ableft2 = half;
var newAB = idoc.artboards.add([ableft2, abtop, abright, abbottom]);

Similar Messages

  • Cannot change page size with acrobat

    I am able to convert my manuscript in Mac word(2011) to adobe acrobat (XI); unfortunately the 6 X 9 " page size does not convert. I spent a few hours on the phone with adobe support and the final resolution was to upload the file to them and they converted it for me. however, they used distiller which reduced the file size and appears to have affected the many images. Does anyone have any advice? The best I have been able to glean online is work with inDesign to change page size.

    Thanks.
    The problem was with the paper size. In addition to change the page size I needed to change the paper size in the print option before selecting save Adobe PDF.
    From Word go to File> Print
    Open the Copies & Pages dropdown
    Select Paper Handling
    Check the Scale to fit paper size box
    Open the Destination Paper Size list
    Select your custom 6x9 Preset
    Click the PDF button
    Select either Save as PDF or Save as Adobe PDF
    The unfortunate thing is that I was able to do this initially, but when I went back to replicate it adobe is creating 2 files one with my cover page and the rest to the manuscript. Luckily my initial copy was good. Thanks again for your help.

  • Change page size in Acrobat Pro 6.0

    Hello, I'm wondering if there's a way to change page sizes in Acrobat Pro 6.0 for Windows. We are receiving manuscripts which have been assembled from various documents. They're going to be printed at 8.5 x 11, but sometimes some of the pages are 7 x 10. Is there an automated way to change all the 7 x 10 pages to 8.5 x 11? We don't want to have to do each page individually because there are too many of them.
    Many thanks,
    Coral

    You could try printing to a new PDF with the PDF printer, setting the page size to 8.5 x 11 and setting the page scaling option to 'Fit to Printable Area'.  This will hopefully leave the existing 8.5 x 11 ones about the same size (it may shrink them slightly) and scale the other sizes.

  • Introduce left/top margin: Change Page Size ignored

    I have a vector drawing of a technical schematic in PDF.  The drawing is an extract of a much larger schematic, so it is very small: 2.2" by 1.648".  However, when I print it out, it is resized to fill up a Letter size paper (8.5" by 11") and the size is then perfect for viewing.  Also, the PDF has no white space around the edges, so the same PDF is perfect for importing into documentation packages.
    However, for hard copy printing, depending on the exact aspect ratio of the drawing, I will sometimes want to introduce white space along one edge for hole-punching purposes.  I am opening the PDF and printing it from Acrobat 8 Professional.  I cannot use Document->Cropping because I am trying to introduce a margin rather reduce an existing margin.  I tried using the Change Page Size controls in the cropping dialog panel.  Originally, it was set to Fixed Sizes and Page Sizes was set to None.  I selected Custom instead of Fixed Sizes, then I entered in the Width and Height in inches, with the Height being about 0.5" more than the original 1.648" (it's landscape, so the holes will be at the top).  However, the illustrative diagram does not change, and neither do the dimensions shown on it.  I click OK and the PDF as viewed did not change -- no white space.  When I go back into the Change Paper Size dialog, all the size data that I entered is gone and the control have reverted back to Fixed Size with a Page Size of None.  I explored the dropdown list for Page Sizes, and none of them are appropriate for such a small diagram.
    What I'm trying to achieve is a pretty simple effect, and I thought it would be straightforward.  It has to be *very* simple as I expect to do this regularly.  Is there actually a way?  Ideally, it doesn't involve calculating all sorts of bounding boxes and offsets.  Who knows what the assumed reference points for those are.  In fact, the most direct way would be to enter a negative Margin Controls in the Crop Margins region of the dialog.  That is not possible, of course.

    Actually, I found a way.  The reason why the page size was being ignored is because the numbers were too small.  If I enter a big enough number, it sticks.  It would be nice to get a message to that effect though.......sigh.
    I can then adjust the cropping margins to get the gutter.
    Thanks.

  • XI Pro: How to change page size?

    I have a letter-sized document where each page has extremely large margins and text in a tiny font size. Can I use the 'Remove White Margins' function (Crop pages > Set Page Boxes) to remove the large margins and then resize what remains back to 8.5" x11" using the 'Change Page Size' function?
    When I try this, I can do the first step and I'm left with pages about 5.5"x8". But the Change Page Size function does not allow me to resize the page.
    It this possible?

    Hi J Kart,
    Please refer the doc: https://acrobatusers.com/tutorials/how-to-resize-pages-in-a-pdf-file
    Regards,
    Rave

  • How We Can Change Page Size During Report Run Time

    Hello !
    How We Can Change Page Size During Report Run Time .
    How can we stop to change the column name when we amend a sql in report data model.
    Thanks !
    null

    hello sohail
    1. question - i'm afraid this cannot be done ... bit in report 6 and newer you have posibility to divide your report in 3 parts (former header, body, trailor) and each part can have diferent page siz, orientation , ...
    2. question - best is give each column in your statements in one report diferent alias. when you have to chnge something, alias will remain same ...
    try this: select 1 as fist_column, 1 as second_column from dual
    hope this helsp

  • Maintain custom page size with bleed

    I use CS4 and when working in Illustrator ( and later taking into a book in InDesign) how do I maintain custom page size with bleed in Illustrator when saving as PDF .
    I have been told my files are not print ready and have no bleed even though I set a bleed and accurate (custom)page size initially. It seems I lose these when I save as a PDF for Printers to use.

    Sometimes and I will check the way I do that, though usually I move from
    from AI ,  save as print quality PDF and still seem to lose the bleed. Is
    there a setting I should be using for the PDF?

  • How to change flash size with ac3?

    I want to change flash size with xml. Sample config.xml
    <genGenis>300</genGenis>
    <genYuksek>100</genYuksek>
    My flash read xml and change size to 300 * 100
    After working in a flash I want to change the default values. Is this possible?

    Have you worked with XML before? You're going to need to load that XML file and wait for it to complete. After you do that, are you using layout logic based on these values to create your content? Meaning do you have code in place to realize you have (as you said) 500x200 space so your code is able to use the space available effectively? Or do you just expect the content of the SWF to scale automagically?
    As for the loader, you can use a simple URLLoader to load the external XML file. Here's a quick Adobe code snippit and explaination on how to load it:
    http://help.adobe.com/en_US/as3/dev/WS5b3ccc516d4fbf351e63e3d118a9b90204-7e6a.html
    Once you have the XML in an XML object you can just access the value via the XML variable name you make (e.g. myXML) with the name of the node while getting its text value. In your case you'll need to convert it to a Number because you may want the flexibility of using fractions (e.g. 1.5, 500.25, etc). So you'd need to case the value to a number. So to get the width it'd be like: var myWidth:Number = Number(myXML.genGenis.text()); and same for height just changing the variable and node name as needed.
    Now that you have your values you can write layout code to use the numbers and handle the content creation yourself.
    If you don't do that, as Andrei1 mentioned you'll need to affect the object embedded directly using ExternalInterface (Flash AS3 talking to the webpages JavaScript) requesting the object be resized to the new size.
    You'll want to make sure your stage.scaleMode = StageScaleMode.EXACT_FIT; or stage.scaleMode = StageScaleMode.NO_BORDER; so your SWF content is "stretched" to the size you request. Exact fit will allow the content to distort if necessary to fill the width and height. No border will scale the content to the size specified but will maintain the aspect ratio. It's up to you whichever you want.
    If you have any specific questions on any of this just ask.

  • Possible to enlarge white space by changing page size?

    Greetings.  I'm using Acrobat 10 pro now, but in 9  it was possible to enlarge the white space around the text by changing the page size as part of the crop command.  This was very handy for creating an area large enough for text box comments.  I can't find this capability in 10.  Am I, hopefully, mistaken?

    Select: Tools > Pages > Crop
    and then double-click on the page. You'll then get the Crop dialog and you can select a larger page size in the CHange Page Size area.

  • Changing page size from legal to letter with same size font when printed

    I have the problem that I get a pdf which is in legal size format.  I need to print this in letter size, sign it and re-scan it and send via email to a person who then needs to print it and sign it and scan it.  What is happening is the person who I have to send this too can only scan letter size paper.  I can make the legal size form print, (shink to fit printable area), as letter size but the font becomes so small that it is unreadable.  What I need to do is resize the legal to letter but keep the same size font.  I expect this to make the document 2 pages but that is fine.  I can not find how to do this.  I have Adobe 9.
    [email protected]

    Does the original legal size document content occupy more space than would fit on 8.5x11? If not, then you can simply set the page size in print driver properties to letter, and in the Page Handling area of the Print dialog box tell it:
    Page Scaling: None
    check: Auto-Rotate and Center
    do not check: Choose paper source by PDF page size - this will force it to print on the paper selected in the print driver properties.
    If the actual content is too large to print on the forced paper, then you need to (in the Page Handling area of the print dialog) tell it:
    Page Scaling: Tile large pages
    This will allow the remaining content to print on a second page

  • Change Page Size of a Form

    I created a form in Adobe Acrobat Pro from a spreadsheet that I had printed to PDF. However, the PDF was in a landspace orientation rather than a portrait orientation. Does anyone know how I can change the page size and orientation of the form. I tried opening it importing it into LifeCycle Designer, but it messes up my java script calculations. If I print it to another PDF it no longer remains a fillable form.

    You really need to go back to your spreadsheet program and properly orient it there. Consider a PDF only a piece of paper that you created. You might be able to create the new PDF and then use replaces pages in the old PDF to keep the form fields. This last step is the typical process to keep the form fields. You will probably still have to move the fields. I am just not sure if the orientation and such will be kept with the replace pages, but that is where I would start. You could also copy the fields from one PDF to the other.

  • Batch change page size of InDesign documents

    I have about 300 one-page InDesign (cc 2014, Mavericks) documents of varying page sizes. Each page is 4 inches wider and 4 inches taller that the content of the page. The content is in the middle of the page—effectively making a 2-inch margin (but with no margin guides) around the content. What I need to do is get the page of all documents to be one specific page size, 7.125” x 9.75”.
    I was able to accomplish this by putting all the docs in a book, making a master page 7.125” x 9.75” on one doc, synching the other docs, and then opening each doc and applying the master page. The last bit was a little labor intensive and I would like to avoid it going forward.
    Could a script be written that opens selected InDesign docs (in or not in a book) and changes the various page sizes to the one size needed? I’ve never written scripts before so have no idea if it is possible or how to do it.
    I put the following on another forum and got help but it required that I have control over the creation of the original docs. And I don’t. “Is there a way to globally apply a master page to all pages of all docs in a book?”
    Any help is greatly appreciated.

    Hi,
    Is this 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<myFiles.length; i++)
        app.open(myFiles[i])
        app.scriptPreferences.userInteractionLevel = UserInteractionLevels.NEVER_INTERACT;
        var myDoc = app.activeDocument;
        myDoc.viewPreferences.horizontalMeasurementUnits = MeasurementUnits.inches;
        myDoc.viewPreferences.verticalMeasurementUnits = MeasurementUnits.inches;
        with(myDoc.documentPreferences){
        pageHeight = "7.125";
        pageWidth = "9.75";
    app.activeDocument.save();
    app.activeDocument.close();
    Regards
    Siraj

  • Book Module - how to change page size?

    I'd like to design book pages for my existing hard covers - A4 landscape and portrait. Also for specific 12x12 cover which takes 11.69" x 12" paper.
    Have watched various YouTubes, search within support - but haven't found a reference to add preferred sizes. Yet.
    Can anyone help on this one please?

    Yep, that's how I am doing it. I just wanted to make sure that I was doing it correctly. I need to keep debugging then and figure out what the real problem is. I am new to all of this (obviously) and I just needed to make sure I had the idea correct. I didn't mean to use document and page interchangeably, I understand that you can't have different size pages in the same document.
    Thank you for your help.
    [FYI]I created a class that creates a document with most of the document settings that I use (e.g. a standard number of pages, non-facing pages, units in inches, etc.) but I don't specify a page size, that's something that varies between documents, so I figured I could just apply that after I have created the page. The problem is, when I try to create multiple documents it doesn't work. The script will create the first document using the default page size settings and I can't get it to change the page size, but then the next document will be created using the page size I tried to apply from the previous document that the script created. I am sure this is totally a coding error somewhere else. I will try to track it down. Just when I think I have this stuff figured out . . .

  • HOW TO: Change page size after page is created?

    Is there a way to change the size of a page after the page has been created? In the documentation, the only way I have seen to set the page size is in a "with" statement right after creating the document. I have need to change the size of the document after a document has already been created. Any ideas?

    Yep, that's how I am doing it. I just wanted to make sure that I was doing it correctly. I need to keep debugging then and figure out what the real problem is. I am new to all of this (obviously) and I just needed to make sure I had the idea correct. I didn't mean to use document and page interchangeably, I understand that you can't have different size pages in the same document.
    Thank you for your help.
    [FYI]I created a class that creates a document with most of the document settings that I use (e.g. a standard number of pages, non-facing pages, units in inches, etc.) but I don't specify a page size, that's something that varies between documents, so I figured I could just apply that after I have created the page. The problem is, when I try to create multiple documents it doesn't work. The script will create the first document using the default page size settings and I can't get it to change the page size, but then the next document will be created using the page size I tried to apply from the previous document that the script created. I am sure this is totally a coding error somewhere else. I will try to track it down. Just when I think I have this stuff figured out . . .

  • Change page size

    I need to change the page size of a document. Usually a drawing scanned with format Iso A1 (840x594) to format iso A3 (420x297).
    Is it possible to do this by using Acrobat 7.0 Professional?
    Preferably redused exactly 50%.

    As I understand it, you want to scale the graphic to a different size, not just change the page size. Those are two different aspects of the problem. If a graphic is part of the page, it can be moved, but can not be resized. To get a scalable graphic in the PDF, you have to put it on a button (TOOLS>FORMS>BUTTON) as an image. The button can be scaled. Once you make an object a part of the PDF itself (a form button is not part of the basic document), you can no longer scale it. This is why we all talk about doing editing in your original document and not in the PDF.
    When you say to print to PDF with reduced size settings, I have no idea what you have done. Is this a job.settings file selection or what? I am still not sure what your objective is. It looks like you want to put multiple graphics into one file. I would suggest using a word processor, inserting the graphics to the size you want, then print all of the graphics to a PDF from that application. You selections would then be the choice of job.settings that you use in terms of the resolution that the graphics may be produced in. I think that this is the workflow that you really want, not trying to do things directly in Acrobat.

Maybe you are looking for

  • HT204053 My old email address is used for my iCloud and I can't change it to my new apple ID

    I can't change my iCloud ID to my new apple ID. My iCloud ID is my old email address which is no longer in use.

  • Why is the answer of the program such??

    I have a program code below. class Flag private boolean flag; public Flag() { boolean flag = true; public boolean getFlag() { return flag; public static void main(String[] args) { Flag f = new Flag(); System.out.println(f.getFlag()); When i run the p

  • Transfering Photos from iPod

    Does anyone know if it's possible to transfer photos from an iPod into iPhoto '08? I just got my new 17" MBP and was a little distraught at losing all of my photos. Excitement hit once I realized I still had them on my iPod but in playing around with

  • Mail: spinning ball lock-up?

    I just upgraded to Tiger. Now when I attempt to open mail on my G4 Titanium laptop, I get the forever spinning ball requiring force quit. Other apps seem to work fine, but a reinstall still failed to fix the mail program. Any ideas?

  • Synaptic driver doesn't catch my Dell Precision M6600 TouchPad?

    For whatever reason, the synaptic driver doesn't catch my touchpad. I've got: /etc/X11/xorg.conf.d/50-synaptics.conf Section "InputClass" Identifier "touchpad" Driver "synaptics" MatchIsTouchpad "on" Option "TapButton1" "1" Option "TapButton2" "2" Op