On Thu, 10 Oct 2002 [EMAIL PROTECTED] wrote: > Like .bin, .exe files, The format of the file is binary instead of ASCII. > > Thanks > > Lixin > > -----Original Message----- > From: Stovall, Adrian M. [mailto:Adrian.Stovall@;durez.com] > Sent: Thursday, October 10, 2002 2:06 PM > To: [EMAIL PROTECTED] > Subject: RE: How can I figure out whether it is binary file or ASCII > file under one directory? > > > Can you be any more specific than "various binary files"? > > -----Original Message----- > From: [EMAIL PROTECTED] [mailto:Cai_Lixin@;emc.com] > Sent: Thursday, October 10, 2002 12:54 PM > To: [EMAIL PROTECTED]; > [EMAIL PROTECTED]; > [EMAIL PROTECTED] > Subject: How can I figure out whether it is binary file or ASCII file > under one directory? > > > Dear all, > > A question, How can I figure out whether it is binary file or ASCII file > under one directory using perl? Does perl have a function for that? I > have a project to pick up various binary files from some directories. >
The file test operators that I nebtioned previously can sometimes cause confusion. For example, it is entirely possible that a .pdf file can consist of nothing but ascii text characters however that doesn't mean that trying to print it out with NotePad will look very pretty. The use of the -T operator should not be relied on if the file's extention tells you something else. **** [EMAIL PROTECTED] <Carl Jolley> **** All opinions are my own and not necessarily those of my employer **** _______________________________________________ Perl-Win32-Users mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs