Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Visual Studio.NET / Setup / July 2006

Tip: Looking for answers? Try searching our database.

How to Pre-Set InstallAllUsersVisible

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
David White - 11 Jul 2006 18:05 GMT
I am creating an installer using VS2005 and I do not want to permit the user to
override my setting for InstallAllUsers (as documented in the help for the
InstallAllUsers property). So I want to set the InstallAllUsersVisible property
to False sometime before the installer's Installation Folder UI is presented.
How can I do this. It seems that I need to somehow update the property table. I
though I might be able to call MsiSetProperty() to do this. But it is not clear
where I can put this and get it triggered. I considered a custom action to do
this. But it appears that these can only be configured to run after the install
step is finished. There must be a way to do this. Any suggestions? Thanks.
Phil Wilson - 12 Jul 2006 01:14 GMT
You can edit the MSI file (Orca from the Platform SDK will do it) before you
ship the MSI file.

Open the MSI file with Orca; go to the Control table; find the row that has
a Dialog value of FolderForm and a Control of AllUsersRadioGroup. Set the
Attributes value in that column to 0 instead of 3. It looks the same at
install time but it can't be changed.
Signature

Phil Wilson [MVP Windows Installer]
----

>I am creating an installer using VS2005 and I do not want to permit the
>user to override my setting for InstallAllUsers (as documented in the help
[quoted text clipped - 6 lines]
>that these can only be configured to run after the install step is
>finished. There must be a way to do this. Any suggestions? Thanks.
David White - 12 Jul 2006 03:05 GMT
Phil,

Thanks for the response. I got Orca installed and was looking around at the
directions you gave. Any reason why I should NOT do the following (as opposed
to your route)?

(a) Go to the Property table
(b) Change the value for FolderForm_AllUsersVisible from 1 to 0

I tried this and it seems to have the intended effect. No radio group is
displayed. So the user cannot over-ride what I want done.

Is there any way to do this in an automated form, say on a post-build event in
VS2005?

Thanks.

> You can edit the MSI file (Orca from the Platform SDK will do it) before you
> ship the MSI file.
[quoted text clipped - 3 lines]
> Attributes value in that column to 0 instead of 3. It looks the same at
> install time but it can't be changed.
David White - 12 Jul 2006 11:54 GMT
Phil,

I think I figured the following out on my own. After diddling the msi file in
orca, I ran msitran.exe -g against the original and diddled msi files to
produce a transform file. Then in VS2005 I create a post-build event for the
setup project which runs msitran.exe -a specifying the transform file and the
setup project output file. Please let me know if there are any pitfalls to this
approach. Thanks for all.

> Is there any way to do this in an automated form, say on a post-build
> event in VS2005?
[quoted text clipped - 8 lines]
>> AllUsersRadioGroup. Set the Attributes value in that column to 0
>> instead of 3. It looks the same at install time but it can't be changed.
Phil Wilson - 12 Jul 2006 17:42 GMT
Those should all work. There's any number of ways to do what you asked by
hiding controls, radiobutton groups or whatever. You could even write code
to go into the MSI file and update it.
Signature

Phil Wilson [MVP Windows Installer]
----

> Phil,
>
[quoted text clipped - 17 lines]
>>> Set the Attributes value in that column to 0 instead of 3. It looks the
>>> same at install time but it can't be changed.

Rate this thread:







Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.