Click here to Skip to main content
15,887,346 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Display Huge Size file content in dialog Pin
«_Superman_»14-Feb-10 22:25
professional«_Superman_»14-Feb-10 22:25 
GeneralRe: Display Huge Size file content in dialog Pin
Prabhu09200914-Feb-10 22:37
Prabhu09200914-Feb-10 22:37 
GeneralRe: Display Huge Size file content in dialog Pin
«_Superman_»14-Feb-10 22:48
professional«_Superman_»14-Feb-10 22:48 
NewsRe: Display Huge Size file content in dialog Pin
Prabhu09200915-Feb-10 0:48
Prabhu09200915-Feb-10 0:48 
GeneralRe: Display Huge Size file content in dialog Pin
Maximilien15-Feb-10 1:28
Maximilien15-Feb-10 1:28 
GeneralRe: Display Huge Size file content in dialog Pin
Rajesh R Subramanian15-Feb-10 1:41
professionalRajesh R Subramanian15-Feb-10 1:41 
QuestionRe: Display Huge Size file content in dialog Pin
CPallini14-Feb-10 22:55
mveCPallini14-Feb-10 22:55 
QuestionWrong partion info for Dynamic disk using DeviceIoControl Pin
MKC00214-Feb-10 22:03
MKC00214-Feb-10 22:03 
DeviceIoControl with IOCTL_DISK_GET_DRIVE_LAYOUT parameter does not returns correct values for drives in dynamic disk. For basic disk all values are correct.

DWORD i;
HANDLE handle = CreateFile("\\.\PhysicalDrive0", ,GENERIC_READ,FILE_SHARE_READ|FILE_SHARE_WRITE,0,OPEN_EXISTING,0,0);

DRIVE_LAYOUT_INFORMATION *drive_layout;

int buf_size = sizeof(DRIVE_LAYOUT_INFORMATION) + 8* sizeof(PARTITION_INFORMATION);
DeviceIoControl(handle,IOCTL_DISK_GET_DRIVE_LAYOUT,NULL,0,(BYTE*)drive_layout,buf_size,&i,NULL);

for (i = 0; i < drive_layout->PartitionCount; i++)
{
PARTITION_INFORMATION * partinfo = &drive_layout->PartitionEntry[i];
// PARTITION_INFORMATION keeps starting offset, drive size and hidden sectors for any drive. and i can get all using partinfo pointer.
}

If i have a disk of 80 gb size. Suppose First drive (C:/) start at sector 63 and size is 20 gb, then second drive (d:/) start at offset 40 gb and size is 20 gb then above function returns 20 gb as start offset for second drive. While the correct value is 40 gb. (In this disk offset from 20 gb to 40 gb is free and it has no partition).

I also tried to open second drive (CreateFile("\\.\d:",..) and call DeviceIoControl with IOCTL_VOLUME_GET_VOLUME_DISK_EXTENTS parameter but it does not returns correct value for starting offset and drive size.

Please suggest.
QuestionReading a CSV file Pin
Pryabu14-Feb-10 21:56
Pryabu14-Feb-10 21:56 
AnswerRe: Reading a CSV file Pin
«_Superman_»14-Feb-10 22:03
professional«_Superman_»14-Feb-10 22:03 
GeneralRe: Reading a CSV file Pin
Pryabu14-Feb-10 22:15
Pryabu14-Feb-10 22:15 
AnswerRe: Reading a CSV file Pin
Rolf Kristensen18-Feb-10 10:57
Rolf Kristensen18-Feb-10 10:57 
QuestionSending values to WPF control from VC++ Pin
Anu_Bala14-Feb-10 19:58
Anu_Bala14-Feb-10 19:58 
AnswerRe: Sending values to WPF control from VC++ Pin
CPallini14-Feb-10 21:30
mveCPallini14-Feb-10 21:30 
QuestionRun copy command in the background using vc++ Pin
raj157614-Feb-10 18:17
raj157614-Feb-10 18:17 
AnswerRe: Run copy command in the background using vc++ Pin
«_Superman_»14-Feb-10 18:45
professional«_Superman_»14-Feb-10 18:45 
GeneralRe: Run copy command in the background using vc++ Pin
raj157614-Feb-10 19:21
raj157614-Feb-10 19:21 
GeneralRe: Run copy command in the background using vc++ Pin
«_Superman_»14-Feb-10 19:32
professional«_Superman_»14-Feb-10 19:32 
GeneralRe: Run copy command in the background using vc++ Pin
raj157614-Feb-10 20:25
raj157614-Feb-10 20:25 
GeneralRe: Run copy command in the background using vc++ Pin
«_Superman_»14-Feb-10 20:32
professional«_Superman_»14-Feb-10 20:32 
GeneralRe: Run copy command in the background using vc++ Pin
David Crow15-Feb-10 4:27
David Crow15-Feb-10 4:27 
AnswerRe: Run copy command in the background using vc++ Pin
Adam Roderick J14-Feb-10 19:44
Adam Roderick J14-Feb-10 19:44 
GeneralRe: Run copy command in the background using vc++ Pin
raj157614-Feb-10 23:11
raj157614-Feb-10 23:11 
AnswerRe: Run copy command in the background using vc++ Pin
Maximilien15-Feb-10 1:35
Maximilien15-Feb-10 1:35 
GeneralRe: Run copy command in the background using vc++ Pin
David Crow15-Feb-10 4:29
David Crow15-Feb-10 4:29 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.