Hi,
I am trying to open and read a Binary file into visual C++. Can you tell me how to do that.(the file i am trying to read is a Matlab[.mat] file).
thanks a lot
ITT
This is the basic process:
CreateFile - open the file for read access
GetFileSize - get the size of the file
malloc - create a buffer to hold file contents
ReadFile - copy the contents of the file into the buffer
CloseHandle - close the file handle
At this point you'll have the file's binary data in your buffer. Do with it what you wish, just remember to free the memory associated with the buffer when you are done.
Each of the functions listed above is documented in the SDK help files and should be easy to follow. If you have further questions, post them here and I'll try to help.