LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous (more recent) messageNext (less recent) messagePrevious (more recent) in topicNext (less recent) in topicPrevious (more recent) by same authorNext (less recent) by same authorPrevious page (November 1999, week 2)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Mon, 8 Nov 1999 12:36:27 GMT
Reply-To:     Huck <huck@FINN.EXTRA..COM>
Sender:       "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:         Huck <huck@FINN.EXTRA..COM>
Organization: HarvardNET
Subject:      Re: Getting IP adress dynamically.

i think netstat might be the easiest, but may produce more lines of output netstat -an >junk.txt data _null_; .......

On 2 Nov 99 19:03:03 GMT, raymondk@MOCR.OAPI.COM (King, Raymond) wrote:

>I seem to recall a similar question from a year or so ago. > >I think you can use the ARP command and redirect the output to a file. > > arp -a > arpdata.txt > >You read the file in SAS and then extract the IP address from the specific >line # and position in a data step and assign it to a macro variable before >doing your download. > >HTH, >Raymond > > >> -----Original Message----- >> From: Rob Rohrbough [SMTP:Rob@ROHRBOUGH-SYSTEMS.COM] >> Sent: Tuesday, November 02, 1999 1:37 PM >> To: SAS-L@LISTSERV.UGA.EDU >> Subject: Re: Getting IP adress dynamically. >> >> Not sure if WINIPCFG will write to a file. It does have a control menu >> option to copy to the clipboard. There may be a command line parameter >> that >> you can use to trigger this option from an X command. Then you would have >> to programmatically read the clipboard from SAS. >> >> Another option to think about is the Windows SDK. WINIPCFG gets its >> information from somewhere - probably via a Windows API. Conceivably, you >> could find the API call and write a DLL in C or another language to return >> the IP address dynamically to SAS. >> >> Not everyone would want to resort to this - just a thought, >> >> Rob >> >> >> Paul Kairis wrote: >> >> >Can you write the output of the WINIPCFG to a temp file and then read >> >that file and extract the IP info ... >> >> >> > -----Original Message----- >> > From: Pieter Kirsten [mailto:Ben-de.Gooijer@CORP.AH.NL] >> > Sent: Monday, November 01, 1999 2:51 AM >> > Subject: Getting IP adress dynamically. >> > >> > >> > I have a SAS/AF program that runs in the MVS environment. Itīs >> > purpose is to >> > create 4 flat files that needs to be downloaded. At the moment >> > the user must >> > input the IP adress every time it is used by running WINIPCFG and >> > seeing what >> > the current IP adress is. The program will then use this information and >> > download it from MVS to his PC. The user has Windows 95 at the moment. >> > >> > My question is if there is a way that I can retrieve the IP >> > adress automatically >> > as it is dynamically created each day. Maybe combining the X >> > command with some >> > Dos commands or a small dos program. Can someone direct in the >> > right direction >> > or stop me if I am wasting my time. >> > >> > Thanks >> > Pieter Kirsten >> >


Back to: Top of message | Previous page | Main SAS-L page