About Disk Prompting and Error Handling
Though the setup functions do not provide a user interface, there are four setup functions that generate dialog boxes to handle common installation situations and gather information from the user. These are: SetupPromptForDisk, SetupCopyError, SetupRenameError, and SetupDeleteError.
Callback routines can call these functions to create dialog boxes to aid in processing notifications sent by other setup functions such as SetupCommitFileQueue and SetupInstallFile.
The SetupPromptForDisk function prompts the user to insert removable media, specify a new source path, or cancel the installation. The application can offer additional options to the user, depending on the flags specified when the function is called. These include skipping the current file, or browsing for a new source path.
The three functions, SetupCopyError, SetupRenameError, and SetupDeleteError, create dialog boxes that interact with the user to gather information from the user on how to proceed when an error has occurred.
The SetupCopyError function generates a dialog box that asks the user how to recover from a copy error. The user can specify a new source path for the copy operation or cancel the installation. Depending on the flags specified during the call to SetupCopyError, the user may also be able to browse for a new source path, view error details, or skip the current file.
A dialog box that asks the user how to process errors that occur during a file renaming operation can be generated by calling SetupRenameError. With this dialog box, the user has the opportunity to retry the operation, skip the current rename operation, or abort.
The SetupDeleteError function generates a dialog box that can gather input on how the user wishes to handle an error that occurred during a file deletion operation. The user is given the options to retry the operation, skip the current delete operation, or abort.
The default queue callback routine, SetupDefaultQueueCallback, uses the previously mentioned four functions to generate parts of its user interface and to handle errors and prompt for new media.