|
Hi Scott. The location of my NT shared folder is 192.168.10.2/shared. When I do a wrklnk /QNTC/192.168.10.2/shared, it says "object not found". Do I need to someone "map" or configure the iseries to recognize that location on the network. Thanks -----Original Message----- From: midrange-l-bounces@xxxxxxxxxxxx [mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of midrange-l-request@xxxxxxxxxxxx Sent: Sunday, December 10, 2006 1:00 PM To: midrange-l@xxxxxxxxxxxx Subject: MIDRANGE-L Digest, Vol 5, Issue 2387 Send MIDRANGE-L mailing list submissions to midrange-l@xxxxxxxxxxxx To subscribe or unsubscribe via the World Wide Web, visit http://lists.midrange.com/mailman/listinfo/midrange-l or, via email, send a message with subject or body 'help' to midrange-l-request@xxxxxxxxxxxx You can reach the person managing the list at midrange-l-owner@xxxxxxxxxxxx When replying, please edit your Subject line so it is more specific than "Re: Contents of MIDRANGE-L digest..." *** NOTE: When replying to this digest message, PLEASE remove all text unrelated to your reply and change the subject line so it is meaningful. Today's Topics: 1. Re: Access non-ibm file server fils from iseries (Michael Ryan) (tim) 2. Re: Access non-ibm file server fils from iseries (Scott Klement) ---------------------------------------------------------------------- message: 1 date: Sun, 10 Dec 2006 11:44:59 -0500 from: "tim" <tim2006@xxxxxxxxxxx> subject: Re: Access non-ibm file server fils from iseries (Michael Ryan) I will try to clarify. We have folders/files that exist on an NT server. From the iseries via rpg, I would like to be able to read the NT server directories, and open the files in there. For example, I would like to see if a file exists in a specific directory, and if it does, open it with its corresponding pgm (such as Adobe, Word, Excel, etc) or, read it as a stream file. I am currently reading stream files located in the IFS, and would love the same ability with file located on the NT server (non iseries platform). I hope this make some more sence. ------------------------------ message: 2 date: Sun, 10 Dec 2006 11:14:56 -0600 (CST) from: Scott Klement <midrange-l@xxxxxxxxxxxxxxxx> subject: Re: Access non-ibm file server fils from iseries Hi Tim,
Our shop has an iseries (520 v5r4) and some NT servers with some shared folders. Is there a way of reading/accessing the NT server files from the iseries. Using the IFS is not a consideration.
The System i provides access to Windows machines through the IFS. A lot of the time, when people refer to the "IFS" they're referring to the ability to store PC-like files on the System i. However -- that's NOT what I'm talking about today. The IFS includes many different things, including the ability to access Windows NEworking (SMB) file shares, the ability to access Network File Systems (NFS), the ability to access optical drives, the ability to access other iSeries computers over the network, the ability to access traidtional iSeries objects (You know, "library/object" objects) and the ability to store PC-style (stream) files on the system i hard drive... all of these completely different file systems are available through one integrated interface -- the "Integrated File System" (IFS) is the one interface!! IT's not just for storing PC files on your System i! It's for accessing Windows PCs over the network as well! In the world of Windows, you might access a file using a UNC path like this: \\AcctServer\C\customers\5412\Letter20061210.doc To access the same document from the iSeries, you change the path around a little bit. Instead of starting with \\, you start it with /QNTC. And you use forward slashes instead of backward ones. So to access the same file from an RPG program, you'd use the name: /QNTC/AcctServer/C/customers/5412/Letter20061210.doc You must use that from the IFS interface. From an RPG program, if you want to check if that file exists, you could use: D filename s 500A /free filename = '/QNTC/AcctServer/C/customers/5412/' + 'Letter20061210.doc'; if (access(%trimr(filename): F_OK) = 0); // file exists! endif; Obviously, you'd also need to create a prototype for the access() API. (But, it'd work!) For more info on IFS programming, please see the following document: http://www.scottklement.com/rpg/ifs.html To launch Word, Excel, etc... well, those programs don't run on the iSeries! You'd need to run them on the PC. You could send a remote command to the PC, though. You could do something like this: D QCMDEXC PR ExtPgm('QCMDEXC') D command 32702A const options(*varsize) D len 15p 5 const D cmd s 500A varying /free cmd = 'STRPCO'; callp(e) QCMDEXC(cmd: %len(cmd)); cmd = 'STRPCCMD PCCMD(''start winword "\\AcctServer\C\' + 'customers\5412\Letter20061210.doc"'')'; QCMDEXC(cmd: %len(cmd)); I don't currently have access to my iSeries -- I'm typing this from memory -- so I may not have everything 100% right, but maybe the above info will help you get started (or at least give you some command names to search for information about.) Also, if you remove the "winword" from the MS-DOS "start" command, it'll search for the best program to use for the file you've given. ------------------------------
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.