AS/CS3 open document without showing window

Hi everyone,
I'm pretty new to scripting and mostly I've used Applescript to script InDesign.
In InDesign you can open a file without showing the window, which often speeds up the script.
I cannot figure out how to tell Photoshop to open a file without showing the window.
Is this possible?
thanks!

With CS4 you can also toggle the panels and set image zoom to .25% to speed up the script.
togglePalettes();
setZoom( .25 );
function setZoom( zoom ) {// as percent
   cTID = function(s) { return app.charIDToTypeID(s); }; // from xbytor
   var docRes = activeDocument.resolution;
   activeDocument.resizeImage( undefined, undefined, 72/(zoom/100), ResampleMethod.NONE );
   var desc = new ActionDescriptor();
   var ref = new ActionReference();
   ref.putEnumerated( cTID( "Mn  " ), cTID( "MnIt" ), cTID( 'PrnS' ) );
   desc.putReference( cTID( "null" ), ref );
   executeAction( cTID( "slct" ), desc, DialogModes.NO );
   activeDocument.resizeImage( undefined, undefined, docRes, ResampleMethod.NONE );
// your code here
togglePalettes();
If you where using javascipt you could also place all you code in a string and suspendHistory to speed it up a little more.

Similar Messages

  • [JS] Open document without showing window

    Hi there, wise scripters,
    Win7 64-bit, CS6, ID8.0.2
    I need to open indd doc, process some code, close file. Everything works fine.
    However, the 'open' method has a parameter [showingWindow], right?
    To speed things up a bit, I try to turn off displaying document's window by using the 'false' argument while opening the file, like this:
    var file = File.openDialog(); 
    app.open(file, false);
    ... and can't get it to work. File just won't open then.
    Found a few posts where people say it's working just fine for them.
    What I am missing / doing wrong?
    Thank You!
    P.S. Funny thing is, a couple of years ago, playing with 'save', 'save as', and 'save a copy' options, I had achieved this effect unintentionally, in some quite different way I can't recall now...

    Hi,
    Well, I see now, my problem is a bit different...
    This is initial basic working code sample:
    var file = File.openDialog();
    app.open(file);
    app.pdfExportPreferences.pageRange = PageRange.ALL_PAGES;
    app.pdfExportPreferences.viewPDF = false;
    app.activeDocument.exportFile(ExportFormat.pdfType, File("C:/Folder/Test.pdf"), false, "myPDFpreset");
    app.activeDocument.close(SaveOptions.NO);
    alert("Done");
    Now I realized I can't simply add 'false' argument to app.open(file, false) - script throws an error 'No documents are open'.
    And this works as expected (not showing window):
    var file = File.openDialog();
    var myDoc = app.open(file, false);
    app.pdfExportPreferences.pageRange = PageRange.ALL_PAGES;
    app.pdfExportPreferences.viewPDF = false;
    myDoc.exportFile(ExportFormat.pdfType, File("C:/Folder/Test.pdf"), false, "myPDFpreset");
    myDoc.close(SaveOptions.NO);
    alert("Done");
    So I would need to modify the main code - that's too bad... I was hoping to use this in a much more complex script, with a lot of lines, doing a big bunch of things...
    However, thank You for your response and have a nice party tonight

  • AS CS3 open without showing window

    Hi
    I am transferring perfectly working script from Tiger-CS2 to Leopard-CS3 environment - and stumble practically on each line
    For example this:
    set myDoc to open theDocument without showing window
    Worked for CS2. Now it doesn't compile, highlights "window" and says "Expexted end of line, etc. but found class name"
    Where could I find what's different between scripting CS2 and CS3?
    Would greatly appreciate any help!
    Vera

    Now I know that it's not CS3 problem - it's Leopard or Script Editor. Took my script on Tiger machine - compiled fine.
    BTW, Sample Script from Adobe doesn't compile on my Leopard machine.
    One down more to go...
    Vera

  • InDes CS3 - open without showing window

    Hi
    I am transferring perfectly working script from Tiger-CS2 to Leopard-CS3 environment - and stumble practically on each line
    For example this:
    set myDoc to open theDocument without showing window
    Worked for CS2. Now it doesn't compile, highlights "window" and says "Expexted end of line, etc. but found class name"
    Where could I find what's different between scripting CS2 and CS3?
    Would greatly appreciate any help!
    Vera

    Now I know that it's not CS3 problem - it's Leopard or Script Editor. Took my script on Tiger machine - compiled fine.
    BTW, Sample Script from Adobe doesn't compile on my Leopard machine.
    One down more to go...
    Vera

  • Using Firefox, I used to be able to open a document on a website and look at it without downloading.  Now, I must download a document in order to view it.  How can I change settings so that I can open documents without saving them?

    Using Firefox, I used to be able to open a document on a website, such as a bank statement, and view it without downloading.  Now, I must download and save a document before I can view it.  How can I change settings so that I can open documents without saving them first?

    Do you know what kind of docs they are? Did you upgrade/Update Firefox lately?
    https://addons.mozilla.org/en-US/firefox/addon/pdf-download/
    http://kb2.adobe.com/cps/333/333563.html
    https://addons.mozilla.org/en-US/firefox/addon/open-it-online/

  • "Open documents in same window" option--gone in v.9 Pro?

    I always preferred to have all my documents open in Acrobat 8 Pro. Now my new upgrade to Acrobat 9 Pro, they all open in their own window. Oddly, the setting to stop this from happening and force a single-window opening does not seem to exist any more.
    Am I missing something? is there a fix somewhere?

    This is the worst thing to happen to acrobat, in my opinion.
    The clutter that it creates on my computer and the fact that i cant even see the document title when I have a bunch of them open (because the task bar is too full) is unacceptable.
    I never would have changed from Acrobat 8 if I had known, and now I cant switch back (company license).
    The latest thing i can find about addressing it is here:
    http://kb.adobe.com/selfservice/viewContent.do?externalId=kb405108&sliceId=1
    which was in november 2008....
    why hasnt any thing else been done about it?  I just spent 45 minutes being sent to different departments over the phone, only to be told to submit a feature request.
    Please do this if you havent already:
    http://www.adobe.com/cfusion/mmform/index.cfm?name=wishform

  • Problem Opening document in New Window

    Hai all,
    in my JSP page i have a link. the link path i am getting from database which is actually a word document present in a local drive. to open the file in a new window i have written the code like this
    <a href="<%=docPath %>" target="_blank">Open New</a> Now problem is in IE file is opening in a new window but in Mozilla FireFox it is not opening.
    Thanks in Advance

    Here are some thoughts on this kind of thing: http://www.trilithium.com/johan/2005/03/target-blank/

  • Opening document in new window

    I've added a button to the online help toolbar in the Skin
    Editor and created a link to the manual in the Action Tab. I
    compiled the help and when I select the button, the document comes
    up in the topic pane window in the online help. I want the document
    to open in a new window with the appropriate application (Word for
    .doc, Adobe Reader for .PDF, etc.). I think this requires some
    javascript but not sure. How would I go about doing this?
    Thanks in advance for your time.
    Bill

    Hi Bill
    I believe that how these documents open are dependent upon
    the settings for each PC viewing the page. For .PDF content, each
    user has the ability to configure the settings for their PDF reader
    to choose between whether PDF files open in the browser or in the
    PDF reader. Additionally, browser add ins may have a role too. For
    example, I use FireFox as my primary browser. I have an add in for
    FireFox that allows me to choose what happens when I click a link
    that opens a PDF. The add in prompts me for my desired action.
    I believe Word is similar, but I'm not sure where you would
    go to change the behavior of how it opens. But I do believe there
    is a setting on each Windows install that governs how Word
    documents are handled when opened from a link on a web page.
    Actually, I just conducted a Google search and here is a link
    or two that you may find interesting.
    Link regarding Word
    Documents
    Link regarding
    PDF Documents
    Hopefully this helps... Rick

  • Opening documents with Show All

    In the Open dialog selecting Show all - will inconsistently open some doc's but not others. If I specify the format ( example= RTF or Word Mac 98 ) most times it will open it. All these documents work fine with every other application. What gives?
    Is there a way to make the default in the Open screen " Show All " and have it work as it should?
    Thx

    Hello
    Is there a way to make the default in the Open screen " Show All "
    Response : NO
    and have it work as it should?
    I don't know what to write. On my machine it works as it is made for
    Yvan KOENIG (from FRANCE dimanche 15 janvier 2006 18:01:49)

  • Open Documents in new window fails

    Hello,
    I have created successfully an action where I want to open a new window to show/download a document. After triggering the action the window opens and closes immediately afterwards without asking to download the document. The curious thing is, when I am deploying the Web Dynpro application from Developer Studio and run it directly in internet explorer it works. But when I am creating an iView I will get the above mentioned behaviour. Is this a bug? Can you help me out?
    Best regards,
    Denis

    Hi,
    You have to set the "useWindow" property on the button to "true", and the action must start with "dialog:", like "dialog:action". And, in adfc-config.xml you have to have navigation defined also with "dialog:action".
    <af:commandButton text="Button"
             action="dialog:action"
             useWindow="true">
    {code}
    Pedja                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • Illustrator substitutes fonts when opening document without warning.

    Have an annoying issue hopefully somebody can shed light on. When we activate fonts using font management software, work on a file, close the file and then deactivate those fonts, if we open the file again without turning the fonts back on, the file will load without giving a missing font warning and substitute the fonts to myriad. In a few test, the fonts were still open, and no substitution occured, BUT, random blocks of type were inexplicably empty. When the file gets reopened with fonts reactivated or if Ilustrator is restarted, everything behaves normally.
    This was tested on os 10.5.8 on multiple machines using Illust CS4, Suitcase, Universal Type Server and Font Explorer X. Test were made both before and after using Font Nuke to clean font caches to the same effect.
    Anybody have any idea how to prevent this behavior? I don't want Illustrator to substitute fonts without warning me that fonts are missing....ever. If it must, can I have it substitute to wingdings or chinese characters or something that will be a bit more obvious than myriad?

    Yeah, this is very big and money cost problem, happened to me a few times and couldnt find and answer. To try to prevent this  I did this two posible options, but is not perfect...
    1. There is an option under the page setup uncheked by default named "Highlight substitude fonts" so you have to check this option for every document you have and make, what a nightmare, this must be checked by defalut, please adobe team...!
    2. Also yo can try to change the default font following this steps, another nightmare because not always work
    To change the default font for Illustrator CS4
    Choose  File > Open and go to Documents and Settings/User/Application  Data/Adobe/Adobe Illustrator CS4 Settings/New Document Profiles  (Windows) or to Users/User/Library/Application Support/Adobe/Adobe  Illustrator CS4/New Document Profiles (Mac OS).
    Open  one of the default document profile template files (Basic CMYK, Basic  RGB, Mobile and Devices, Print, Video and Film, or Web, depending on  which type of document you intend to use).
    Choose Window > Type > Character Styles.
    Select the Normal Character Style and choose Character Style Options from the palette menu.
    Select Basic Character Formats and choose the desired font from the Font Family menu.
    Click OK, and then choose File > Save and close the file.
    Restart Illustrator
    Give it a try and tell us..

  • Open documents in same window (Adobe Reader 9)

    Dear forum,
    I would like to set up Adobe Reader 9, that it opens all documents in the same window. This is much easier to handle, when you have multiple documents opened.
    Does anybody know how to set up Adobe Reader 9 in this manner ?
    Thanks for your answers,
    Theklum

    This is the worst thing to happen to acrobat, in my opinion.
    The clutter that it creates on my computer and the fact that i cant even see the document title when I have a bunch of them open (because the task bar is too full) is unacceptable.
    I never would have changed from Acrobat 8 if I had known, and now I cant switch back (company license).
    The latest thing i can find about addressing it is here:
    http://kb.adobe.com/selfservice/viewContent.do?externalId=kb405108&sliceId=1
    which was in november 2008....
    why hasnt any thing else been done about it?  I just spent 45 minutes being sent to different departments over the phone, only to be told to submit a feature request.
    Please do this if you havent already:
    http://www.adobe.com/cfusion/mmform/index.cfm?name=wishform

  • How to print set of documents without showing print dialog box

    I have created a smartform tht prints a Payment Advice. Its input includes range of Document numbers.
    I call the smartform function in loop for all those document numbers. Now my problem is tht everytime tht function is executed the print dialog opens up askin for Printer name and then on pressin 'print', one document is printed and so user has to press print tht many times. To avoid this i added code:
    DATA: it_ssfcompop TYPE ssfcompop.
    DATA : gst_control_parameters TYPE ssfctrlop.
    DATA : gt_job_output_info TYPE ssfcrescl.
        it_ssfcompop-tddest = 'LOCL'.
         IT_SSFCOMPOP-TDNOPREV = 'X'.
         it_ssfcompop-tdnewid = sy-prnew.
         it_ssfcompop-tddelete = sy-prrel.
         it_ssfcompop-tdimmed = 'X'.
         it_ssfcompop-tdnoprint = 'X'.
         CLEAR gst_control_parameters.
         gst_control_parameters-no_dialog = 'X'.
         gst_control_parameters-preview = 'X'. "Deactivate preview!
         gst_control_parameters-GETOTF = 'X'.
    and called smartform function like this:
      CALL FUNCTION FM_NAME
           EXPORTING
            BUKRS                      = BUKRS-LOW
            BELNR                      = BELNR
            GJAHR                      = GJAHR-LOW
            CONTROL_PARAMETERS         = gst_control_parameters
            OUTPUT_OPTIONS             = it_ssfcompop
         IMPORTING
            JOB_OUTPUT_INFO            = gt_job_output_info.
    this shows print preview but still does not print. What could be error. Please help.

    Try this
    * Work Area declarations
    w_objhead TYPE soli_tab,
    w_ctrlop TYPE ssfctrlop,
    w_compop TYPE ssfcompop,
    w_return TYPE ssfcrescl,
    w_doc_chng typE sodocchgi1,
    w_data TYPE sodocchgi1,
    w_buffer TYPE string,"To convert from 132 to 255
    * Variables declarations
    v_form_name TYPE rs38l_fnam,
    v_len_in LIKE sood-objlen,
    v_len_out LIKE sood-objlen,
    v_len_outn TYPE i,
    v_lines_txt TYPE i,
    v_lines_bin TYPE i.
    call function 'SSF_FUNCTION_MODULE_NAME'
    exporting
    formname = 'ZONE'
    importing
    fm_name = v_form_name
    exceptions
    no_form = 1
    no_function_module = 2
    others = 3.
    IF sy-subrc <> 0.
    MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
    WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
    ENDIF.
    w_ctrlop-getotf = 'X'.
    w_ctrlop-no_dialog = 'X'.
    w_compop-tdnoprev = 'X'.
    CALL FUNCTION v_form_name
    EXPORTING
    control_parameters = w_ctrlop
    output_options = w_compop
    user_settings = 'X'
    IMPORTING
    job_output_info = w_return
    EXCEPTIONS
    formatting_error = 1
    internal_error = 2
    send_error = 3
    user_canceled = 4
    OTHERS = 5.
    IF sy-subrc <> 0.
    MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
    WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
    ENDIF.

  • Asp requests download instead of opening document in new window

    I go to certain websites with the new FF 4 and attempt to access a document that uses asp and FF downloads it instead of opening it. Works fine in Safari, Chrome, Opera but not in FF.

    see : [https://support.mozilla.org/en-US/kb/change-firefox-behavior-when-open-file Change what Firefox does when you click on or download a file]
    see also : [https://support.mozilla.org/en-US/kb/set-how-firefox-handles-different-file-types Set how Firefox handles different types of files]
    thank you

  • I updated Pages two months ago, yet my gmail program will NOT send out a pages document and a pages file I saved to desktop will NOT open and a box pops up telling me it won't open document without the Pages upgrade WHICH I HAVE ALREADY DONE...PLEASE HELP

    I updated Pages two months ago to the latest version.  BUT, my MAIL program will not allow me to send documents I attach that are genereated witht eh update Pages.  And, when I save a doc to desktop generated in Pages, it will not opena, a box pops up and tells me the it wil not open until I have upgraded to the new PAges, WHICH I HAVE ALREADY DONE!!!  What is UP with this, can anyone please help me?  Would GREATLY appreciate it.
    SA

    Pages 5 is in a new format that is not compatible with GMail, Google, Amazon, DropBox and other 3rd party servers.
    Peter

Maybe you are looking for

  • Problem generating Adobe form in ABAP

    Hi Experts, I have just written a function module that calls a form that I created, which is meant to generate a pdf form and email it to a specific email address. However, I have the problem where the pdf is not being generated properly and is actua

  • Can't delete Motion.app

    After a problematic (endless, failed) update from the App Store, I need to delete and maybe reinstall Motion but I can't. Emptying the trash is impossible (left hanging there with a blank progress bar for 12 hours or more...). I tried using Terminal,

  • Print 6 Slides per Page

    Is it possible to have Keynote print 6 slides per page the way PowerPoint for Windows does (3 slides in each of two columns on the page), rather than 6 slides vertically along the left side of the page?

  • All mail accounts suddenly stopped working on iPad2. Have tried deleting accounts and re installing, but still no luck. Any solutions?

    Unable to find any of the mail servers for pop, gmail and me. However can access all accounts directly through web without issue.

  • Width Percentage problem for IE6?

    I have a CSS navigation bar with buttons defined in percentage, placed in a 100% width container.  The buttons add up to 100% in their widths.  This works fine for every browser except IE 6, which seemingly sets all the widths and heights of the butt