Date: Mon, 25 Jun 2001 19:19:36 +0200
Reply-To: Yung-Yang_Hu@ABNAMRO.COM
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Yung-Yang_Hu@ABNAMRO.COM
Subject: Re: Directory exists or not??
Content-type: text/plain; charset=us-ascii
With FEXIST you still do not know if it is a file or directory . (in V6 ) I
try to open the directory with the DOPEN function. If it fails it is not a
directory or the dirname is incorrect:
rc=fileref('<fileref>','<dirname>')
dir_id=DOPEN('<dirname>')
if dir_id then {it exists} ELSE {not exist};
IF dir_id THEN dir_id=DCLOSE(dir_id);
rc=fileref('<fileref>','');
(same principle as the libname function)
"Smith, Curtis, Mr, DCAA" <Curtis.Smith@DCAA.MIL>@LISTSERV.UGA.EDU> on
06/25/2001 06:13:02 PM
Please respond to "Smith, Curtis, Mr, DCAA" <Curtis.Smith@DCAA.MIL>
Sent by: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
To: SAS-L@LISTSERV.UGA.EDU
cc:
Subject: Re: Directory exists or not??
Yes, use the FEXIST function.
-----Original Message-----
From: Jeff Morison [mailto:jmt_mtf@YAHOO.COM]
Sent: Monday, June 25, 2001 9:58 AM
To: SAS-L@LISTSERV.UGA.EDU
Subject: Directory exists or not??
I know one way to check to see if a directory or
sub-directory in PC exists or not using LIBREF
function,
Are there any other easy ways or functions to find
that information?.
Using V8.1 on NT.
__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail
http://personal.mail.yahoo.com/