I works like this:
1. Windows task scheduler invokes my VB script.
2. VB script launches a .bat file that sets permissions using the
CWBCFG command
3. VB script opens presaved file transfer from AS400 to the PC via
client access.
4. VB script opens excel
5. Excel has Vb scipt in it to manipulate the data and make it "pretty"
6. Excel prints the file in pdf.
7. VB scipt moves the pdf file to our intranet.
8. program is complete.
Now for what ever reason the data file transfer is not happening. I
have tried like mad to use different combinations of the cwbcfg command
and settings to get this to work only to come up empty handed.
Anybody have any idea on how to make this work again?
Thanks!
Chad
Thanks!
Chad
That's a very bad way to do it.
CPYTOPCD copies to the /QDLS file system which was originally designed
for Office Vision and DOS connectivity. It's use is not recommend no-a-
days due to pore performance and limitations.
Instead, use the CPYTOSTMF command to copy to one of the more modern
file systems, root or QOpenSys. You could even use the /QNTC file
system to place the file directly on a PC's network share.
If you use root or QOpenSys, use iSeries Netserver to create a Windows
compatible share the PC will be able to access.
HTH,
Charles
I suggest you also look at CPYTOIMPF as an alternative to CPYTOSTMF
using the other suggestions made by Charles.
Angus
I tried CPYTOPCD and it worked sort of, but it fubared some of my
fileds. In other words it took the data file produced by the query and
put a bunch of goobly gook into the last three fields when viewing the
query file AS a text file on the PC.
So I tried the CPYTOSTMF and I get the following error:
Message . . . . : Object is not a file or is a file with attributes
not
supported by this command.
Cause . . . . . : Object
/qsys.lib/scott.lib/prbktest.file/prbktest.mbr must
be either a source physical file that has three fields or a program
described file. Externally described files and source physical files
containing fewer or more than three fields are not permitted by this
command.
Recovery . . . : Specify the name of an existing source physical
file with
correct attributes, or specify a program described file, then try
the
command again.
So I tried the CPYTOIMPF:
Why do I want to copy frome one data base to another database file and
then to a streaming file? I left out the second database file name and
it won't work either. Then I tried putting in a name as I assume this
is just a "temp" file and got the error:
STMFCODPAG not valid when output file is a database file. This was
becasuse I put PCASCII or STDASCII in that field. If I leave the
default it work but it copies a bunch of crap to the pc text file which
I assume is the PCs attempt to read an ebcidic file.
Can you all please provide me a bit more help. I never realized that
copying a file from AS400 to PC would be such a pain in the butt. Is
there any resources I can use to better educate myself about stuff of
this nature? I know the basics of the AS400 but am more of a Microsoft
person. I just hate feeling like a moran and when ever thing get rough
with the 400 I feel like moran.
Any help you all can provide would much appreciated.