c# - Wix bootstrapper How to prevent rollback -
i know if there way prevent rollback when package fail.
like in case have .bat package sets user name , password services. , if fails, want show message @ end of installation telling user need set credential manually. when check credential before installation, , reason failed tell user credential wrong , ask him if wants continue.
(else wouldn't want prevent rollback)
i know there <exitcode/>
in <exepackage/>
can use prevent rollback, can't detect error value in bootstrapper.
i tried read status in bootstrapper when package complete , return 1 of following:
e.result = result.continue; e.result = result.ignore; e.result = result.ok;
exemple of reading status:
if (e.status == -2147024895) { e.result = result.continue; }
but still rollsback.
i got answer here: http://lists.wixtoolset.org/pipermail/wix-users-wixtoolset.org/
basically, need set package want handle return code vital='no'
, in executepackagecomplete
handler use e.result = result.ignore;
prevent rollback.
Comments
Post a Comment