Several Windows Embedded CE API's deal with handles: an application obtains a handle to an object than it typically checks if the handle is valid or not; unfortunately there are two values which means invalid handle: for example CreateFile returns INVALID_HANDLE_VALUE (which is defined as -1 or 0xFFFFFFFF) while CreateEvent returns NULL. A mnemonic aid is the following: all the API's that deal with files, storage and database (CreateFile, FindFirstChangeNotification, OpenStore, CeOpenDatabaseEx,...