Is user a member of the Administrators group

Sometimes it's important to know if application is running under account that is a member of the Administrators group. There're a few ways to accomplish that.

Obtaining DLL-specific version information

topic: 

Most Windows Shell and common controls DLLs implement DllGetVersion function. It allows applications to obtain DLL-specific version information to make sure that required functionality in a DLL is implemented. The Windows API support class

is used to handle Windows API structures.

Generate GUID

UDF below generates 128-bit GUID and returns it as a string in the format 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx'.

MSDN:

Creating directory preserving name case

MSDN:

File operations with Progressbar

It's based on the late Ed Rauh's code around SHFileOperation Win API and requires his Heap allocation class. It supports wild cards and shows standard Windows progress bar.

Windows limitations on file and path name

The limitations have been pulled from Windows SDK header file

Windows API support class

The class below simplifies use of Windows API function by providing methods to convert data between VFP types and Windows API types/structures

Using Sparse Files sample

Sparse files

are only supported under Windows 2000 and later and the file must be on a volume that is NTFS 5.0 or later.

Setting the Backup and Restore Privileges

topic: 

The backup and restore privileges are required of all backup and restore applications. These privileges can be programmatically set, and the following example can be used to set these privileges. Based on Setting the Backup and Restore Privileges

Pages