Control registry operations in Windows and .NET applications

Error reporting and handling

If your application needs to report some error when processing the callback, it should throw ECBRegError exception. The application must pass the error code with the exception by passing the error code as a parameter to ECBRegError constructor.

Use the error codes, defined by Win32 API, when throwing the exception. These error codes are listed in WinError.h header file in Windows Platform SDK. CallbackRegistry API will catch ECBRegError exception and extract the error code. The error code will be reported to the operating system. The original request will not be passed further to the registry.

If some exception occurs when the callback is executed and your code doesn't handle this exception in a graceful manner, CallbackRegistry API will catch it for you and the original request will be passed further to the underlying file system..

Back to top