Hello All:
HELP!!! I have developed a very slick VBA script in Excel which automates copying AS400 spool files to a Shared Folder in Windows using the CPYTOIMPF function. The CPYTOIMPF required several key values, which have all be captured in an AS400 Macro. I can manipulate the key values using VBA to select the appropriate spool files (they always have same name) as they are refreshed with new data.
My problem is the Job Number. CPYTOIMPF forces me to enter the latest Job Number, which requires manual intervention to find the Job Number. It seems to me if I know the Job Name (never changes), User Name (never changes), System Name (never changes), *Last file created, etc. Why won’t CPYTOIMPF forgive entering the Job Number which changes every time the spool file is refreshed. In one case there are 36 spool reports run in sequence and all have the same Job Number.
I will stop here and ask if anyone have a easy solution to get around the Job Report Number of a way to scrap the number perhaps from an AS400 screen. A solution would be a great find, and result in major labor savings at my company
Many thanks,
AMRICE
HELP!!! I have developed a very slick VBA script in Excel which automates copying AS400 spool files to a Shared Folder in Windows using the CPYTOIMPF function. The CPYTOIMPF required several key values, which have all be captured in an AS400 Macro. I can manipulate the key values using VBA to select the appropriate spool files (they always have same name) as they are refreshed with new data.
My problem is the Job Number. CPYTOIMPF forces me to enter the latest Job Number, which requires manual intervention to find the Job Number. It seems to me if I know the Job Name (never changes), User Name (never changes), System Name (never changes), *Last file created, etc. Why won’t CPYTOIMPF forgive entering the Job Number which changes every time the spool file is refreshed. In one case there are 36 spool reports run in sequence and all have the same Job Number.
I will stop here and ask if anyone have a easy solution to get around the Job Report Number of a way to scrap the number perhaps from an AS400 screen. A solution would be a great find, and result in major labor savings at my company
Many thanks,
AMRICE