Closing a new document with textvariable

1. In Indesign CS4 version 6.0.2 ,
if I create a new document and insert a textvariable, I can save the document and I can close it.
2. In scripting Indesign CS4 version 6.0.2 with VB.net (Visual Studio 2008 + Framework 3.5),if I open a document manually created under Indesign CS4 version 6.0.2 with a textvariable, I can save the document and I can close it.
3. In scripting Indesign CS4 version 6.0.2 with VB.net (Visual Studio 2008 + Framework 3.5),if I create a new document and insert a textvariable, I can save the document, but I can't close it. Indesign give a win32 error.
MyPub = myIndesign.Documents.Add(False)
MySpread = MyPub.Spreads.Item(1)
myTextFrames = MySpread.TextFrames
MyInfos = myTextFrames.Add
Dim FileNameVariable As InDesign.TextVariable = Nothing
For Each Item As TextVariable In MyPub.TextVariables
      If Item.VariableType = idVariableTypes.idFileNameType Then
               FileNameVariable = Item
               Exit For
     End If
Next
Dim FileNameVariableInstance As InDesign.TextVariableInstance = Nothing
FileNameVariableInstance = MyInfos.TextVariableInstances.Add(idLocationOptions.idAtBeginning)
FileNameVariableInstance.AssociatedTextVariable = FileNameVariable
MyPub.Save(FullPath)   'OK
MyPub.close               'Error Win32 in Indesign.exe
I try to save the document before creating the FileNameVariableInstance but it's the same result.
Do you know a way to do it ?
Regards

After searching a lot I have finally found the solution :
MyPub = myIndesign.Documents.Add(False)
MySpread = MyPub.Spreads.Item(1)
myTextFrames = MySpread.TextFrames
MyInfos = myTextFrames.Add
Dim MyVars as Indesign.TextVariables = MyPub.TextVariables
Dim FileNameVariableInstance As InDesign.TextVariableInstance = Nothing
FileNameVariableInstance = MyInfos.TextVariableInstances.Add(idLocationOptions.idAtBeginning)
FileNameVariableInstance.AssociatedTextVariable = MyVars.item(8) ''index of the textvariable equals to idFileNameType
MyPub.Save(FullPath)   'OK
MyPub.close               'OK

