D
DT
Does the .NET Framework have direct support for NTFS5 sparse files?
(something equivalent to Win32 DeviceIoControl with FSCTL_SET_PARSE)
For example, what's the .NET equivalent of this Win32 example:
HANDLE h = CreateFile("A huge file.txt",
GENERIC_WRITE, 0, NULL,
CREATE_ALWAYS, 0, NULL);
DWORD dw;
DeviceIoControl(h, FSCTL_SET_SPARSE, NULL,
0, NULL, 0, &dw, NULL);
LONG lDist = 8; // 32 GB!!!
SetFilePointer(h, 0, &lDist, FILE_BEGIN);
SetEndOfFile(h);
CloseHandle(h);
....or if I have to pinvoke the above Win32 from .NET, what's the .NET
declarations I need?
Thanks,
DT
(something equivalent to Win32 DeviceIoControl with FSCTL_SET_PARSE)
For example, what's the .NET equivalent of this Win32 example:
HANDLE h = CreateFile("A huge file.txt",
GENERIC_WRITE, 0, NULL,
CREATE_ALWAYS, 0, NULL);
DWORD dw;
DeviceIoControl(h, FSCTL_SET_SPARSE, NULL,
0, NULL, 0, &dw, NULL);
LONG lDist = 8; // 32 GB!!!
SetFilePointer(h, 0, &lDist, FILE_BEGIN);
SetEndOfFile(h);
CloseHandle(h);
....or if I have to pinvoke the above Win32 from .NET, what's the .NET
declarations I need?
Thanks,
DT