Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Manipulate ULARGE_INTEGER

0 views
Skip to first unread message

Jean-Michel VANSTEENE

unread,
Feb 26, 1998, 3:00:00 AM2/26/98
to

Do you know how to manipulate ULARGE_INTEGER that
contains the free disk space (after a call to GetDiskFreeSpaceEx.

I just want to display the value in KB.

Thank you.

--
*--* mailto:Jean-Miche...@bull.net (Bull)
*--* mailto:van...@worldnet.fr (Home)
*--* http://www.worldnet.fr/~vanstee (Jean GABIN)
-------------------------------------------------------------
Do you know another word for synomym?

ScottMcP

unread,
Feb 26, 1998, 3:00:00 AM2/26/98
to

ULARGE_INTEGER SectorsPerCluster;
ULARGE_INTEGER BytesPerSector;
ULARGE_INTEGER NumberOfFreeClusters;
ULARGE_INTEGER TotalNumberOfClusters;
ULARGE_INTEGER temp;
SectorsPerCluster.HighPart = 0;
BytesPerSector.HighPart = 0;
NumberOfFreeClusters.HighPart = 0;
TotalNumberOfClusters.HighPart = 0;
GetDiskFreeSpace(
czRootDirectory,
&SectorsPerCluster.LowPart,
&BytesPerSector.LowPart,
&NumberOfFreeClusters.LowPart,
&TotalNumberOfClusters.LowPart);

temp.QuadPart = (SectorsPerCluster.QuadPart * BytesPerSector.QuadPart *
TotalNumberOfClusters.QuadPart) >> 20;
ULONG TotalMB = temp.LowPart;

Martin Maat

unread,
Feb 28, 1998, 3:00:00 AM2/28/98
to

Jean-Michel VANSTEENE wrote in message <34F57DCC...@bull.net>...

> Do you know how to manipulate ULARGE_INTEGER that
> contains the free disk space (after a call to GetDiskFreeSpaceEx.
> I just want to display the value in KB.

The type ULARGE_INTEGER has some handy members like QuadPart, which returns
a 64-bit DWORDLONG that can be used in calculations.

> Do you know another word for synomym?

The word is synonym and another word for it would be equivalent.

Martin.


0 new messages