PDA

View Full Version : How can I search for registry key thru dialogs



psuryakiran
07-20-2004, 12:45 AM
Hi everybody,

Can anyone please tell me how to I search for registry key from dialogs written in Java language.

thanks in advance,
with regards,
Kiran Kumar

brianl
07-20-2004, 11:17 AM
In one of the script events for your dialog in the Dialogs view (for example, queryEnter), you can do:



public void queryEnterDialog1(com.installshield.event.ISQueryContext arg0)
{
try {
Win32RegistryService wserv = (Win32RegistryService)arg0.getService(Win32RegistryService.NAME);
// do wserv.keyExists() or whatever
} catch (ServiceException se) {
se.printStackTrace();
}
}

Win32RegistryService is what is used to find/add/delete items from the Windows registry. Documentation is on helpnet (http://helpnet.installshield.com/robo/projects/isxuniversalhelplibrary/platforms/windows/api/index.html).

Katrin
07-23-2004, 01:57 AM
That is an interesting link (http://helpnet.installshield.com/robo/projects/isxuniversalhelplibrary/platforms/windows/api/index.html) you mentioned in your answer!

But I cannot reach it! - Is there a temporary problem?

MarloV
07-23-2004, 09:27 AM
The server may have been down for backups that late at night. Try again later in the morning.

psuryakiran
07-28-2004, 12:13 AM
Hi Brian,

I am very much thank ful to you for providing me some vital information. I went through this link and coded necessary program too. But at the end when I compiled, I had an error saying that this class Win32RegistryService is not found. Do you feel that I am not having necessary jar files. If so can you please tell me from where can I down load them.

In between I am using professional evaluation version of Installshield X.

Thanks in advance.

Thanks and regards,
Kiran Kumar

brianl
07-28-2004, 10:45 AM
You need to add win32ppk.jar from lib/ppk to your compilation classpath.