Hello, What is the best practice on debugging a LOAD_CAB routine with MSP 3.3? I've made a simple CAB file change and now the dreaded -841 and cannot figure out where the fault lies. I can run the CAB manually just fine. Thanks Brad
Error [-841]// Expert user has replied. |
1 Replies
There is no reason that Error -841 should be "dreaded". Error -841 indicates that the install command failed. An install command typically Fails for one of two reasons: First, it can fail because the command could not be executed. This usually occurs because the .EXE you tried to run did not exist, either because the path or name was typed incorrectly, because you forgot to deploy it first, etc. Second, it can fail because the .EXE that was run returned a non-zero value. Any non-zero return value is interpreted as failure, but you can override that by using any of the following in front of the command: NOWAIT mypgm.exe // This doesn't wait for it to finish and hence ignores the return code WAITIGNORE mypgm.exe // This waits for it to finish then ignores the return INVERTRESULT mypgm.exe // This waits for it to return and considers 0 to mean failure If the .EXE you are launching is one you can't control the return code of, like wceload.exe, then you can use any of the above to prevent a non-zero return code from causing an Error -841. Of course, if the .EXE you are running does not return a code that tells you meaninfully whether it succeeded or failed, or if you choose to ignore its return code, then the Package may succeed whether the .EXE you ran succeeded or failed.