I've been working on a system to read data in blocks. It works well with text but when I try reading something like exe's it produces bad or not data. Is it possible to fix this problem if so how?
Why are you trying to read something like an exe? And what do you consider bad or no data. You can't use cout to print an array of char, especially an array of char that can contain embedded '\0' characters and may contain fewer characters than what you requested leaving all the other elements of the array in an undefined state.
However it becomes a ram hog after you read anything larger than say 1gb.
So I tried using the code above to break the file into blocks sort of like this.
1234 5678 91011
rather than
1234567891011
Which would use too much ram. I am trying to use this an encryption system.
One of your problems is that your using cout on an array of characters, not a string. You will need to print the individual characters since this array may and probably does have embedded '\0'.