Similar Messages

  • How to create a new document with a given theme, instead of choosing it every time.

    Hi,
    for work I only use a custom made keynote theme.
    I've already deleted all the default themes, and the only one that is listed in the app is the one I actually use.
    However every time I create a new document I have to chose its theme (that's normal having plenty of themes, but in my case is just a waste of time).
    I was wondering if there's a way to tell keynote to start a new document with a given theme, in order to avoid to chose it every time.
    Thank you for reading and for the help you will give.
    Giacomo

    Keynote > Preferences > General tab
    select “Use theme,” and then click Choose to select a theme.

  • Create a new document with settings appropriate for SWF or XFL output.

    I'm studying up for the CS4 ACE exam, and I'm stumped on something. In the "Laying out a Document" section, it says: "Create a new document with settings appropriate for SWF or XFL output." There isn't really anything specific to creating a document for flash, except that you wouldn't add bleed. I can't find anything online that addresses this. Am I missing something here? Any document can be exported to SWF or XFL. This seems rather ambiguous. What is there to know about this?

    You're right that any document can be exported to SWF or XFL. I'm not sure what you're going to be asked on the ACE exam, but here are some resources:
    Help topic:
    http://help.adobe.com/en_US/InDesign/6.0/WS2DECDF40-B6DA-40b6-804F-2703D6C6A460.html
    Tim Cole's first of 3-part series:
    http://blogs.adobe.com/indesignchannel/2008/11/indesign_2_flash_part_i_1.html
    My blog entry:
    http://blogs.adobe.com/indesigndocs/2009/03/exporting_interactive_indesign.html

  • JS - Center Selection to Artboard / New Document with certain Artboard size

    TL;DR:
    how do I center my current selection to the artboard?
    just like hitting the "horizontal align-center" and "vertical align-center" buttons.
    Hi,
    I've been searching for the last two hours and before my head hits the keyboard I wanted to ask you for help.
    What I'm struggling with:
    in my init function i create a new document and then copy all layers from the previous document step by step to the new document and then save it as SVG.
    // Init
    (function(){
              destination = Folder.selectDialog('Select folder for SVG files.', docPath);
              if (!destination){return;}
              holderDoc = app.documents.add();
              stepThroughAndExportLayers(docRef.layers);
    my problem is that holderDoc = app.documents.add(); always creates a document that is not the same size as my initial document where the layers get copied from.
    so I want the exact same artboard size as in my initial document.
    I'm fine with either doing it as fixed values or taking directly the values of the inital doc.
    i tried this in the segment where I create the new document:
    // Init
    (function(){
      destination = Folder.selectDialog('Select folder for SVG files.', docPath);
      if (!destination){return;}
      holderDoc = app.documents.add();
      holderDoc.artboards[0].artboardRect = [0,0,128,128];
      stepThroughAndExportLayers(docRef.layers);
    and get this error message:
    "Error 1200: an Illustrator error occured: 1346458189 ('PARM')
    Line: 83
    -> holderDoc.artboards[0].artboardRect = [0,0,128,128];"
    which from what I've read on the web means that illustrator doesnt know what document to pick. but i have called it directly. so what could be the issue?
    to clearify: I do not want to fit the artboard to the images/layer. the artboard should always have a certain size. (for me 128px by 128px)
    I would highly appreciate you helping me with either fixing my approach or propose a completely new one.
    Thanks so much in advance.
    // edit: workaround
    (function(){
              destination = Folder.selectDialog('Select folder for SVG files.', docPath);
              if (!destination){return;}
              var activeArtboard = app.activeDocument.artboards[app.activeDocument.artboards.getActiveArtboardIndex()];
              var ABRect = activeArtboard.artboardRect;
              holderDoc = app.documents.add();
              holderDoc.artboards.add(ABRect);
              holderDoc.artboards.remove(0);
              holderDoc.artboards.setActiveArtboardIndex(0);
              //stepThroughAndExportLayers(docRef.layers);
    i now added a new artboard to the new document with the same size as the artboard on the initial document.
    i remove the predefined artboard on the new doc and set the new artboard as active.
    BUT!
    the artboard is now not centered into the window. which lets illustrator place my image with ctrl+c -> ctrl+v somewhere outside the artboard.
    i now need to align my selection to the center of the artboard. but i cant find any reference on how to center a selection to the artboard.

    yes of course. i never modify the author's comments in original scripts.
    but I wont post the script anywhere when it doesnt work anyway haha.
    this is what I've done now:
    // Init
    (function(){
              destination = Folder.selectDialog('Select folder for SVG files.', docPath);
              if (!destination){return;}
              var activeArtboard = app.activeDocument.artboards[app.activeDocument.artboards.getActiveArtboardIndex()];
              var ABRect = activeArtboard.artboardRect;
              // create new document with same artboard as original
              holderDoc = app.documents.add(DocumentColorSpace.RGB, new UnitValue ((Math.abs(ABRect[0]-ABRect[2])), "px"), new UnitValue ((Math.abs(ABRect[0]-ABRect[2])), "px"));
              stepThroughAndExportLayers(docRef.layers);
    in order to create the new document with the same dimensions as my orignal doc, I first read the artboardRect dimensions of the current artboard and then create the document with those values passed as parameters. the calculation is to get the real width since artboardRect gives you left,top,right,bottom values and not just height and width.
    this only works for square formats though. to make it properly you'd have to change the second "new UnitValue" to use the top and bottom values of artboardRect but I currently dont need to do so.
    * Layers to SVG - layers_export.jsx
    * @version 0.1
    * Improved PageItem selection, which fixed centering
    * @author Anton Ball
    * Exports all layers to SVG Files
    * I didn't want every layer in the SVG file so it first creates a new document
    * and one by one copies each layer to that new document while exporting it out
    * as an SVG.
    * TODO:
    * 1. More of an interface wouldn't hurt. Prefix option and progress bar of some description.
    // Variables
    var docRef = app.activeDocument,
              docPath = docRef.path,
              ignoreHidden = true,
              svgExportOptions = (function(){
                        var options = new ExportOptionsSVG();
                        options.fontSubsetting = SVGFontSubsetting.GLYPHSUSED;
                        options.embedRasterImages = true;
                        options.fontType = SVGFontType.OUTLINEFONT;
                        return options;
              destination, holderDoc;
    // Functions
    var stepThroughAndExportLayers = function(layers){
              var layer,
                        numLayers = layers.length;
              for (var i = 0; i < numLayers; i += 1){
                        layer = layers[i];
                        if (ignoreHidden && !layer.visible){continue;}
                        copyLayerTo(layer, holderDoc);
                        // Resize the artboard to the object
                        selectAll(holderDoc);
                        exportAsSVG(validateLayerName(layer.name, '-'), holderDoc);
                        // Remove everything
                        holderDoc.activeLayer.pageItems.removeAll();
              holderDoc.close(SaveOptions.DONOTSAVECHANGES);
    // Copies the layer to the doc
    copyLayerTo = function(layer, doc){
              var pageItem,
                        numPageItems = layer.pageItems.length;
              for (var i = 0; i < numPageItems; i++){
                        pageItem = layer.pageItems[i];
                        pageItem.duplicate(holderDoc.activeLayer, ElementPlacement.PLACEATEND);
    // Selects all PageItems in the doc
    selectAll = function(doc){
              var pageItems = doc.pageItems,
                        numPageItems = doc.pageItems.length;
              for (var i = 0; i < numPageItems; i += 1){
                        pageItems[i].selected = true;
    // Exports the doc to the destination saving it as name
    exportAsSVG = function(name, doc){
              var file = new File(destination + '/' + name + '.svg');
              holderDoc.exportFile(file, ExportType.SVG, svgExportOptions);
    // Makes sure the name is lowercase and no spaces
    validateLayerName = function(value, separator){
              separator = separator || '_';
              //return value.toLowerCase().replace(/\s/, separator);
              return value.replace(/\s/, separator);
    // Init
    (function(){
              destination = Folder.selectDialog('Select folder for SVG files.', docPath);
              if (!destination){return;}
              var activeArtboard = app.activeDocument.artboards[app.activeDocument.artboards.getActiveArtboardIndex()];
              var ABRect = activeArtboard.artboardRect;
              // create new document with same artboard as original
              holderDoc = app.documents.add(DocumentColorSpace.RGB, new UnitValue ((Math.abs(ABRect[0]-ABRect[2])), "px"), new UnitValue ((Math.abs(ABRect[0]-ABRect[2])), "px"));
              stepThroughAndExportLayers(docRef.layers);

  • Ilustrator freezes creating a new document with web profile.

    Hi,
    I have the illustrator instalation from creative cloud subscription and everytime i create a new document and on the profile combo choose "web", the illustrator freezes forever.
    Im using mac version in a macbook pro 13" corei7 with 8gigs ram.

    I'm having the same issue with i7 2500k, SSD, 16gb ram, 6870 2gb vram 10.7.4.
    Anyone have any idea if i can get a crash report to help you guys out with figuring this?
    Basically whenever i go -> new and change the document profile to web (or a few others) it just LOCKS and needs to be force quitted.
    I've also just ran with the default and it locks up anyway.    

  • Creating a new document with columns and printing effects

    If you create a new document and set columns into it in the new document menu, and then subsequently create images, tables, text etc. in the document that are bigger than one column (that stretch for example across the entire page), will the part of the image that's in the gutter print and/or show up if it's saved as a PDF?
    Help!
    Thanks!

    Guides are only there as a reference for you to help in alignment.They don't restrict what or where objects can be placed or affect their visibility or printability.
    To see what your page will look like in print, switch to Preview Mode (fast way is to press W with nothing selected).

  • Creating a new document with separate images

    Can someone help me create a new document that has two separate images. I can create a new document but don't know how to place two separate photos in the document. For instance create a document that is 8.5 x11 with two images each 8.5 x 5.5.

    there is a number of ways to do this. also reading the manual to get a basic understanding of how Photoshop works will do wonders. Another method of learning is lynda.com
    here is one way.
    1 make a doc that is 8.5 x 11 at whatever resolution you need.
    2 use a guide as a center point.
    3 open the two pics you want to use.
    4 make sure they are the same res as your 8.5 x 11
    5 drag the layers from the open pics to the 8.5 x 11
    6 crop and size the pics in the file so they fit in each half

  • Setting english as the default language for a new document with arabic version of CC apps

    first off, appologies for the screen name, the name i'm sure i had registered before with account was suppose dot be looged in as was barred, so i used this in frustration.  Read the book, The Etymologicon to learn more.
    and another note.  why is the font size in the subject on this form gigantic? intentional of cockup?
    Now, to the point.
    Please please enlighten me, I'm sure it's simple but i can't find the answer and have been haphazardly ploughing the net for half the night.
    I have installed the Arabic langauge version of CC software becuase i need to do a lot of bilingual layouts.
    But
    I generally use, and start with english, but the defualt new document is always set to all the arabic settings, which is a nightmare.
    How do i make english the defualt type (and all the paragraph and language options) while retaining the functionaility of arabic version. 
    I've found instructions for CS2-6 but nothing remotely sensible about CC, and presume i'm missing something really really obvious.

    Hi,
    Here you have some interesting tutos about foreign languages in LV :
    Localizing Your LabVIEW Application to Different Languages
    Localize LabVIEW Applications in Multiple Languages
    Let me know what happens.
    Regards,
    Message Edité par Steve Mohamed le 02-27-2009 09:02 AM
    Steve M.
    National Instruments France
    #adMrkt{text-align: center;font-size:11px; font-weight: bold;} #adMrkt a {text-decoration: none;} #adMrkt a:hover{font-size: 9px;} #adMrkt a span{display: none;} #adMrkt a:hover span{display: block;}
    >> Vidéo-t'chats de l'été : présentations techniques et ingénieurs pour répondre à vos questions

  • New Document with Layer Comp & Groups Link ?

    I'd like to create a script that creates a new photoshop document that automatically creates a set of layer comps with specific names that are linked with groups with identical names or the same name. I don't know whether to create this in Adobe Configurator but since I want to create a 'new' document that does this automatically I don't know if Adobe Configurator is the best route to go ?
    An added bonus it would be benifical to select the layer comp, and save only the selected layer comp or an option to save the entire composition or a layer comp.

    What good are Layer Comps that show Groups if one is to add Layers only
    later on or should Layers in the Groups be created right away?
    In Photoshop when you create a new document File -> New it would create the following layer comps and layer groups.
    The layer comps would be linked to the layer groups with the same name or identical name if allowed, for example if the Layer Group name is not Layer Comp A, rather CompyDesignA the script would know to still link it to Layer Comp A.
    I don't know how many layers I would add to the layer group so the script wouldn't create these layers, the script would then export the layer comp with the selected layer group.
    For example, I select Layer Comp A which is tied to the Layer Group, Layer Group A / or similiar name if I select the layer comp Layer Comp A it would know to save only the Layer Group 'Layer Group A / or similar name' automatically, with the option to save the entire composition with all layer comps and all layer groups, understand ?
    I suppose that upon creating the new composition/document each layer group would have a layer created called 'background' and the first layer created above that background layer would have a screen blend mode applied, automate the task.

  • Copy contents of 2 layers to new document with javascript

    Hi guys !
    Basically i have created a new cutfile generator for a Zund cutting machine we have here at work i have got it to the point where i can create a Registration mark layer and Cut layer now i would like to save this as a layered PDF as this is how the cutter software prefers it. What i would like to know is how with Javascript can I copy the contents of "Regmark" layer and "Cut" layer to a dynamically created new document ? Any thoughts on this will be greatly appreciated thanks so much !
    Regards,
    Bass

    Hi guys,
    Just something i forgot to add, the follow piece of code copies content of "Regmark" layer to new document but its going back and selecting contents of "Cut" layer i am unable to do thanks once again !
    var sourceDoc = app.activeDocument;
    sourceDoc.select(sourceDoc.layers.item("Regmark").pageItems)
    app.copy();
    var destinationDoc = app.documents.add();
    app.pasteInPlace();
    /* NEED SOMETHING HERE TO TAKE ME BACK TO sourceDoc */
    sourceDoc.select(sourceDoc.layers.item("Cut").pageItems)
    app.copy();
    /* ONCE AGAIN SOMETHING TO TAKE ME TO destinationDoc */
    app.pasteInPlace();
    I know im probably going about this all wrong but it's the only thing i can figure out from looking on forum and JS help thanks so much !
    Regards,
    Bass

  • Can I create a new document with a locked PDF file, add new pages, and lock it all again?

    I published a PDF document ten years ago and now want to add Creative Commons licensing language to the copyright page.  But I forgot the password!  I gather from the Forum that there is no way to recover the password.  However, I wonder if I can take the locked PDF file, create a new document (adding a new page for the licensing information), then lock the whole thing up again.  Will this work?  Thanks for your help!                                                                               

    To create an unprotected file you would need the password.

  • Start new document with view at 100%?

    Every time I start Pages a new document is zoomed at 125%. I created a template that I use all the time & set the view zoomed at 100% before I saved it.
    But every time I create new blank document (or new document from my template) it's zoomed at 125%.
    Is it possible to set it so that a new blank document, or a new one from my template starts up at 100%?

    You can set the default zoom for new documents & those opened from templates in Pages > Preferences in Pages 2 & 3. Pages 1/iWork '05 does not have this setting.

  • Creating a new document with different formats, i.e. A5

    Hi there,
    I want to create a nwe document in A5 with about 10 pages, how to do that?
    thanks a lot
    gustavo

    Hello
    I guess that triggering the menu item :
    File > Page Setup…
    may help.
    It's from this one that we may define the paper format.
    Yvan KOENIG (VALLAURIS, France) dimanche 22 mai 2011 12:37:12
    Please :
    Search for questions similar to your own before submitting them to the community
    To be the AW6 successor, iWork MUST integrate a TRUE DB, not a list organizer !

  • Document Search - how to add new document with link to ALL

    CRM 5.0,  can easily add documents in the ICWC under the Document Search or gui t-code CRM_KW but the linkage is to me.   How can I change or create the link to to "ALL" so all users can find them in the search.

    Hi Glenn,
    Just to clarify for other readers, I assume you are referring to the document search functionality in the Interaction Center that uses Content Management to search for documents and link them to the current business transaction, the current account (business partner) or the current agent/user?
    I am not aware of any out of the box method for linking a document to all CRM users or agents. But if you want to have a look around at the code, I think the class and methods you might want to start with class CL_CRM_IC_CUCOCM_IMPL method REGISTER_*.
    Maybe someone else has an idea how to link multiple users/agents (e.g. all users belonging to a particular org unit or profile) at once, instead of only linking the current user/agent?
    Warm regards,
    John

  • Start a new Document with Millimeters

    Hi there,
    I am new to Illustratror Scripting.
    I changed a Script from William Ngan, http://www.metaphorical.net and http://forums.adobe.com/message/3813716?tstart=1
    It saves EPS-files instead of AI-Files. But the Units are still in PT. I want them to be in Millimeters and the artboard isn't focused on the viewport.
    I suppose it's RulerUnits.Millimeters but somehow it doesn't work and when I pick a line it shows pt. I don't know how to write it. Perhaps you find the solution.
    I deleted the Comments of William so it's not as long as the original. I tried at the line:
    var newdoc = app.documents.add ( doc.documentColorSpace, doc.width, doc.height );
    I thought this would help:
    newdoc.RulerUnits = doc.RulerUnits;
    But it doesn't work. Hope it shows the idea.
    /* Here the Script starts */
    var doc = app.activeDocument;
    var docname = (doc.name.split('.'))[0]; // name
    var doc_artboard = doc.artboards[0].artboardRect;
    if (app.documents.length > 1) {
            alert( "Nur ein Dokument darf geöffnet sein. Schließen Sie andere Dokumente und führen Sie das Script erneut aus.");
    } else {
        var ok = confirm( "Bitte speichern Sie zuerst Ihr Original.\nDie Ebenen werden im gleichen Ordner wie Ihre Datei gespeichert.\nWeiter?" );
        if (ok) {
            // prepare layers
            for(var i=0; i<doc.layers.length; i++) {
                doc.layers[i].visible = false;
            // go through each layers
            for(var i=0; i<doc.layers.length; i++) {
                app.activeDocument = doc;
                if (i>0) doc.layers[i-1].visible = false;
                doc.layers[i].visible = true;
                doc.activeLayer = doc.layers[i];
                saveAI( doc.path, doc.activeLayer.name, i );
            // close original file without saving
            doc.close( SaveOptions.DONOTSAVECHANGES );
    function saveAI( path, name, id ) {
        var currlayer = doc.layers[id];   
        var g = currlayer.groupItems.add();
        group( g, currlayer.pageItems );   
        var t = g.top;
        var l = g.left;
        var myPreset = app.getPresetSettings("Druck");
        app.documents.addDocument("Druck", myPreset );
        var newdoc = app.documents.add ( doc.documentColorSpace, doc.width, doc.height );
        newdoc.artboards[0].artboardRect = doc_artboard;
        /* app.preferences.rulerUnits = Units.Millimeters; */
        /* app.activeDocument.rulerUnits = RulerUnits.Millimeters; */
        /* newdoc.Units = RulerUnits.Millimeters; */ 
        var newlayer = newdoc.layers[0];
        g.duplicate( newlayer, ElementPlacement.PLACEATBEGINNING );
        newlayer.pageItems[0].top = t;
        newlayer.pageItems[0].left = l;
        path.changePath( name+".eps" );
        var saveOpts = new EPSSaveOptions();
        /* saveOpts.compatibility = ILLUSTRATOR16; */
        saveOpts.embedLinkedFiles = true;
        saveOpts.includeDocumentThumbnails = true;
        saveOpts.embedAllFonts = true;
        saveOpts.saveMultipleArtboards = false;
        saveOpts.cmykPostScript = true;
        saveOpts.preview = EPSPreview.TRANSPARENTCOLORTIFF;
        newdoc.saveAs( path, saveOpts );
        newdoc.close( SaveOptions.DONOTSAVECHANGES );
        // wait for the new file to save and close before continue.
        // A callback function (if possible) will be better than a while loop for sure.
        while (app.documents.length > 1) {
            continue;
    function group( gg, items ) {
        var newItem;
        for(var i=items.length-1; i>=0; i--) {
            if (items[i]!=gg) {
                newItem = items[i].move (gg, ElementPlacement.PLACEATBEGINNING);
        return newItem;

    Muppet Mark and pixxxel schubser were totally right! I thank both of you!
    Now it's time for me to share the working version. The Preset "Druck" is for the german version. It's "Print" for the international.
    The Script saves layers as individual EPS-Files. The RulerUnits are Millimeters not Point. The viewport is still not focused on the Artboard when opening the document but that's ...
    var doc = app.activeDocument;
    var docname = (doc.name.split('.'))[0]; // name
    var doc_artboard = doc.artboards[0].artboardRect;
    if (app.documents.length > 1) {
            alert( "Nur ein Dokument darf geöffnet sein. Schließen Sie andere Dokumente und führen Sie das Script erneut aus.");
    } else {
        var ok = confirm( "Bitte speichern Sie zuerst Ihr Original.\nDie Ebenen werden im gleichen Ordner wie Ihre Datei gespeichert.\nWeiter?" );
        if (ok) {
            // prepare layers
            for(var i=0; i<doc.layers.length; i++) {
                doc.layers[i].visible = false;
            // go through each layers
            for(var i=0; i<doc.layers.length; i++) {
                app.activeDocument = doc;
                if (i>0) doc.layers[i-1].visible = false;
                doc.layers[i].visible = true;
                doc.activeLayer = doc.layers[i];
                saveEPS( doc.path, doc.activeLayer.name, i );
            // close original file without saving
            doc.close( SaveOptions.DONOTSAVECHANGES );
    function saveEPS( path, name, id ) {
        var currlayer = doc.layers[id];   
        var g = currlayer.groupItems.add();
        group( g, currlayer.pageItems );   
        var t = g.top;
        var l = g.left;
        var w = doc.width;
        var h = doc.height;
        var w = 31.1*2.834645;
        var h = 28.15*2.834645;
        var myPreset = new DocumentPreset;
        myPreset.width = w;
        myPreset.height = h;
        myPreset.units = RulerUnits.Millimeters;
        myPreset.title = docname;
        var newdoc = documents.addDocument( "Druck", myPreset);
        newdoc.artboards[0].artboardRect = doc_artboard;
        var newlayer = newdoc.layers[0];
        g.duplicate( newlayer, ElementPlacement.PLACEATBEGINNING );
        newlayer.pageItems[0].top = t;
        newlayer.pageItems[0].left = l;
        path.changePath( name+".eps" );
        var saveOpts = new EPSSaveOptions();
        saveOpts.compatibility = Compatibility.ILLUSTRATOR16;
        saveOpts.embedLinkedFiles = true;
        saveOpts.includeDocumentThumbnails = true;
        saveOpts.embedAllFonts = true;
        saveOpts.saveMultipleArtboards = false;
        saveOpts.cmykPostScript = true;
        saveOpts.preview = EPSPreview.TRANSPARENTCOLORTIFF;   
        newdoc.saveAs( path, saveOpts );
        newdoc.close( SaveOptions.DONOTSAVECHANGES );   
        // wait for the new file to save and close before continue.
        // A callback function (if possible) will be better than a while loop for sure.
        while (app.documents.length > 1) {
            continue;
    function group( gg, items ) {
        var newItem;
        for(var i=items.length-1; i>=0; i--) {
            if (items[i]!=gg) {
                newItem = items[i].move (gg, ElementPlacement.PLACEATBEGINNING);
        return newItem;

Maybe you are looking for

  • How can I create a "Next" button with Insert database action

    Hello,      I want to create a "Next" button that will redirect to another page and at the same time to do an INSERT database action. I've searched on google but I didn't find nothing specific that could help me. Below are some screenshots: http://im

  • IPod touch 1G broken after update from 1.1.5 to 3.1.1

    Hi! I hope this is not a doubled entry. I found only similar issues but no solution. I´ve bought the new OS 3.1.1. (on 1st October) and then updated my iPod touch from 1.1.5 to 3.1.1 with iTunes 9.0.1. Since then my iPod does only react on one (somet

  • PowerMac G4 (AGP) suddenly won't boot from its internal HDs

    Hi, here's a description of a weird and sudden issue on my mac. Hope one of you out there has a cure. The system: Powermac G4 (AGP) 450MHz, 512MB RAM, upgraded a couple of years ago with an 133 ATA controller card (Acard 6280M). The card controls my

  • Cannot InterVlan on Cisco Nexus 5500

    Dear All, I have problem with my nexus 5500, Intervlan on my nexus not work, i dont know why.. Before i have only this kind of license: Feature                      Ins  Lic   Status Expiry Date Comments                                  Count FCOE_NP

  • RW Cronacle : Add new instance

    Hi, I created an instance with RSI_MAINTAIN_INSTANCES, but as we didn't use it, I deleted it. But now that we have to use it, I try to add it again via RSI_MAINTAIN_INSTANCES, but it doesn't work, I get the follonwing message : Unable to add XI4 ORA-