When I compiled a project in Visual Studio I had the following error: Unable to Write to Output File … System Error &H80004005&
Its not an error message which one would associate with missing files. However, looking around on the Internet this is given as one of the options. Anther option is that another user or project has access to a file and consequently there is a lock on it.
Despite the error message, a likely answer to my error was to locate a missing file. I had previously excluded a number of files from the project, having copied them into a related project. I added the original copies back into the project a couple at a time but the compilation error remained. Once all of the files were back into the project I was looking for the error to clear. the error message No. &H80004005& remained.
In the Solution Explorer I turned on the Show All Files option and scanned down through the list looking for the item with an exclamation mark in a yellow triangle against it.
I had deleted a designer file from the directory. I usually add controls into the ascx.vb (or .cs) file manually rather than letting the designer do this for me. Whilst tidying up the code I deleted the file, following the pasting of the remaining control references into its associated file.
I right clicked on the file and selected the option to permanently delete the file. I was given a confirmation to proceed which I did. I was pleasantly surprised that there was no grumble, given that the file didn’t exist.
Recompiling the project then proceeded without any issues. I then excluded the files which I had previously done as a part of the tidy-up.


