Problem in LR 6 with export post processing action using windows batch file

  • 1
  • Problem
  • Updated 2 years ago
I have an export action that changes the attribute of all the exported files to read-only. After all the files have been made read-only, the batch file opens Windows Explorer. The problem is that I now get multiple runs of my export action depending on the number of files I'm exporting. For example, up to around 5 files and I get one Explorer window launched at the end. With 20 or so files, I may get three Explorer windows opened. With 150 files, I may get 12 Explorer windows! Debugging it, the problem is that the batch file gets executed multiple times.

Upon further investigation, it turns out that LR 6 limits the command line length to around 1,400 characters. So, depending on the number of photos being exported, plus the path and file name for each photo, one or more command windows will be started. This seems like a new behavior for LR.

To test this, I exported 37 photos. The first complete file name is E:\Users\Scott\Desktop\Test\Test-1.jpg. With this naming sequence, the first command window processed 35 photos and the second window processed two photos. I then added one character on to the file name (E:\Users\Scott\Desktop\Test\TestA-1.jpg). In this test, the first window processed 34 photos and the second window three photos. Both times the line length was just shy of 1,400 characters.

I hope someone knows how to get around this limit.
Photo of Scott Rosenthal

Scott Rosenthal

  • 15 Posts
  • 0 Reply Likes

Posted 2 years ago

  • 1

Be the first to post a reply!