Click here to Skip to main content
15,887,376 members
Please Sign up or sign in to vote.
3.00/5 (1 vote)
See more:
How to determine a file Encoding?
Posted

1 solution

Modern text files have a binary tag at the front of the file. You can read the first 4 bytes of a file and then look up the encoding from the table here:

http://en.wikipedia.org/wiki/Byte_order_mark[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900