Hi Emily,
That's not a text file. It's a binary file. Thos boxes and squiggles are
characters that your text editor is interpreting the binary data as. Let me
explain a bit, and see if this helps.
Everything in a computer is stored as 1s and 0s. Everything. That is why a
computer is called "binary." Binary means Base 2. Decimal numbers , such as
the type of numbers that you and I use every day, are called "decimal"
because they are Base 10 numbers. In Base 10 numbers, there are 10 digits,
0 - 9. In Base 2 numbers, the kind that the computer uses, there are 2
digits, 0 - 1. This is because a computer has billions of microscopic
transistors inside it that do the calculating. A transistor is basically a
switch, like a light switch. If the switch is off, its value is 0. If the
switch is on, its value is 1.
Any number can be represeted using 2 digits, but since there are only 2, you
need more places to represent higher numbers. In Base 10 numbers, the number
10 requires 2 digits to represent because 9 is the highest single digit in
the numbering system. In Base 2, the number 10 requires 4 digits to
represent (1010), as 1 is the higest single digit in the numbering system.
In Base 10, each "column" represents an exponent of 10: 1s, 10s, 100s, etc.
In Base 2, each "column" represent an exponent of 2: 1s, 2s, 4s, 8s, etc.
Because of this, and for the purpose of making things a little easier, a
byte of data in a computer is 8 digits in length, and can represent any
number from 0 (00000000) to 255 (11111111).
Okay, now for the part that relates to your problem. If everything
(including text) in a computer is nothing but 1s and 0s, how does the
computer know how to read it, and translate it into something meaningful to
you and I, mere humans? This is done via the file extension. The file
extension tells the operating system what kind of data is in the file (one
big long string of 1s and 0s), and how to interpret it. So, let's say the
file contains the following:
10001010001110111010100111010111011010010001100101001011
What the computer does is look at the file extension, which says ".txt" and
it says to itself, "Self, this is a text file. Therefore, I will break the
bytes up into chunks of the size of a character, and read it as a character
to the user." If the file has a .jpg extension, the computer says to itself
"Self, this is an image file. It contains pixels. So I will break the bytes
up into chunks the size of a pixel, and read it as an image (a whole bunch
of pixels of different colors) to the user.
So, the real question is, what IS the type of file you're looking at? If you
don't know, you can't give it the proper extension to clue in your computer.
Since you're seeing all those squiggly characters in your text editor (which
the OS opened it in, since it had a .txt extension), it is obviously NOT a
text file. So, you could give it a .jpg extension, and try to open it
(again, the computer will open it in a JPG editor). If that doesn't work,
try giving it a .gif extension to see whether it turns out to be a GIF. And
so on.
--
HTH,
Kevin Spencer
Microsoft MVP
..Net Developer
What You Seek Is What You Get.