Apparently this VBA code that I'm trying to create is too difficult for AI, so I wanted to throw this out here to you guys because you've helped me tremendously over the years. Here we go, I will attempt to explain what I'm trying to do. Please bare with me:
We are a small print shop that is trying to layout files for our digital printer so the process is quicker. These printed files, (after they are printed onto a 12x18 sheet) will then go through a series of two other steps. After they are printed, it will go through a heater, page by page. Then lastly, it will be sent through a cutting machine, page by page that will cut it down into individual pieces. I need this VBA code to put the files in alphabetical order so I can use it for the first step, which is the InDesign layout. The layout needs to be in such a way that the last step keeps the alphabetical order with "A" on top and "Z" on the bottom.
The Process:
We will use InDesign data merge to pull in the files to make the layout, which will then be exported and used to print the files digitally on our digital printer. The InDesign data merge uses a csv file that will have the names of all the files I need to layout, in a single column list. InDesign will take this list and lay it out from left to right. The VBA code will be used in another workbook that I have that contains lists of items that customers choose from. I want the VBA code to look at a "RawData" tab that lists the quantities next to the description and file names. Headers are starting on row 2, raw data underneath in columns A:D. The VBA code will create the layout and create an "output" tab, (keeping in mind that each item could have more than 1 quantity, so it will need to take that into account and list it as many times as the quantity states. Also keeping in mind how the final result should be, which is alphabetical order with A on top and Z on the bottom. ) I will then take the output of the VBA code and paste it into a csv that InDesign will data merge and create the layout.
InDesign auto layout (which is what I need the vba code to create in one list) will take the list of files and lay them out on a page in two columns with 6 rows equaling 12 on a page. It will lay them out starting from left to right and will then begin the next row directly underneath it, left to right. This will make 12 total on the page. The number of files will vary, it can be different all the time. So the vba code will need to take the total number of files and divide it by 12 to get the total pages before it can lay it out in alphabetical order.
The finished product at the digital printer will come out with page 1 on top, which will have "A" then moving through the alphabet per page with last page having "Z". Here is a visual layout of the pages and how the alphabetical order should look. Also on the left is the VBA output order to achieve this.
From the digital printer it get’s taken over to a clear coating machine where they will feed each sheet, one at a time into the machine and it will come out with the last page on top, with “Z” on top and “A” on the bottom.
After that clear coat step, it will be fed into a Duplo machine where it will be cut into individual pieces. It will be fed starting with the last page with “Z” on top and end up with the last page with “A” on top. It cuts them into two columns and drops them into the delivery that way. We need to be able to then physically stack the left column on top of the right column putting “A” on top and “Z” on the bottom. Here is a visual:
The amount of files will vary every time, but the layout method needs to remain the same to get the desired result from the last step which is the Duplo cutting machine. So you will first need to take the amount of files then divide them by 12 so you can get the amount of pages. Then lay them out in two columns, starting from the left. Remember that the order is important in order to get them in the correct alphabetical order at the end. So even though InDesign is laying them out starting in position 1 top left corner and moving over to the right and then starting a new row underneath, the file names need to be laid out starting in bottom left position of page and going up then onto the next page and going up, then reaching the end of the pages and then starting in the bottom right and going up and so on till all pages are filled.
I know that was long and confusing but I hope someone was able to follow along because I've been working on this for a couple weeks now. The VBA that AI keeps coming up with does not put it in the order I need for the end result after it's cut. Please let me know if there is anymore information I can provide.
We are a small print shop that is trying to layout files for our digital printer so the process is quicker. These printed files, (after they are printed onto a 12x18 sheet) will then go through a series of two other steps. After they are printed, it will go through a heater, page by page. Then lastly, it will be sent through a cutting machine, page by page that will cut it down into individual pieces. I need this VBA code to put the files in alphabetical order so I can use it for the first step, which is the InDesign layout. The layout needs to be in such a way that the last step keeps the alphabetical order with "A" on top and "Z" on the bottom.
The Process:
We will use InDesign data merge to pull in the files to make the layout, which will then be exported and used to print the files digitally on our digital printer. The InDesign data merge uses a csv file that will have the names of all the files I need to layout, in a single column list. InDesign will take this list and lay it out from left to right. The VBA code will be used in another workbook that I have that contains lists of items that customers choose from. I want the VBA code to look at a "RawData" tab that lists the quantities next to the description and file names. Headers are starting on row 2, raw data underneath in columns A:D. The VBA code will create the layout and create an "output" tab, (keeping in mind that each item could have more than 1 quantity, so it will need to take that into account and list it as many times as the quantity states. Also keeping in mind how the final result should be, which is alphabetical order with A on top and Z on the bottom. ) I will then take the output of the VBA code and paste it into a csv that InDesign will data merge and create the layout.
InDesign auto layout (which is what I need the vba code to create in one list) will take the list of files and lay them out on a page in two columns with 6 rows equaling 12 on a page. It will lay them out starting from left to right and will then begin the next row directly underneath it, left to right. This will make 12 total on the page. The number of files will vary, it can be different all the time. So the vba code will need to take the total number of files and divide it by 12 to get the total pages before it can lay it out in alphabetical order.
The finished product at the digital printer will come out with page 1 on top, which will have "A" then moving through the alphabet per page with last page having "Z". Here is a visual layout of the pages and how the alphabetical order should look. Also on the left is the VBA output order to achieve this.
From the digital printer it get’s taken over to a clear coating machine where they will feed each sheet, one at a time into the machine and it will come out with the last page on top, with “Z” on top and “A” on the bottom.
After that clear coat step, it will be fed into a Duplo machine where it will be cut into individual pieces. It will be fed starting with the last page with “Z” on top and end up with the last page with “A” on top. It cuts them into two columns and drops them into the delivery that way. We need to be able to then physically stack the left column on top of the right column putting “A” on top and “Z” on the bottom. Here is a visual:
The amount of files will vary every time, but the layout method needs to remain the same to get the desired result from the last step which is the Duplo cutting machine. So you will first need to take the amount of files then divide them by 12 so you can get the amount of pages. Then lay them out in two columns, starting from the left. Remember that the order is important in order to get them in the correct alphabetical order at the end. So even though InDesign is laying them out starting in position 1 top left corner and moving over to the right and then starting a new row underneath, the file names need to be laid out starting in bottom left position of page and going up then onto the next page and going up, then reaching the end of the pages and then starting in the bottom right and going up and so on till all pages are filled.
I know that was long and confusing but I hope someone was able to follow along because I've been working on this for a couple weeks now. The VBA that AI keeps coming up with does not put it in the order I need for the end result after it's cut. Please let me know if there is anymore information I can provide.