quota script for windows XP

Hi

I am Samba server which is working as a domain log on server for winxp client and user home directories are assigned 100MB quota on the linux drive.

I am trying to get below script working so that user gets informed of his disk space usage.

dim oFS, oFolder
set oFS = WScript.CreateObject("Scripting.FileSystemObject")
set oFolder = oFS.GetFolder("H:\")

Set objWMIService = GetObject("winmgmts:")
Set objLogicalDisk = objWMIService.Get("Win32_LogicalDisk.DeviceID='H:'")
Wscript.Echo "Space Used=" & int(oFolder.Size /1048576) & " MB" & vbCr & _ 
"Allowed Space: " & Int(objLogicalDisk.Size /1048576) & " MB"

Only problem with above script is that it shows space used less than what is actually used.

For example if user has consumed 28.8 MB out of 100 MB (I got this info by using right clicking the properties for user's home drive : 'H'). However, the script reports 24 MB space used. :confused:

Can anyone please help me with this script so that script shows the correct space used.

Thanks!:b: