Old 6th December 2007, 13:38   #1
inmedius
Junior Member
 
Join Date: Dec 2007
Posts: 7
Repair option in Add/Remove Programs

Hi All,

I have searched the forums and followed examples from the wiki with no luck.

I am currently in the process of switching our installers from one Manufacturer to NSIS. One of the features that is used a lot is the option to Repair your installation simply by running the installer again. So for example when the user goes in to Add/Remove Programs and selects the program then selects the addition information there is an option in that dialog to repair the install.

I have set the registry settings and the path to the location of the extracted installer.

Any help in getting this working would be much appreciated.

Thanks

David
inmedius is offline   Reply With Quote
Old 6th December 2007, 22:37   #2
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
Component Manager should be able to do that.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 10th December 2007, 13:45   #3
inmedius
Junior Member
 
Join Date: Dec 2007
Posts: 7
Hi

Thanks for your reply but this is not quite what I am looking for.

If you go into the Control Panel and open 'Add/Remove Programs' you get a list of all programs installed on your machine. If you select an item you get an option on the left hand side to see support information. When that box appears there is an option to 'Repair' the product. All this genreally does is, is to run the installer in silent mode and to repair any broken or missing files.

I don't necessarily need an option in the installer to repair I just need a way of running the installer.

Thanks again for your help

David
inmedius is offline   Reply With Quote
Old 11th December 2007, 08:25   #4
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
Then all you are looking for is in the documentation:

http://nsis.sourceforge.net/Docs/AppendixD.html#D.2

ModifyPath is the string to set.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 11th December 2007, 09:31   #5
inmedius
Junior Member
 
Join Date: Dec 2007
Posts: 7
Hi kichik

I have set the ModifyPath and the NoRepair option to 0 and still the installer does not launch.

I have attached my script file, If you could have a look that would be much appreciated.

Thanks again for your help

David

I am using NSIS v2.31
Attached Files
File Type: nsi transition.nsi (6.5 KB, 285 views)
inmedius is offline   Reply With Quote
Old 11th December 2007, 10:52   #6
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
I'd guess CopyFiles failed. Use a full path instead of just the installer's name. The working directory depends on the user and you can't trust it to be the installer's directory. The user might also rename the installer.

Use $EXEPATH instead.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 11th December 2007, 14:03   #7
inmedius
Junior Member
 
Join Date: Dec 2007
Posts: 7
Hi

I have changed that value now and double checked that the Installer has been copied to the location specified. I have attached a screen shot of what I am trying to achieve. Simply when I press the 'Repair' button I want to launch the installer.

If I change the NoModify to 0 and NoRepair to 1 I get the Change button appear and the installer loads as expected.
inmedius is offline   Reply With Quote
Old 11th December 2007, 14:12   #8
inmedius
Junior Member
 
Join Date: Dec 2007
Posts: 7
Hi sorry forgot attachment.
Attached Images
File Type: gif add-remove-repair.gif (40.0 KB, 293 views)
inmedius is offline   Reply With Quote
Old 12th December 2007, 16:26   #9
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
I don't understand from your last post whether you got it working or not.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 12th December 2007, 16:47   #10
inmedius
Junior Member
 
Join Date: Dec 2007
Posts: 7
Sorry if I was un clear, I have not managed to get this working using the 'Repair' button.
inmedius is offline   Reply With Quote
Old 12th December 2007, 16:55   #11
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,343
Seems like it's a MSI only feature. Only MSI installers show this button in the information dialog.

NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 13th December 2007, 08:52   #12
inmedius
Junior Member
 
Join Date: Dec 2007
Posts: 7
OK. This should realy be documented in the documentstion.

Thanks for all your help much appreciated.

David
inmedius is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump