Hello, I had created some macros years ago that would take a prn file and import it according to the table columns which I would manipulate further. However, I needed some of the preceding header information so I just let it break across columns and then concatenate later to get the full text string. Because the incoming data would change, that was not always the cleanest solution.
Now the source system has changed the widths of the incoming data and I have to redo these, I'm wondering if there is a way to import text by position in the prn: for example lines 6,7,8 positions 10 through 40 would go into 3 separate cells in the Excel spreadsheet. Lines 6,7,8 positions 51 thru 81 would go into 3 other cells. There would be other header info to import in the first 8 rows. Then rows 9 to LR would be the spreadsheet that needs to get cleaned up.
I'm interested in seeing if this can be done.
Following is the top portion of the prn before it goes into columns. Thank you.
Now the source system has changed the widths of the incoming data and I have to redo these, I'm wondering if there is a way to import text by position in the prn: for example lines 6,7,8 positions 10 through 40 would go into 3 separate cells in the Excel spreadsheet. Lines 6,7,8 positions 51 thru 81 would go into 3 other cells. There would be other header info to import in the first 8 rows. Then rows 9 to LR would be the spreadsheet that needs to get cleaned up.
I'm interested in seeing if this can be done.
Following is the top portion of the prn before it goes into columns. Thank you.
PHP:
PURCHASE ORDER NO. 7448 VENDOR- SD01 PAGE 1
05/15/17 TERMS- SHIP VIA-
SEND TO: STANDARD MOTOR PRODUCTS BILL/ MYCOMPANY, INC.
7070 GOLF COURSE RD. SHIP TO:440 ASHLAND ST S.W.
DISPUTANA VA. 23842 CICERO, MI 49507
LINE ORDR PKG WD CORE
NO. PART NUMBER QTY UM QTY DESCRIPTION WEIGHT INVOICE PRICE CODE
--- ----------- --- -- --- ----------- ------ ------- ----- ----
1 AS523 1 EA 1 SENSOR 0.4 43.41 0.00 Q
2 CBS2140 1 EA 1 CMBN SWITCH 0.3 122.49 0.00 Q
3 CP443 1 EA 1 STANDARD FUEL VA 3.0 73.56 0.00 Q
4 CVS91 1 EA 1 VAPOR CANISTER V 0.3 38.11 0.00 Q
5 DV142 1 EA 1 DIVERTER VALVE 1.5 142.12 0.00 Q
6 ETB54 1 EA 1 EGR TUBE 0.5 25.97 0.00 Q