Is it by design that setup.exe throws a dialog box when you run an install with
the /quiet option and an error occurs (say trying to run a 64bit install on a
32bit system)? I have changed this functionality locally with this simple
change:
case ERROR_UNKNOWN_PRODUCT:
case ERROR_INSTALL_PACKAGE_REJECTED:
case ERROR_CREATE_FAILED:
case ERROR_INSTALL_PLATFORM_UNSUPPORTED:
if (dwUiLevel != INSTALLUILEVEL_NONE)
{
cchErrorMessage = ::FormatMessageW(FORMAT_MESSAGE_ALLOCATE_BUFFER |
FORMAT_MESSAGE_FROM_SYSTEM, NULL, hr, MAKELANGID(LANG_NEUTRAL,
SUBLANG_DEFAULT), (LPWSTR)&pvErrorMessage, 0, NULL);
if (0 < cchErrorMessage)
{
::MessageBoxExW(NULL, static_cast<PCWSTR>(pvErrorMessage),
L"Install Error", MB_ICONERROR | MB_OK, 0);
}
}
break;
default:
if (dwUiLevel != INSTALLUILEVEL_NONE)
{
cchErrorMessage = ::FormatMessageW(FORMAT_MESSAGE_ALLOCATE_BUFFER |
FORMAT_MESSAGE_FROM_SYSTEM, NULL, HRESULT_FROM_WIN32(ERROR_PROCESS_ABORTED),
MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), (LPWSTR)&pvErrorMessage, 0, NULL);
if (0 < cchErrorMessage)
{
::MessageBoxExW(NULL, static_cast<PCWSTR>(pvErrorMessage), L"Install
Error", MB_ICONERROR | MB_OK, 0);
}
}
break;
}
Now I see in ProcessSetupChain where ConfigMsi is called there is a parameter
to ignore errors based on pPackage->dwAttributes &
SETUP_INSTALL_CHAIN_PATCH_FORCE_TARGET, but I don't know if or if I would want
that attribute set for an Msi in all situations.
Seems the above change fits given that the error code should still log if a
mass deployment is using the /quiet option.
Nik Twerdochlib
Software Developer
BOMGAR | The Box That's Revolutionizing Remote Support(tm)
One of the Fastest-Growing Technology Companies in America | Technology Fast
500(tm)
What is Bomgar? Find out in 154 seconds<http://www.bomgar.com/overview>.
------------------------------------------------------------------------------
Minimize network downtime and maximize team effectiveness.
Reduce network management and security costs.Learn how to hire
the most talented Cisco Certified professionals. Visit the
Employer Resources Portal
http://www.cisco.com/web/learning/employer_resources/index.html
_______________________________________________
WiX-devs mailing list
WiX-devs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-devs