Well, Windows doesn't allow access to raw sectors anymore. You can still access the logical sectors, btw. What you have to do is use CreateFile and the DeviceIoControl functions to access the drive and partition table (and other data) of a drive, in a reasonable safe way. (Until you start writing data.) As filename you would use e.g. '\\.\A:' and that should give you access to the drive. With DeviceIoControl you will have more control over the drive and it's many additional functions.
Be aware: Writing data to this 'file' will be hazardous to your harddisk if you write the wrong thing. Use at your own risk! One mistake and you can start installing Windows on your system again from scratch... (If your harddisk is still alive.)
Main Topics
Browse All Topics





by: Programmer-xPosted on 2006-08-13 at 05:53:59ID: 17305114
Hi!
n.htm
I think you should write some In-Line assembly codes to set direct access to disk sectors...
take a look at Interrupts at 13xx ... some Ints for disk I/O
Ralf Brown Interrupt List =>
http://www.ctyme.com/rbrow
~HRV