How to cleam memory in InDesign.

Dear all,
We are developing a extension for Adobe InDesign and after many months of development we are still stuck with various things we cannot find a proper solution to them. The extension exports a lot of images, texts, creates new pages, basically we are exporting all the content in a document as long as 300-400 pages in different assets, in JPG and PNG formats. So is really memory consuming
When running the extension we have developed, the main thread is bloqued and the InDesign is not responding and if the export we are doing is really large it just crashes InDesign. We would like to reléase memory after each page is finished, but we cannot do so. Once the complete export is finished, then memory is released, but not while the export is happening
As we export the memory is increasing more and more without releasing anything, we have tried different options, but seems like we never get to release memory as everything is blocked
How can we release memory while the extension is running ? Or is there a way to stop the extension each iteration so it releases memory?
We use the extension manager and flash builder.
Thanks!
Cesar.

Hi Cesar,
I'm also making an export script, (not extension), mine seems to be quite different to yours but we'll might see when both are published.
Off the point.
The first thing you have to be aware of is using flash builder and extension manager, If you are making a flash based extension, from what I understand it's not going to work for the next version of InDesign which is switching to HTML5 based panels and dropping support for flash based panels (you'll still need the flash based panels to support the current version (9) and below. This is going to be a major pain for all extensions for the next lot of years that all of them will need 2 completely different interface bases to be compatible with CC(1), CS6 (which is going to be around for a long time for obvious reasons) and below on the one side and CC(2) + on the other.  I can't actually blame Adobe for this one as there should be some serious benefits in the HTML5 panels.
Back to the point.
See Ariel's Phenomenal optimization technique! which is based on the same Idea of breaking down the script into small parts.
See also Re: Big performance issue while removing tabs by indents including the link brought by Xavier in 7 over there. Loic reduced his script run time from 6 hours + to 90 seconds by using efficient techniques.
I made a script for making swatch books (sort of thing than Pantone publish - involved a quite a bit of maths and color conversions) it was workable for 3,000 - 4,000 swatches but when it got to 15,000 or so swatches the machines wouldn't budge one bit.  Separating the output into separate document  (which any I needed to do because the proofing and print machines can only handle up to 27 spot colors) resulted in the script working very efficiently.
As Uwe mentioned redraw can make a big difference and even more so hidden documents app.open(myFile, false)
Using myObjectCollection.everyItem().getElements().slice(0). Very significant for big collections.
Better still don't make big collections in the first place.  Don't if possible try process all the export items in the document myItems = doc.allGraphics or myItems = doc.spreads.everyItem().allGraphics rather make a collection myItems = doc.spread[n].allGraphics this will take up much less memory and work much quicker.
Try playing with $.memCache see if increasing or reducing the memory allocation makes a difference.  Please let me know if it does!
There's a very lot of methods that would depend on the actual script the differences can be huge, from scripts that just won't move to taking less than 2 minutes.
Don't forget to report back with the results
Trevor

