Copy link to clipboard
Copied
Hello, we use the place() function (ex: myFrame.place(myFile) )
i have noticed that when i run a script that inserts ±20k images in an indesgn file with the 2022 version it took ±1-2hrs, but with 2023 it can take 3-4 days.
Logging the placing time i noticed that on the 2022 it always takes 100-300ms to place an image, while on the 2023 it starts with 100-300ms per image but it grows as more images are placed, at around 3k images it takes 1500-3000ms per image.
Copy link to clipboard
Copied
If you are processing a 20k item long js array, you may try to slice the array and process smaller chunks. I am not saying it will solve your issue but I remember that for one project, I had a very important array of items and it took hours to complete. I created a series of sub-arrays (100 items max) and could process the same items in a couple of minutes. Worth the try.
Copy link to clipboard
Copied
Are you opening the doc or keeping it hidden. Maybe try: app.enableRedraw = false;
Copy link to clipboard
Copied
First of all - doing it in one file is an overkill and asking for trouble 😞
Upgrading a bit @Loic.Aigon suggestion - you should split your document into smaller chunks.
You'll achieve few things:
As already mentioned by @brian_p_dts - you can either disable Redraw or save your document and then open it as invisible - you'll save a lot of time thanks to the fact that InDesign won't have to render / redraw screen.
Then, you can turn off Undo - which will save even more processing time and keep your file small.
And one more thing - what exactly are you doing? Because there may be a 3rd option 😉