Here's the situation. I've got some data. It contains a text header and then one long string of binary data that represents numerous samples of data. I have a script that pulls off the header, and then begins to read the binary data. Depending on the type of data, each data point is n-bytes long. I take this into account. I read in, let's say 2 bytes, split them, ord each and reassemble the two numbers so that I have the value for the data point. All of this works fine in linux. However, when I run the same script in DOS (I'm using active state perl for the DOS part), it inevitably finds a byte that seems to indicate EOF for it. I've looked at the byte values in linux and DOS and they match until the hose up. The last byte that DOS gets is FDh. The one that it seems to trip up on is 1Ah which is actually SUB (substitute). It's my understanding that if you open a file in DOS you have to specify that it is a binary file or this type of control character error will occasionally (inevitably?) occur. So my question is this, how do I tell my filehandle, in the DOS implementation, that the file it points to is a binary file, not a text file? Or is my problem something else I haven't thought of?