开发者

Windows installer does not fail when custom action returns an error

I am trying to modify a custom action of type 3137 and a .dll source (with say a target DWORD InstallFunction( MSIHANDLE hInstall )) to return some error codes in certain situation and I am expecting that window installer fails and prompt me with an error message or something.

However, when I do return an ERROR_INSTALL_USEREXIT code (or any error code in that matter) from the module that has been 开发者_如何学编程called, the installer completely ignores the returned value and proceeds to complete the installation as if nothing has happened.

How do I get the installer to fail as well? I am new to the whole windows installer API/concept so I would truly appreciate any advise.


The custom action has the msidbCustomActionTypeContinue flag set. Thus the installer ignores the return code. Removing this flag will solve the problem.

http://msdn.microsoft.com/en-us/library/windows/desktop/aa368071(v=VS.85).aspx

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