|
That's a good idea. Thanks Simon. Art Tostaine, Jr. CCA, Inc. Jackson, NJ 08527 Ping just tells you TCP is up. Maybe that's enough. PING lets you control how its messages are returned. You could set MSGMODE(*QUIET *ESCAPE) and monitor for the failure messages. > Any better ideas appreciated. I don't know about better but since you want to know if the remote file is available why not just attempt to open it? pgm (&method) dcl &method *char 4 if (&method *eq '*SNA') do opndbf ddmf_sna option(*inp) opnid(thefile) enddo else if (&method *eq '*TCP') do opndbf ddmf_tcp option(*input) opnid(thefile) enddo else do sndpgmmsg msgid(cpf9898) msgf(qcpfmsg) msgdta('Method must be *SNA or *TCP) + msgtype(*escape) enddo clof thefile endpgm This will verify communications, network, and file availability. Although my example distinguishes between SNA and TCP there is no need to do that. T=You can see the OPNDBF doesn't care about the transport mechanism.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 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.