[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

microsoft.public.dotnet.framework.setup

Annoying Installation "feature". How do I disable it????

pedrito

8/18/2007 1:16:00 AM

I've created an installer for my app. I must have done something different
this time from the last time, but when it runs my app from the shortcut the
installer created, it also does some sort of check to make sure everything
is installed properly and if it isn't, it helpfully runs the installer and
replaces the files that are missing. Unfortunately, this feature is screwing
up my apps own update system and at least for a few files, I need to turn it
off.

I tried setting Vital to false, but that didn't help.

Can't it just make a normal damn shortcut?

Thanks.


3 Answers

Phil Wilson

8/20/2007 7:29:00 PM

0

The supported mechanism for updating an MSI product is another MSI update
mechanism, like a patch MSP file or an update like Visual Studio's
RemovePreviousVersions.

Repair is an integral part of Windows Installer. A design that requires that
it will never happen is unsafe. You can add DISABLEADVTSHORTCUTS to your MSI
file with Orca. That will prevent routine repair via shortcut use, but there
are lots of other things that will do an automatic repair if Windows thinks
your product isn't installed as it should be. Also, you can't stop somebody
right-clicking the MSI file and choosing Repair, and what about Add/Remove
Prrograms "Click Here for Support Information" and the Repair button?

--
Phil Wilson
[MVP Windows Installer]

"pedrito" <pixbypedrito at yahoo.com> wrote in message
news:75SdnSNk6cL-1VvbnZ2dnUVZ_siknZ2d@giganews.com...
> I've created an installer for my app. I must have done something different
> this time from the last time, but when it runs my app from the shortcut
> the installer created, it also does some sort of check to make sure
> everything is installed properly and if it isn't, it helpfully runs the
> installer and replaces the files that are missing. Unfortunately, this
> feature is screwing up my apps own update system and at least for a few
> files, I need to turn it off.
>
> I tried setting Vital to false, but that didn't help.
>
> Can't it just make a normal damn shortcut?
>
> Thanks.
>


pedrito

8/21/2007 4:17:00 AM

0

"Phil Wilson" <phil.wilson@wonderware.something.com> wrote in message
news:ef5ApB24HHA.5724@TK2MSFTNGP05.phx.gbl...
> The supported mechanism for updating an MSI product is another MSI update
> mechanism, like a patch MSP file or an update like Visual Studio's
> RemovePreviousVersions.
>
> Repair is an integral part of Windows Installer. A design that requires
> that it will never happen is unsafe. You can add DISABLEADVTSHORTCUTS to
> your MSI file with Orca. That will prevent routine repair via shortcut
> use, but there are lots of other things that will do an automatic repair
> if Windows thinks your product isn't installed as it should be. Also, you
> can't stop somebody right-clicking the MSI file and choosing Repair, and
> what about Add/Remove Prrograms "Click Here for Support Information" and
> the Repair button?
>
> --
> Phil Wilson
> [MVP Windows Installer]

Okay, that makes sense I guess. The problem is, I have data files that I
want to pre-install, but the user may want to delete some of those files,
which is an option available in my app. In fact, for the app to do what the
user wants, they must be able to delete these files. But when those files
get deleted and you run the app again, the installer reinstalls them. This
is clearly not MY user's desired behavior.

Is there no way around this? Some way to mark the items as "don't repair"? I
would have assumed marking them "Vital = false" would take care of that, but
apparently not.

As for repairing the app, that's fine if it reinstalls them, they can go
back in and delete them if they want. But I certainly don't want them
reinstalled every time the app runs. I can understand it being a feature,
but it also seems logical that it should be a feature you should be able to
disable for certain files.


Phil Wilson

8/21/2007 4:38:00 PM

0

There is a way, but Visual Studio doesn't expose it in its IDE. It's not a
fully-featured tool for generating MSI files compared with 3rd party ones.

You'd need to use the Orca tool from the MSI section of the Windows SDK,
install from Orca.msi. Open your MSI file and find the File table entry with
your file in the FileName column. Make a note of the Component_ value. Then
look in the Component table and find that component. In the ComponentId
column there will be a guid. Clear that guid, set it to an empty value. This
means that the component (containing your file) isn't to be registered on
the system, so it won't get repaired.
http://msdn2.microsoft.com/en-us/library/aa3... ComponentId column.
--
Phil Wilson
[MVP Windows Installer]

"pedrito" <pixbypedrito at yahoo.com> wrote in message
news:vNWdnTfO3cTL-lfbnZ2dnUVZ_vOlnZ2d@giganews.com...
> "Phil Wilson" <phil.wilson@wonderware.something.com> wrote in message
> news:ef5ApB24HHA.5724@TK2MSFTNGP05.phx.gbl...
>> The supported mechanism for updating an MSI product is another MSI update
>> mechanism, like a patch MSP file or an update like Visual Studio's
>> RemovePreviousVersions.
>>
>> Repair is an integral part of Windows Installer. A design that requires
>> that it will never happen is unsafe. You can add DISABLEADVTSHORTCUTS to
>> your MSI file with Orca. That will prevent routine repair via shortcut
>> use, but there are lots of other things that will do an automatic repair
>> if Windows thinks your product isn't installed as it should be. Also, you
>> can't stop somebody right-clicking the MSI file and choosing Repair, and
>> what about Add/Remove Prrograms "Click Here for Support Information" and
>> the Repair button?
>>
>> --
>> Phil Wilson
>> [MVP Windows Installer]
>
> Okay, that makes sense I guess. The problem is, I have data files that I
> want to pre-install, but the user may want to delete some of those files,
> which is an option available in my app. In fact, for the app to do what
> the user wants, they must be able to delete these files. But when those
> files get deleted and you run the app again, the installer reinstalls
> them. This is clearly not MY user's desired behavior.
>
> Is there no way around this? Some way to mark the items as "don't repair"?
> I would have assumed marking them "Vital = false" would take care of that,
> but apparently not.
>
> As for repairing the app, that's fine if it reinstalls them, they can go
> back in and delete them if they want. But I certainly don't want them
> reinstalled every time the app runs. I can understand it being a feature,
> but it also seems logical that it should be a feature you should be able
> to disable for certain files.
>
>