I have found this function GetFileSizeEx(), which returns the size of file in PLARGE_INTEGER that is formed by the union of structures.
typedef union _LARGE_INTEGER {
  struct {
    DWORD LowPart;
    LONG  HighPart;
  } ;
  struct {
    DWORD LowPart;
    LONG  HighPart;
  } u;
  LONGLONG QuadPart;
} LARGE_INTEGER, *PLARGE_INTEGER;
Is it same as if I'd call it structure of structures? How can I figure the file size that it has returned and how large information can it handle?
You are probably misunderstanding what a union is.  A file's length is obtained by
LARGE_INTEGER  len_li;
GetFileSizeEx (hFile, &len_li);
int64 len = (len_li.u.HighPart << 32) | len_li.u.LowPart;
Alternatively, you can access the 64 bit representation directly with modern compilers:
LARGE_INTEGER  len_li;
GetFileSizeEx (hFile, &len_li);
LONGLONG  len_ll = len_li.QuadPart;
                        If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With