OK - try this.. Here's the script AND the UDF, all in one file.
1. Copy the following script
2. Paste into Notepad
3. Edit the line between the ; ===== headers to define a computer on your network that you have access to
4. Save as "DskInfo.kix"
5. Run as KIX32.EXE DSKINFO.KIX
You should get a report of each disk capacity. If you don't, check that the computer name is correct, and that you have access to the remote computer. You can verify by "DIR \\COMPUTER\C$"

The difference between this and the earlier version is that the UDF is included directly in the file, and not loaded from an external file.
I prefer this method, as it assures me the script will always work without reliance on external files. My KGen tool (Part of my KixDev product) assembles finished scripts in this manner, but automatically identifies which UDFs are required. I added a simple error check - if the call to the UDF doesn't return data, I display a message and exit.

Note that this example is very basic in terms of coding - vars are not declared, and vars/macros are permitted in strings. My emphasis was on providing a usable code SAMPLE, which demonstrates the capability. It's up to you to A) apply good coding process to your finished script, and B) wrap this logic in a loop to process many computers instead of just one.

That should provide you with a decent shove in the right direction, and enough stuff to do on your own to make it a worthwhile learning experience.

Regards,

Glenn

 Code:
Break On

; print the header
'Drv      Capacity           Free        <!>' ?

;=====================================================
; Define the name of your test computer
; (later, enumerate a list of computers in a loop)
$Computer = 'COMPUTER'
;=====================================================

; load the array from the computer
$aSysInfo = WMISysInfo($Computer)
If UBound($aSysInfo) = -1
  'Bad computer name or no access!' ? 
  Quit 1
EndIf

; Examine the disk drives & capacities
$D_Letters    = Split($aSysInfo[32], ',')
$D_Capacities = Split($aSysInfo[33], ',')
$D_FreeSpace  = Split($aSysInfo[34], ',')

For $Index = 0 to UBound($D_Letters)
  Left($D_Letters[$Index] + '               ', 4) ; 15 spaces between quotes
  Right('               ' + $D_Capacities[$Index], 15)
  Right('               ' + $D_FreeSpace[$Index], 15)
  If CDbl($D_FreeSpace[$Index]) < 500000
    '   <Low!>'
  EndIf
  ?
Next