Similar Messages

  • How to save down from InDesign Creative Cloud version to CS5? Have exported as .idml file but still get messages that plug-ins are missing although CS5 confirms it is fully updated.

    How to save down from InDesign Creative Cloud version to CS5? Have exported as .idml file but still get messages that plug-ins are missing although CS5 confirms it is fully updated.

    Yes. Thanks. I misled myself based on another post. Successfully did this by selecting "File," "Save a copy ..." then choosing "for CS4 or later (IDML)"
    It required some patience and several tries, but I think that was due to hardware (memory) being overloaded by CC Cloud version or something. It was a 50 MB, 500-page file and took 17 minutes to convert/save,
    Re-capping: from CCloud to CS5, don't use "Export" (to IDML); use "Save as" or "Save a copy" and select "for CS4 or later (IDML)".
    Advice much appreciated.

  • How to install memory modules on a macbook pro 15"

    I run Windows 7 via parallels desktop on my macbook pro. How do I type special characters on a Word document using the mac keyboard?

    how to install memory modules on a macbook pro 15"
    Read the manual / user guide that came with your comptuer or download it from http://support.apple.com/manuals/
    I run Windows 7 via parallels desktop on my macbook pro. How do I type special characters on a Word document using the mac keyboard?
    Post your question on the Paralells forums:  http://forums.parallels.com

  • How Do I combine 2 InDesign Documents into 1 (in a very particular way)

    How do I combine two InDesign Documents into one in a very specific way.
    Here's my problem: I have two separate InDesign CS5 files for playing cards. File one is the front. File two is the back.
    The company that does my final print production needs the the cards sent as two separate PDFs. One for the card fronts, one for the card backs. Both of these InDesign (and the PDF export) files are arranged in the same way: page 1 is card #1, page 2 is card #2, etc. Nice and simple.
    However, I use a different company for producing prototype versions of the decks (the production printer can't do this economically). My prototype producer needs me to send a single PDF where page 1 is Card #1 Back, page 2 is Card #1 Front, Page 3 is Card #2 back, Page 4 is Card #2 front, etc.
    The decks I am building usually run 56 cards, but can be as large as 180 cards.
    So, what's the easiest way to automate this process? is there a way to combine two separate indesign files by "interleaving" the pages from the two original documents into a new larger document (where I could do a new PDF export)?  Or, is there a better way to do this in Acrobat Pro? At the moment I have to resort to drag and dropping each card from one PDF thumbnail pallet to the other. It's really time consuming and mind-numbingly boring.  Any Ideas?

    This script is actually pretty straightforward, so it's a good first
    challenge I think.
    I would script this in InDesign -- probably because I'm more familiar
    with InDesign scripting.
    To start learning the InDesign scripting basics, open the ExtendScript
    Toolkit (ESTK) which is almost certainly installed on your computer
    already. Go to the Help menu, and you'll find an entry there called
    Adobe Intro to Scripting. Read that. I think that's the best place to start.
    For the script in question, you would want to:
    1. make sure both InDesign documents are open. They would both have the
    same number of pages. (No scripting involved here, just make sure
    they're open before running the script.)
    2. loop backwards through the collection of document pages of one of the
    documents. (document.pages is the collection you're looking for)
    3. use the move() method of a document page to move it. (myPage.move())
    4. Learn about the LocationOptions enumerator so that when you move the
    page you can tell InDesign if you want to move it before, or after
    another page. (LocationOptions.AFTER or LocationOptions.BEFORE)
    5. Get a reference to the page in the second document before (or after)
    which you want to move the page in the first document.
    5. that's basically it
    I suggest that as you work your way through this (if you decide to take
    up the challenge), you post any questions you may have on the InDesign
    Scripting forum here.

  • How to reduce memory use on my iMac

    How to reduce memory use on my iMac, OS X Yosemite, 2.7 GHz Intel Core i5
    8 GB memory
    Running very slowly, and the little spinning ball showing up.
    How do I clean up my IMac please?
    Should I use MacKeep or any clean up apps?

    When you see a beachball cursor or the slowness is especially bad, note the exact time: hour, minute, second.  
    These instructions must be carried out as an administrator. If you have only one user account, you are the administrator.
    Launch the Console application in any of the following ways:
    ☞ Enter the first few letters of its name into a Spotlight search. Select it in the results (it should be at the top.)
    ☞ In the Finder, select Go ▹ Utilities from the menu bar, or press the key combination shift-command-U. The application is in the folder that opens.
    ☞ Open LaunchPad and start typing the name.
    The title of the Console window should be All Messages. If it isn't, select
              SYSTEM LOG QUERIES ▹ All Messages
    from the log list on the left. If you don't see that list, select
              View ▹ Show Log List
    from the menu bar at the top of the screen.
    Each message in the log begins with the date and time when it was entered. Scroll back to the time you noted above.
    Select the messages entered from then until the end of the episode, or until they start to repeat, whichever comes first.
    Copy the messages to the Clipboard by pressing the key combination command-C. Paste into a reply to this message by pressing command-V.
    The log contains a vast amount of information, almost all of it useless for solving any particular problem. When posting a log extract, be selective. A few dozen lines are almost always more than enough.
    Please don't indiscriminately dump thousands of lines from the log into this discussion.
    Please don't post screenshots of log messages—post the text.
    Some private information, such as your name, may appear in the log. Anonymize before posting.

  • How can I get a indesign debug version?

    How can I get a indesign debug version? is it free?
    Anyone could give me a download link?
    thanks

    I know this is available to solution providers, if you are registered as such at partners.adobe.com. I don't know what level of membership is required, but that is one place the debug version is available from.
    Thanks,
    Max
    Max Dunn
    Silicon Publishing
    www.siliconpublishing.com

  • How can I tell what video card and how much video memory does my iMac have?

    How or where can I find out: which video card does my iMac have and how much video memory does it have? I've tried looking in System profiler, but I did not see it there. Thank you.

    Once you open System Profiler there should be a line called "memory" which is the RAM (vs. hard drive size which is not what is called memory), e.g., Memory: 1.5 GB
    For video click on the line Graphics/Displays and look at the chipset line, e.g., Chipset Model: GeForce2 TwinView
    Kappy's instructions are handy for checking the original configuration of your computer, but that may have been changed at some time, especially if you bought it secondhand.

  • How to show/hide an indesign document in cs4

    Hi all,
    How to hide/show an indesign document in cs4.
    In cs3 , I am doing this using the following code --
    IWindow* docWindow = Utils<IWindowUtils>()->GetFrontDocWindow( docRef.GetDataBase() );
    //Schedule the command to show the layout window of original document in CS3
    InterfacePtr<ICommand> showHideCmd (CmdUtils::CreateCommand( kShowHideWinCmdBoss ));
    InterfacePtr<ICloseWinCmdData > closeWinCmdData (showHideCmd, IID_ICLOSEWINCMDDATA);
    closeWinCmdData->Set( docWindow );
    InterfacePtr<IIntData> iIntData (showHideCmd, IID_IINTDATA);
    iIntData->Set( IWindow::kShow );
    CmdUtils::ScheduleCommand( showHideCmd );
    docWindow->BringToFront();
    In cs4, there is an API kShowHidePresentaitonCmd
    Code that i wrote for CS4 --
    //Schedule the command to show the layout window of original document in CS4IDocumentPresentation* docWindow = Utils<IDocumentUIUtils>()->GetFrontmostPresentationForDocument( docRef.GetDataBase() );
    InterfacePtr<ICommand> showHideCmd (CmdUtils::CreateCommand( kShowHidePresentationCmdBoss ));
    InterfacePtr<IPresentationCmdData> presentationCmdData (showHideCmd, IID_IPRESENTATIONCMDDATA);
    presentationCmdData->Set( docWindow );
    InterfacePtr<IIntData> iIntData (showHideCmd, IID_IINTDATA);
    iIntData->Set( 0 );                                       // What is the parameter that should be passed in the set function. 0 is not working
    ErrorCode result = CmdUtils::ProcessCommand( showHideCmd );
    Hide/show document in cs4 is not working

    ErrorCode ShowHideDocument(IDocumentPresentation*docWindow, int32 nShowHide)
    ErrorCode result = kFailure;
    do
      InterfacePtr<IControlView> controlView (docWindow, UseDefaultIID());
      if(controlView == nil)
         break;
      if(nShowHide == 0)
       controlView->Hide();
      else
       controlView->Show();
      result = kSuccess;
    }while( kFalse );
    return result;
    May be helpful!!

  • How do you save an InDesign CC doc down to InDesign 6 so that you can open it in 6?

    How do you save an InDesign CC doc down to InDesign 6 so that you can open it in 6?

    Export/Save As .idml, and don't expect a perfect translation.

  • How do I save my InDesign project as a .pdf so that it shows up on the reader as FACING PAGES?

    How do I save my InDesign project as a .pdf so that it shows up on the acrobate reader as FACING PAGES?

    It's on the export options for PDF (Interactive), but not for PDF (Print).

  • How do I update my InDesign CS3 plugins? I received a document from a colleague created in CS3 and I can't open it due to missing plugins.

    How do I update my InDesign CS3 plugins? I received a document from a colleague created in CS3 and I can't open it due to missing plugins.

    The error message is below. When I get info on the file it says it's a CS3 file.

  • IPAD 16 GB HOW TO CLEAR MEMORY

    IPAD 16 GB HOW TO CLEAR MEMORY ios7

    What do you mean by 'clear memory' ?
    You can close apps via the iPad's taskbar (a lot of the apps that show on the taskbar will just be 'recently used', they won't be using resources) : from the home screen (if you have an app 'open' on-screen then it won't show on the taskbar for closing) double-click the home button to bring up the taskbar at the bottom of the iPad's screen, then press and hold any of the apps on the taskbar for a couple of seconds or so until they start shaking, then press the '-' in the top left of the iTunes app to close it, and touch any part of the screen above the taskbar so as to stop the shaking and close the taskbar.
    If you want to delete content from your iPad to free up storage then you can see how much space each app is taking up via Settings > General > Usage. To delete an app (and therefore its content) press and hold any of the apps on your iPad’s homescreen and after a couple of seconds or so they should start to shake. Then press the 'x' in the left corner to delete the ones that you don't want, and when you've finished deleting press the home button so as to stop the shaking. If you don't get the 'x' on any of the apps that you've downloaded (you can't delete built-in apps) then check that Settings > General > Restrictions > Deleting Apps isn't set 'off'.
    To do a soft-reset (i.e. a reboot) : press and hold both the sleep and home buttons for about 10 to 15 seconds (ignore the red slider), after which the Apple logo should appear.

  • How do I set up InDesign cross-document Text Anchor Hyperlinks so that when the files are moved, they remain active?

    I’m combining several InDesign files into one PDF, with several hundred text links across the different sections, as well as within each. The cross-document (section) Text Anchor Hyperlinks work fine in my workspace - but when I change the file location, they are no longer active (other links, bookmarks remain intact).
    How do I set up InDesign cross-document Text Anchor Hyperlinks so that when the files are moved, they remain active? 

    They seem to be a lot of extra work, and I don't see what the additional benefit is. I have several hundred links to do. I would appreciate learning what the benefit is, as I don't mind the extra effort if it will deliver the desired results.

  • How/where can I download Indesign 7?

    How/where can I download Indesign 7?
    I have CS6 I need to download 7 to open client's files.

    Indesign 7 = CS5.
    You should be able to open CS5 files with Indesign CS6.

  • Already create hyperlink in MSWord file. same link how can i import in indesign?

    Dear All,
    Already create hyperlink in MSWord file. same link how can i import in indesign?

    I'm not having an issue as shown below:

Maybe you are looking for

  • Get_num_value not returning correct value

    Hello, I anm developing with Designer/Headstart 9i. I'll try to be clear on my problem. I am using the function get_num_value form one of my table CAPI. Here is the scenario 1. I do a get_num_value and get 2 as a value 2. I update the column to -1. 3

  • Query on F110 remitance date

    Hi Guys, I am not able to select discussion area as Acccounts payable /disbursement. My query is as follows - I ran Proposal SG01 on 29.04.2014, but proposal was approved on 30.04.2014 and payment run was made 30.04.2014 In the remittance sent to ven

  • How can I get confirmation that my email was received by addressee?

    In Outlook I could choose the option of receiving a confirmation once the email I had sent was either delivered and/or read. I can't find this option anywhere in iMail. Does anybody know if this exists and if so, how do I do that?

  • Version of Autoconfig

    Hi everyone, I have a doubt, i hope somebody can help me. How can i know the current version of autoconfig that i had, i see in metalink how know if we have the last version, but how can i know my current version? Thank you very much. Regards

  • HELP ME PLEASE..DATABASE COMPONENT!!

    Hello , I'm new in Jdeveloper. I purchased the Jdeveloper Handbook from Oracle Press. This book is related to the early versions of Jdeveloper (1.X). The problem is that I'm using the 3.0 version and WHERE ARE THE DATABASE AND THE QUERYDATASET COMPON