Based on these posts,
Writing binary file in Inno Setup
Inno Setup: Reading a file from installer during uninstallation
What is the full code to embed the Bitmap image data into Inno Setup during compile and retrieve it during the installation?
This is required during uninstall process. Because this code does not work at uninstall:
ExtractTemporaryFile('myimage.bmp');
The file cannot be copied during the installation. It should be only retrieved during uninstallation.