; ==========================================================
; UDF Follows
; ==========================================================
;; 
;;====================================================================== 
;; 
;;FUNCTION       WMISysInfo() 
;; 
;;ACTION         Returns an array containing system information  
;;               from local or remote system 
;; 
;;AUTHOR         Glenn Barnas 
;; 
;;VERSION        1.0 / 2007/10/20 - First release 
;; 
;;SYNTAX         WMISysInfo([host] [,AuthPtr]) 
;; 
;;PARAMETERS     host    - OPTIONAL - name of system to query 
;; 
;;               AuthPtr - OPTIONAL - pre-authenticated WMI object pointer 
;;                 Use WMIAuthentication() udf to create the AuthPtr value 
;;                 AuthPtr is not needed if user has admin rights 
;; 
;;REMARKS        Replaced independent OSInfo and HWInfo UDFs 
;; 
;;RETURNS        40 element array 
;;               0   short/full operating system description 
;;               1   kernel description (Win2K, WinXP, Win2K3, Vista) 
;;               2   operating system role (workstation, member server, domain controller) 
;;               3   operating system service pack level 
;;               4   operating system build level 
;;               5   uni/multi-processor type 
;;               6   Computer Name 
;;               7   registered owner,organization 
;;               8   Serial Number 
;;               9   Install Date - YYYY/MM/DD hh:mm:ss 
;;               10  Local Date/Time  - YYYY/MM/DD hh:mm:ss 
;;               11  Last Boot Time - YYYY/MM/DD hh:mm:ss 
;;               12  TimeZone info (Std, Daylight, Bias) 
;;               13  Primary Domain Affiliation 
;;               14  Installed Hotfix list 
;;               15  OS Version (numeric) 
;;               16  Future Use 
;;               17  O/S Architecture 
;;               18  Install Method (Clean, Upgrade, SysPrep) 
;;               19  RAM/PageFile Info (location MinSize MaxSize) 
;;               20  System Brand 
;;               21  System Model 
;;               22  System S/N 
;;               23  System BIOS Revision 
;;               24  Processor Type 
;;               25  Processor Speed 
;;               26  Processor Count (Physical) 
;;               27  Processor Count (Logical) 
;;               28  Processor Cores 
;;               29  Physical Memory 
;;               30  Fixed-Disk Labels, null if none 
;;               31  Fixed-Disk Mount Point ("d:\" for drives, path for mounted volumes) (2K3 & higher) 
;;               32  Fixed-Disk Drives (A:-Z:, or "MV:" for mounted Volumes) 
;;               33  Fixed-Disk Capacities, bytes 
;;               34  Fixed-Disk FreeSpace, bytes 
;;               35  CD-ROM Disk List 
;;               36  Connected Network Drives 
;;               37  Hardware Architecture 
;;               38  Future Use 
;;               39  Future Use 
;; 
;;DEPENDENCIES   WMI support 
;; 
;;TESTED WITH    W2K, WXP, W2K3, Vista, X64 
;; 
;;EXAMPLES       $Host = '' 
;;               $aHWI = WMIHWInfo($Host) 
;;               $Host ' has ' $aHWI[6] ' Physical/Logical processors!' 
;; 
;;               $Host = 'server' 
;;               $objWMI = WMIAuthenticate('computer', 'userid', 'User-P@ss!') 
;;               $Up = WMIUptime($Host, $objWMI) 
;;               'Secure host ' $Host ' has been up for ' $Up[0] ' days!' 
; 
Function WMISysInfo(OPTIONAL $_Target, OPTIONAL $_pAuth)
 
 
  Dim $objWMIService, $colItems, $objItem		; WMI object vars 
  Dim $_SI[39]						; Var for return array 
  Dim $_, $_Delim, $_SRoot, $_WFile, $_OSVer
 
  $_Target = IIf($_Target, $_Target, '.')
  If InStr($_Target, '\') $_Target = Join(Split($_Target, '\'), '') EndIf
  If $_pAuth
    $objWMIService = $_pAuth
  Else
    $objWMIService = GetObject('winmgmts:{impersonationLevel=impersonate}!\\' + $_Target + '\root\cimv2')
    If @ERROR Exit Val('&' + Right(DecToHex(@ERROR), 4)) EndIf
  EndIf
 
 
; O/S SECTION		####################################################### 
 
  ; OperatingSystem	======================================================= 
  $colItems = $objWMIService.ExecQuery("Select * from Win32_OperatingSystem",,48)
  For Each $objItem in $colItems
    $_SRoot  = '\\' + $_Target + '\' + Join(Split($objItem.SystemDirectory, ':'), Chr(36)) + '\'
    $_SI[0]  = Trim(Split($objItem.Name, '|')[0])
    $_SI[15] = $objItem.Version
    $_       = _osid($_SI[0], $_SI[15])		; get kernel name, fix OS name 
    $_SI[0]  = $_[0]
    $_SI[1]  = $_[1]
    $_OSVer  = Trim(Join(Split($_SI[15], '.', 2), '.'))
    $_       = Split($objItem.CSDVersion, ' ')
    $_SI[3]  = $_[UBound($_)]
    $_SI[4]  = $objItem.BuildNumber
    $_SI[5]  = $objItem.BuildType
    $_SI[6]  = $objItem.CSName
    $_SI[7]  = $objItem.RegisteredUser + '/' + $objItem.Organization 
    $_SI[8]  = $objItem.SerialNumber
    ; Translate the following in to standard date strings (yyyy/mm/dd hh:mm:ss) 
    $_       = $objItem.InstallDate
    $_SI[9]  = Left($_, 4) + '/' + SubStr($_, 5, 2) + '/' + SubStr($_, 7, 2) + ' '
             + SubStr($_, 9, 2) + ':' + SubStr($_, 11, 2) + ':'  + SubStr($_, 13, 2)
    $_       = $objItem.LocalDateTime
    $_SI[10] = Left($_, 4) + '/' + SubStr($_, 5, 2) + '/' + SubStr($_, 7, 2) + ' '
            + SubStr($_, 9, 2) + ':' + SubStr($_, 11, 2) + ':'  + SubStr($_, 13, 2)
    $_       = $objItem.LastBootUpTime
    $_SI[11] = Left($_, 4) + '/' + SubStr($_, 5, 2) + '/' + SubStr($_, 7, 2) + ' '
            + SubStr($_, 9, 2) + ':' + SubStr($_, 11, 2) + ':'  + SubStr($_, 13, 2)
    $_       = $objItem.OSArchitecture
    $_SI[17] = IIf($_, $_, '32-bit')
  Next
  $colItems  = 0
 
  ; Time Zone		======================================================= 
  $colItems = $objWMIService.ExecQuery("Select * from Win32_TimeZone",,48)
  For Each $objItem in $colItems
    $_SI[12]  = $objItem.StandardName + ' / ' + $objItem.DaylightName + ' / ' + Abs($objItem.Bias) / 60
  Next
  $colItems  = 0
 
  ; Domain		======================================================= 
  $colItems = $objWMIService.ExecQuery("Select * from Win32_NTDomain",,48)
  For Each $objItem in $colItems
    $_SI[13]  = $objItem.DNSForestName + ',' + $objItem.DomainName
  Next
  $colItems  = 0
 
  ; Hotfixes		======================================================= 
  $colItems = $objWMIService.ExecQuery("Select * from Win32_QuickFixEngineering",,48)
  For Each $objItem in $colItems
    If InStr('KQ', Left($objItem.HotFixID, 1))
      $_SI[14]  = $_SI[14] + ' ' + $objItem.HotFixID
    EndIf
  Next
  $_SI[14] = SubStr($_SI[14], 2)	; trim result 
  $colItems  = 0
 
  ; PageFile		======================================================= 
  $colItems = $objWMIService.ExecQuery("Select * from Win32_PageFile",,48)
  For Each $objItem in $colItems
    $_SI[19] = $_SI[19] + ' ' + $objItem.EightDotThreeFileName + ' ' + $objItem.InitialSize + ' ' + $objItem.MaximumSize
  Next
  $colItems  = 0
 
  ; Check for build status 
  $_SI[18] = 'Clean'
  $_WFile = $_SRoot + Chr(36) + 'winnt' + Chr(36) + '.inf'
  If Exist($_WFile)
    If ReadProfileString($_WFile, 'Data', 'StandardServerUpgrade') = 'yes' Or
       ReadProfileString($_WFile, 'Data', 'WinNtUpgrade') = 'yes'
      $_SI[18] = 'Upgrade'
    EndIf
    If ReadProfileString($_WFile, 'Unattended', 'InstallFilesPath')
      $_SI[18] = 'SysPrep'
    EndIf
  EndIf 
 
 
; HARDWARE SECTION	####################################################### 
 
 
  ; ComputerSystem	======================================================= 
  $colItems = $objWMIService.ExecQuery("Select * from Win32_ComputerSystem",,48)
  For Each $objItem in $colItems
    $_ = 'Standalone Workstation', 'Member Workstation', 'Standalone Server', 'Member Server', 'Backup Domain Controller', 'Primary Domain Controller'
    $_SI[2]   = $_[Val($objItem.DomainRole)]
    $_SI[37]  = Left($objItem.SystemType, 3)
    $_SI[20]  = $objItem.Manufacturer
    $_SI[21]  = $objItem.Model
    $_SI[26]  = $objItem.NumberOfProcessors
    $_SI[29]  = $objItem.TotalPhysicalMemory
    $_        = CInt((CDbl($_SI[29]) + 655360.0) / 1048576.0)
    $_SI[19]  = '' + $_ + $_SI[19]
  Next
  $colItems  = 0
 
  ; BIOS		======================================================= 
  $colItems = $objWMIService.ExecQuery("Select * from Win32_BIOS",,48)
  For Each $objItem in $colItems
    $_SI[22]  = $objItem.SerialNumber
    $_Delim = ''
    For Each $_ in $objItem.BIOSVersion
      $_SI[23] = $_SI[23] + $_Delim + $_
      $_Delim = ','
    Next
  Next
  $colItems  = 0
 
  ; Processor		======================================================= 
  $colItems = $objWMIService.ExecQuery("Select * from Win32_Processor",,48)
  For Each $objItem in $colItems
    $_SI[24]  = Trim($objItem.Name)
    $_SI[25]  = $objItem.MaxClockSpeed
    $_SI[27]  = $objItem.NumberOfLogicalProcessors
    $_SI[28]  = $objItem.NumberOfCores
  Next
  $colItems  = 0
 
  ; Disk Storage	======================================================= 
  $colItems = $objWMIService.ExecQuery("Select * from Win32_LogicalDisk",,48)
  For Each $objItem in $colItems
    If $objItem.DriveType = 3	; fixed disk 
      $_SI[30]  = $_SI[30] + ',' + $objItem.VolumeName
      $_SI[31]  = $_SI[31] + ',' + $objItem.Caption + '\'
      $_SI[32]  = $_SI[32] + ',' + $objItem.Caption
      $_SI[33]  = $_SI[33] + ',' + $objItem.Size
      $_SI[34]  = $_SI[34] + ',' + $objItem.FreeSpace
    EndIf
    If $objItem.DriveType = 5	; CD-ROM 
      $_SI[35]  = $_SI[35] + ',' + $objItem.Caption
    EndIf
    If $objItem.DriveType = 4	; Network Drive 
      $_SI[36]  = $_SI[36] + ',' + $objItem.Caption + '=' + $objItem.ProviderName
    EndIf
  Next
  $colItems  = 0
  If $_OSVer > 5.1 ; only supported on W2K3 and higher - return mounted volume info 
    $colItems = $objWMIService.ExecQuery("Select * from Win32_Volume",,48)
    For Each $objItem in $colItems
      If $objItem.DriveType = 3	And $objItem.DriveLetter = ''
        $_SI[30]  = $_SI[30] + ',' + $objItem.Label
        $_SI[31]  = $_SI[31] + ',' + $objItem.Caption
        $_SI[32]  = $_SI[32] + ',' + 'MV:'
        $_SI[33]  = $_SI[33] + ',' + $objItem.Capacity
        $_SI[34]  = $_SI[34] + ',' + $objItem.FreeSpace
      EndIf
    Next
  EndIf
  $colItems  = 0
 
  ; trim leading "," from strings 
  For $_ = 30 to 36
    $_SI[$_] = SubStr($_SI[$_], 2)
  Next
 
  ; Return the array 
  $WMISysInfo= $_SI
  Exit 0
 
EndFunction
 
 
; _osid - supporting function 
; Identifies the release version (beta, RTM, Preview, etc), defines a "kernel short name", 
; and removes special characters from the description string 
Function _osid($_Vs, $_Vn)
 
  Dim $_
  Dim $_Srel			; string of release IDs 
  Dim $_Vmaj			; Major version number 
  Dim $_Vmin			; Minor version number 
  Dim $_Vrel			; Release number 
  Dim $_aR[1]			; Short (KernelID) name, Descriptive Name 
 
  $_ = Split($_Vn + '.0.0', '.', 3)
  $_Vmaj = Val($_[0])
  $_Vmin = Val($_[1])
  $_Vrel = $_[2]
 
  ; clean up the O/S description string - remove special chars 
  $_Vs = Join(Split($_Vs, Chr(153)), '')	; (tm) 
  $_Vs = Join(Split($_Vs, Chr(169)), '')	; (c) 
  $_Vs = Join(Split($_Vs, Chr(174)), '')	; (r) 
 
  Select
   Case $_Vmaj = 5 And $_Vmin = 0	; Win2K 
    $_aR[1] = 'Win2K'
    $_Srel = '1515=(Beta 2),2031=(Beta 3),2183=(Beta 3),2128=(Beta 3 RC2),2195=(RTM)'
    $_ = InStr($_Srel, $_VRel)
    If $_
      $_ = Split(SubStr($_Srel, $_ + 5), ',')[0]
      $_Vs = $_Vs + ' ' + $_
    EndIf
   Case $_Vmaj = 5 And $_Vmin = 1	; WinXP 
    $_aR[1] = 'WinXP'
    $_Srel = '2505=(RC1),2600=(RTM)'
    $_ = InStr($_Srel, $_VRel)
    If $_
      $_ = Split(SubStr($_Srel, $_ + 5), ',')[0]
      $_Vs = $_Vs + ' ' + $_
    EndIf
   Case $_Vmaj = 5 And $_Vmin = 2	; Win2K3 
    $_aR[1] = 'Win2K3'
    $_Srel = '3718=(Eval),3790=(RTM)'
    $_ = InStr($_Srel, $_VRel)
    If $_
      $_ = Split(SubStr($_Srel, $_ + 5), ',')[0]
      $_Vs = $_Vs + ' ' + $_
    EndIf
   Case $_Vmaj = 6 And $_Vmin = 0	; Vista 
    $_aR[1] = 'Vista'
    $_Srel = '6000=(RTM)'
    $_ = InStr($_Srel, $_VRel)
    If $_
      $_ = Split(SubStr($_Srel, $_ + 5), ',')[0]
      $_Vs = $_Vs + ' ' + $_
    EndIf
   Case 1
    $_aR[1] = 'Unknown'
  EndSelect
 
  $_aR[0] = $_Vs
 
  $_osid = $_aR
 
EndFunction
_________________________
Actually I am a Rocket Scientist! \:D