Archive: The hard disk is full when we are installing the application.


The hard disk is full when we are installing the application.
Hi Everyone,

I am using NSIS to write the installer and I need to handle the case when the installing the application, the disk is full (ex. When you do the installing and copying some big files to the disk, the disk is full although before installing it still has enough volume). How can we know the disk is full when installing and display a messgage.

Thanks,
Hien


StrCpy $1 $INSTDIR 2
System::Call 'kernel32::GetDiskFreeSpaceEx(t, *l, *l, *l)i(r1,.r2,.,.) .r3'

If $3 does not equal 0, $2 contains the number of free bytes. See msdn.microsoft.com/en-us/library/aa364937(VS.85).aspx for details.