This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- HOW to Validate with JRE JAVA RUNTIME ENVIRONMENT
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Feb 22, 2009
10:54 PM
HOW to Validate with JRE JAVA RUNTIME ENVIRONMENT
HI
ALL
I am new to Installshield , i am using macrovision Installshield 2008
can any one plese let me know that how i have to authintace the system that JRE 1.6 or higher is installed on machine
as i tried with Registry
HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Runtime Environment\CurrentVersion
but i am not able to check for JRE condition through
1.Create Customer sofware condition
2.CHECK FOR REGISTRY
3.I am STUCK IN CONDITION BUILDER
so please any one let me know whats the sysntax to check for JRE Version
as well as also let me know if i want to create my own install script then where i have to writ script ?
ALL
I am new to Installshield , i am using macrovision Installshield 2008
can any one plese let me know that how i have to authintace the system that JRE 1.6 or higher is installed on machine
as i tried with Registry
HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Runtime Environment\CurrentVersion
but i am not able to check for JRE condition through
1.Create Customer sofware condition
2.CHECK FOR REGISTRY
3.I am STUCK IN CONDITION BUILDER
so please any one let me know whats the sysntax to check for JRE Version
as well as also let me know if i want to create my own install script then where i have to writ script ?
(4) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Feb 23, 2009
05:03 PM
If you look in the Redistributables view, there is a Java run-time prerequisite you can add to your project; it contains a condition that might suit your needs...
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Feb 23, 2009
09:46 PM
Hi Robert.
thank you so much. I sincerely appreciate your generosity,
I allready done that thing created new Prereqestor for JRE 1.6,
and done all the steps problem is just , i want to check that if the Machine has higher version then 1.6 , it that time it shoud have to skip the installation of JRE 1.6 but
i am not able to check the version with < opertator
i tried with these also in condition Buider
CURRENT_VERSION > 1.6
CURRENT_VERSION > “1.6”
CURRENT_VERSION > ‘1.6’
so can u please explain me in details , what i have to write as conditon in .prq (prerequstor) file.
thank you so much. I sincerely appreciate your generosity,
I allready done that thing created new Prereqestor for JRE 1.6,
and done all the steps problem is just , i want to check that if the Machine has higher version then 1.6 , it that time it shoud have to skip the installation of JRE 1.6 but
i am not able to check the version with < opertator
i tried with these also in condition Buider
CURRENT_VERSION > 1.6
CURRENT_VERSION > “1.6”
CURRENT_VERSION > ‘1.6’
so can u please explain me in details , what i have to write as conditon in .prq (prerequstor) file.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Feb 24, 2009
11:46 AM
Please see, for example, the Prerequisite Condition details for the existing Java prerequisite, which has a similar condition set up, and which you can modify...
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Mar 04, 2009
10:49 AM
Here's a snippet I've been using for some time now, hope it helps;
prototype Get_JRE_Folder(BYREF STRING) ;
function Get_JRE_Folder( JRE_dir)
NUMBER nResult,nSetupType,nRootKey, keyType,nvSize;
STRING keyString, JRE_Version;
begin
RegDBSetDefaultRoot(HKEY_LOCAL_MACHINE);
nRootKey = HKEY_LOCAL_MACHINE;
if (RegDBSetDefaultRoot(nRootKey) < 0) then
MessageBox("First call to RegDBSetDefaultRoot failed: Error in Line 101", SEVERE);
return -1;
endif;
keyType= REGDB_STRING_EXPAND;
//Try to find the Java RunTime first
if (RegDBGetKeyValueEx ( "\\SOFTWARE\\JavaSoft\\Java Runtime Environment", "CurrentVersion",keyType, JRE_Version, nvSize) < 0 ) then
//NO JRE FOUND
// MessageBox("Could not detect Java Runtime Environment, will now launch JRE Installation", WARNING);
return -1;
else
keyType= REGDB_STRING_EXPAND;
//Found JRE
if (RegDBGetKeyValueEx ( "\\SOFTWARE\\JavaSoft\\Java Runtime Environment\\"+JRE_Version, "JavaHome",keyType, keyString, nvSize) < 0 ) then
//MessageBox("Could not detect JavaSoft JRE: RegDBGetKeyValueEx", WARNING);
return -1;
else
MessageBox("JavaSoft JRE has been found.",INFORMATION);
JRE_dir = keyString;
return 0;
endif;
return -1;
endif;
end;
prototype Get_JRE_Folder(BYREF STRING) ;
function Get_JRE_Folder( JRE_dir)
NUMBER nResult,nSetupType,nRootKey, keyType,nvSize;
STRING keyString, JRE_Version;
begin
RegDBSetDefaultRoot(HKEY_LOCAL_MACHINE);
nRootKey = HKEY_LOCAL_MACHINE;
if (RegDBSetDefaultRoot(nRootKey) < 0) then
MessageBox("First call to RegDBSetDefaultRoot failed: Error in Line 101", SEVERE);
return -1;
endif;
keyType= REGDB_STRING_EXPAND;
//Try to find the Java RunTime first
if (RegDBGetKeyValueEx ( "\\SOFTWARE\\JavaSoft\\Java Runtime Environment", "CurrentVersion",keyType, JRE_Version, nvSize) < 0 ) then
//NO JRE FOUND
// MessageBox("Could not detect Java Runtime Environment, will now launch JRE Installation", WARNING);
return -1;
else
keyType= REGDB_STRING_EXPAND;
//Found JRE
if (RegDBGetKeyValueEx ( "\\SOFTWARE\\JavaSoft\\Java Runtime Environment\\"+JRE_Version, "JavaHome",keyType, keyString, nvSize) < 0 ) then
//MessageBox("Could not detect JavaSoft JRE: RegDBGetKeyValueEx", WARNING);
return -1;
else
MessageBox("JavaSoft JRE has been found.",INFORMATION);
JRE_dir = keyString;
return 0;
endif;
return -1;
endif;
end;