Archive: Error opening file for writing


Error opening file for writing
Hello all,

I am seeing "error opening file for writing" randomly on some of the 64 bit Windows 7 and Vista for one of the dll. Not sure why it only happens randomly.

Here is how I have it:

-----
; at the beginning
RequestExecutionLevel user

; .onInit section
UAC plugin

; Install section
${If} Running_64
ExecWait '"$SYSDIR\regsvr32.exe" /s "$INSTDIR\Namespace.x64.dll"'
ExecWait '"$WINDIR\SysWOW64\regsvr32.exe" /s "$INSTDIR\Namespace.x86.dll"'
${Else}
ExecWait '"$SYSDIR\regsvr32.exe" /s "$INSTDIR\Namespace.x86.dll"'
${EndIf}

------

Many thanks!


'Error opening file for writing' appears only when a file couldnot be overwritten. You may use the code "SetOverWrite try".