Hi All - Bear with me. I'm very much a VBA newbie and am trying to teach myself best I can. I've seen quite a few threads discussing something similar to what I'm trying to achieve but being new to VBA, I haven't been able to figure out how to modify the solutions to my specific need. Here's my scenario:
I have a workbook with data in multiple sheets. I need to consolidate into a single sheet formatted as an import file for our ERP software. The sheets are named "SO-PREPRO-H", "SO-PREPRO-L", "SO-PREPRO-N", "SO-PREPRO-T", "SO-PREPRO-X". The range of data will need to be dynamic for rows and will go out to "BX" for columns. Also note, each sheet has a header row but I do not want to copy the header info. I need a macro to start in order of the sheets listed and copy the content of the entire row (as values) where column "A" contains a specific letter to a master sheet named "SOIMPORT". For example: "SO-PREPRO-H", copy all rows containing "H" in column "A" to "SOIMPORT" then SO-PREPRO-L, copy all rows where column "A" contains "L" to next open row on "SOIMPORT", (same for "SO-PREPRO-N", "SO-PREPRO-T" & "SO-PREPRO-X).
The ultimate goal is to create a single CSV file that will be used as an order import template. If there is any way at the end of this script, to add code to replace all commas in "SOIMPORT" with a space and then save "SOIMPORT" as a .csv named after the value entered in cell reference "='SO Details'!A1", the would be too good to be true!!!
Thanks so much for any guidance you can provide. I love this site and learn so much from all of you. Hopefully I can get to a point I'll be able to contribute & give back!!!
Best regards,
Brett
Update: At the recommendation of one or our members, I attached a sample file. Note in the live workbook (too large to upload, the actual sheets have formulas to return a value or blank "". Thus the reason I want to paste the entire row as value. Please let me know if anyone has questions and thanks again!!!
Bookmarks