Update 2
--------

Minor bug fix, plus a plethora of new features.


BUG FIXES

Fixed bug in Registry.EnumerateValues when there are no values to enumerate.


clsWindowsXP
------------

EmptyRecycleBin()
xp.EmptyRecycleBin
Empties the recycle bin. Will display an automatic progress meter if operation takes long enough to merit one.

OpenURL()
xp.OpenURL "www.vbforums.com"
Opens the specified URL in the default browser.

ShowOpenDialog()
strFile = xp.ShowOpenDialog(strUserMusic, "Audio Files (*.mp3)|*.mp3", "mp3")
Displays the Open File common dialog, returning either the file selected or an empty string if the user cancels. Supports multiple extensions; separate each valid extension (and description) with the pipe (|) character.

ShowSaveAsDialog()
strFile = xp.ShowSaveAsDialog(strFolder, strFile, "Audio Files (*.mp3)|*.mp3", "mp3")
Displays the Save File common dialog, returning either the file selected or an empty string if the user cancels. Supports multiple extensions; separate each valid extension (and description) with the pipe (|) character.

ShutDownWindows()
xp.ShutDownWindows [Reboot] [Force]
Not written by me, and unfortunately the code is so old I've lost track of where I originally found it so I can't offer proper credit. Can either Shutdown or Restart, and can optionally force the action if processes are busy.

SystemColorRGB()
lngColor = xp.SystemColorRGB(vbButtonFace)
System color values are dependent on user settings. Use this function to translate any system color to its resultant color value.


clsDrive
--------

FormatSize()
strSize = xp.File.FormatSize(curSize)
Returns a formatted string description of the specified (currency) size. This string is formatted the same way as displayed in the Explorer status bar. (eg: 37 bytes, 63.2 KB, 123 KB, 64.2 MB, 153 MB, 4.22 GB)

GetDriveSpace()
xp.Drive.GetDriveSpace("C:", curTotal, curFree, curUsed)
Retrieves all three drive space statistics (Total, Free, Used) in a single operation. Send three currency variables to be filled in by reference. Use the FormatSize() function to convert these values for display.

GetFreeSpace()
curFree = xp.Drive.GetFreeSpace("C:")
Returns the free space on the specified drive. Use the FormatSize() function to convert the value for display.

GetTotalSpace()
curFree = xp.Drive.GetTotalSpace("C:")
Returns the total space on the specified drive. Use the FormatSize() function to convert the value for display.

GetUsedSpace()
curFree = xp.Drive.GetUsedSpace("C:")
Returns the used space on the specified drive. Use the FormatSize() function to convert the value for display.


clsFile
-------

GetType()
strType = xp.File.GetType(File)
Returns the text description of a file type based on its extension. This is the same text that is displayed in the Type column of Windows Explorer when in Details view.

LoadToString()
strText = xp.File.LoadToString(File)
Returns the entire contents of text file in a single string.

MakeNameDOS()
strFilename = xp.File.MakeNameDOS(strFilename)
Strips invalid DOS characters, replacing them with similar valid characters. For example, colons (:) are converted to dashes (-).

MakeNameUnique()
strFilename = xp.File.MakeNameUnique(strFilename)
Returns a unique filename by adding an incremental suffix if the files already exists. For example: "C:\Text.txt", "C:\Text_a.txt", "C:\Text_b.txt"

RunAs()
xp.File.RunAs File, Ext[, DefaultFolder]
Runs a file using the application associated with a different extension.


clsFolder
---------

GetDatetime()
xp.Folder.GetDatetime strFolder, dtmCreated, dtmModified, dtmAccess
Retrieves all three folder dates (Created, Modified, Access) in a single operation. Send three date variables to be filled in by reference.

MakeNameUnique()
strFolder = xp.Folder.MakeNameUnique(strFolder)
Returns a unique folder name by adding an incremental suffix if the folder already exists. For example: "C:\Temp", "C:\Temp_a", "C:\Temp_b"

SPECIAL FOLDERS

strFolder = xp.Folder.CDBurnArea


clsRegistry
-----------

ReadStringArray()
xp.Registry.ReadStringArray Key, Value, StringArray[, Root]
Similar to the standard ReadValue functions, reads a string array instead of a single string.

ReadStringEnviron()
strExpanded = xp.Registry.ReadStringEnviron(Key, Value, Default[, Root])
Some registry strings contain environment variables that need to be expanded. Retrieves them in expanded form.

WriteStringArray()
xp.Registry.WriteStringArray Key, Value, StringArray[, Root]
Companion to ReadStringArray function, writes a string array to the registry. 

WriteStringEnviron()
xp.Registry.WriteStringEnviron(Key, Value, String[, Root])
Companion to ReadStringEnviron.