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
- :
- Re: How To Add Registry Entry While Uninstalling The Product?
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
‎Apr 09, 2009
09:16 AM
How To Add Registry Entry While Uninstalling The Product?
Guys Can Anyone Help Me With Adding A Registry Key While Uninstalling The Product...thanks In Advance.......
(6) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 13, 2009
05:17 AM
guys please help....waiting for your solutions.....
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 14, 2009
04:28 AM
Hi,
Which project you are using ? (Install script/Basic MSI)
Best Regards
Nil.
Which project you are using ? (Install script/Basic MSI)
Best Regards
Nil.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 20, 2009
07:29 AM
it's basic msi type
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 23, 2009
05:37 AM
help please......need the solution urgently............
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 23, 2009
08:24 AM
Hi sowmya,
Once chk this following code i think it will help you.. using the following code we can set the registry values..
still if u did not get solution letme know i will provide you the solution..
u can mail to me sandeep.madhu14@hotmail.com..if you have any problem ..
#define COMPANY_NAME "ExampleCompany"
#define PRODUCT_NAME "ExampleProduct"
#define VERSION_NUMBER "5.00.00"
#define PRODUCT_KEY "EXAMPLE.EXE"
#define DEINST_KEY "ExampleDeinstKey"
#define APP_DEF_LOG_PATH "C:\\EXAMPLE\\TEMP"
#define APP_PATH "C:\\EXAMPLE"
#define APP_DEF_PATH "C:\\EXAMPLE\\TARGET"
#define UNINSTALL_NAME "ExampleUninstallName"
#define TITLE "RegDBSetItem Example"
// Include Ifx.h for built-in InstallScript function prototypes.
#include "Ifx.h"
export prototype ExFn_RegDBGetItem(HWND);
function ExFn_RegDBGetItem(hMSI)
STRING svLogFile, svValue, szTitle;
begin
// Set the root key.
RegDBSetDefaultRoot (HKEY_LOCAL_MACHINE);
// Set installation and uninstallation information in
// order to call RegDBSetItem and RegDBGetItem.
InstallationInfo (COMPANY_NAME, PRODUCT_NAME, VERSION_NUMBER, PRODUCT_KEY);
DeinstallStart (APP_DEF_LOG_PATH, svLogFile, DEINST_KEY, 0);
// Set the value of the application path key in the
// registry to the value of szAppPath.
if (RegDBSetItem (REGDB_APPPATH, APP_PATH) < 0) then
MessageBox ("Unable to set application path key.", SEVERE);
else
SprintfBox (INFORMATION, TITLE, "RegDBSetItem set the application " +
"path key to %s.", APP_PATH);
endif;
// Set the value of the application default path key in
// the registry to the value of szAppDefPath.
if (RegDBSetItem(REGDB_APPPATH_DEFAULT, APP_DEF_PATH) < 0) then
MessageBox ("Unable to set application default path key.", SEVERE);
else
SprintfBox (INFORMATION, TITLE, "RegDBSetItem set the application " +
"default path key to %s.", APP_DEF_PATH);
endif;
// Set the value of the uninstall name key in the
// registry to the value of szUninstallName.
if (RegDBSetItem (REGDB_UNINSTALL_NAME, UNINSTALL_NAME) < 0) then
MessageBox ("Unable to set uninstall name key.", SEVERE);
else
SprintfBox (INFORMATION, TITLE, "RegDBSetItem set the uninstall " +
"name key to %s.", UNINSTALL_NAME);
endif;
// Set up title parameter for call to SprintfBox.
szTitle = "RegDBGetItem";
// Get the value of the application path key from the registry.
if (RegDBGetItem (REGDB_APPPATH, svValue) < 0) then
MessageBox ("Unable to get value of application path key.", SEVERE);
else
SprintfBox (INFORMATION, TITLE, "RegDBGetItem retrieved the value " +
"of the application path key: %s.", svValue);
endif;
// Get the value of the application default path key in
// the registry.
if (RegDBGetItem (REGDB_APPPATH_DEFAULT, svValue) < 0) then
MessageBox ("Unable to get application default path key", SEVERE);
else
SprintfBox (INFORMATION, TITLE, "RegDBGetItem retrieved the value " +
"of the application default path key: %s.", svValue);
endif;
// Get the value of the uninstall name key from the registry.
if (RegDBGetItem (REGDB_UNINSTALL_NAME, svValue) < 0) then
MessageBox ("Unable to get application uninstall name key.", SEVERE);
else
SprintfBox (INFORMATION, TITLE, "RegDBGetItem retrieved the value " +
"of the uninstallation name key: %s.", svValue);
endif;
end;
thanks
madhu
Once chk this following code i think it will help you.. using the following code we can set the registry values..
still if u did not get solution letme know i will provide you the solution..
u can mail to me sandeep.madhu14@hotmail.com..if you have any problem ..
#define COMPANY_NAME "ExampleCompany"
#define PRODUCT_NAME "ExampleProduct"
#define VERSION_NUMBER "5.00.00"
#define PRODUCT_KEY "EXAMPLE.EXE"
#define DEINST_KEY "ExampleDeinstKey"
#define APP_DEF_LOG_PATH "C:\\EXAMPLE\\TEMP"
#define APP_PATH "C:\\EXAMPLE"
#define APP_DEF_PATH "C:\\EXAMPLE\\TARGET"
#define UNINSTALL_NAME "ExampleUninstallName"
#define TITLE "RegDBSetItem Example"
// Include Ifx.h for built-in InstallScript function prototypes.
#include "Ifx.h"
export prototype ExFn_RegDBGetItem(HWND);
function ExFn_RegDBGetItem(hMSI)
STRING svLogFile, svValue, szTitle;
begin
// Set the root key.
RegDBSetDefaultRoot (HKEY_LOCAL_MACHINE);
// Set installation and uninstallation information in
// order to call RegDBSetItem and RegDBGetItem.
InstallationInfo (COMPANY_NAME, PRODUCT_NAME, VERSION_NUMBER, PRODUCT_KEY);
DeinstallStart (APP_DEF_LOG_PATH, svLogFile, DEINST_KEY, 0);
// Set the value of the application path key in the
// registry to the value of szAppPath.
if (RegDBSetItem (REGDB_APPPATH, APP_PATH) < 0) then
MessageBox ("Unable to set application path key.", SEVERE);
else
SprintfBox (INFORMATION, TITLE, "RegDBSetItem set the application " +
"path key to %s.", APP_PATH);
endif;
// Set the value of the application default path key in
// the registry to the value of szAppDefPath.
if (RegDBSetItem(REGDB_APPPATH_DEFAULT, APP_DEF_PATH) < 0) then
MessageBox ("Unable to set application default path key.", SEVERE);
else
SprintfBox (INFORMATION, TITLE, "RegDBSetItem set the application " +
"default path key to %s.", APP_DEF_PATH);
endif;
// Set the value of the uninstall name key in the
// registry to the value of szUninstallName.
if (RegDBSetItem (REGDB_UNINSTALL_NAME, UNINSTALL_NAME) < 0) then
MessageBox ("Unable to set uninstall name key.", SEVERE);
else
SprintfBox (INFORMATION, TITLE, "RegDBSetItem set the uninstall " +
"name key to %s.", UNINSTALL_NAME);
endif;
// Set up title parameter for call to SprintfBox.
szTitle = "RegDBGetItem";
// Get the value of the application path key from the registry.
if (RegDBGetItem (REGDB_APPPATH, svValue) < 0) then
MessageBox ("Unable to get value of application path key.", SEVERE);
else
SprintfBox (INFORMATION, TITLE, "RegDBGetItem retrieved the value " +
"of the application path key: %s.", svValue);
endif;
// Get the value of the application default path key in
// the registry.
if (RegDBGetItem (REGDB_APPPATH_DEFAULT, svValue) < 0) then
MessageBox ("Unable to get application default path key", SEVERE);
else
SprintfBox (INFORMATION, TITLE, "RegDBGetItem retrieved the value " +
"of the application default path key: %s.", svValue);
endif;
// Get the value of the uninstall name key from the registry.
if (RegDBGetItem (REGDB_UNINSTALL_NAME, svValue) < 0) then
MessageBox ("Unable to get application uninstall name key.", SEVERE);
else
SprintfBox (INFORMATION, TITLE, "RegDBGetItem retrieved the value " +
"of the uninstallation name key: %s.", svValue);
endif;
end;
thanks
madhu
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 24, 2009
09:37 AM
it's not installscript type.it's rather basic Installshield MSI type project.
![](/skins/images/CC38E504FC9E1309DC48ACFEB4925670/responsive_peak/images/icon_anonymous_message.png)