PDA

View Full Version : How to install different run.exe based on IE version



faintboy
04-04-2002, 09:57 PM
we want install different run.exe to taget machine based on the IE version on the taget machine.For example:
If IE 4.0,install runa.exe;
if IE 5.0,install runb.exe.

How to do this?

Can you supply script file?

Thank you very much

Martin R.
04-05-2002, 12:03 AM
with a custom action check with IE is installed..
set a property.. eg: IEVER=4 or IEVER=5..
make 2 components, which have runa and runb..
both must have a condition, namely IEVER=4 or IEVER=5
Hope that helps and works..

Martin R.
04-05-2002, 12:13 AM
following code was for msaccess, but i quickly changed it toto iexplorer.. check it out

#define REG_IEXPLOREAPPPATH "Software\\Microsoft\\Windows\\CurrentVersion\\App Paths\\IExplore.exe"

function CheckForApp(hMSI)
string svValue, svVersionNumber, sVerMajor, sTemp;
number nvType, nvSize;
begin
sTemp = "";
RegDBSetDefaultRoot(HKEY_LOCAL_MACHINE);
if (RegDBGetKeyValueEx(REG_IEXPLOREAPPPATH, "", nvType, svValue, nvSize) == 0) then
// Found something, need version
VerGetFileVersion(svValue, svVersionNumber);
//StrSub(sVerMajor, svVersionNumber, 0, 2);
SprintfBox(INFORMATION, "Information", "MS IExplore %s found!", svVersionNumber);
//MessageBox("found access", INFORMATION);
else
MessageBox("No IExplore found!", INFORMATION);
endif;
//return sTemp;

end;

faintboy
04-05-2002, 02:44 AM
I know how to detect IE Version but how to install different run.exe

Martin R.
04-05-2002, 02:51 AM
well, as I said: make 2 components..

component one:
file one
condintion: iever=4

component two:
file two
condition: iever=5

no extra code necessary!!!