Chris Sheffield wrote:
Does anyone have a sure fire way to determine if a file is binary or text?
There is no such thing as a sure fire way to determine if it is text or
not, unless the definition of text can be clearly defined.
I have need to create an import utility that will import data from a
text file (csv, tab-delimited, etc) into a database, but I'd like to
check the file before doing anything else just to make sure it is in
fact text and not binary.
Any thoughts?
I would just assume it is text, and then handle "wrong" input
gracefully. Trying to parse the contents first to verify it would just
add overhead, and is unnecessary if you do the former.
Consider my input as general, and not Revolution specific --my exposure
to Revolution is modest, at least at this point...
--
Geir A. Myrestrand
_______________________________________________
use-revolution mailing list
[email protected]
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-revolution