Determine Invalid Characters in File Name and Path

This is sample code. Add error handling and adjust to your requirements as necessary.

Detect Multiple Monitors

The GetSystemMetrics WIN API can be used to get the number of monitors. Some other constants related to multi-monitor PC configurations are also included.

CRC16 - Polynom 0x8005

Relevant links: http://www.summitinstruments.com/knowledge_center/pdf/TN410.pdf http://www.lammertbies.nl/comm/info/crc-calculation.html?crc=1234567898765421&method=ascii

Copy, Move, Rename File Preserving Destination Name Case

The CopyFile() and MoveFile() WIN API functions preserve the case of the name for the destination file. Alternatively, WSH can be used. The source and destination file names should include the directory name in both cases.
Note 1 A Copy operation will not change file name case when destination file already exists (overwritten).
Note 2 The WinApiErrMsg is used to retrieve Windows API error message in case of error.

Copy Command Window Selected Text to Clipboard Programmatically

The code uses Editor functions from Foxtools.fll. See George Tasker's Extended Foxtools Help Download #9333 on UT for more info.

Converting ADO Recordset to Cursor with CursorAdapter

CursorAdapter can easily convert ADO recordset into a VFP cursor. It does not support conversion in opposite direction.

Pages