?
Solved

Custom Folders (.NET Install)

Posted on 2004-09-17
10
Medium Priority
?
221 Views
Last Modified: 2012-03-15
I have a setup and deployment project for my C# windows service.  I added a custom folder in the "File System Editor".  I now want to be able to prompt the user for the path of that custom folder and then set it in the "File System Editor" section programmatically.  How can I do this?
0
Comment
Question by:ardolino
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 3
10 Comments
 
LVL 5

Expert Comment

by:tomasX2
ID: 12088802
That´s not that easy with a regular msi setup.
You can add a user interface with a textbox and ask the user to input a filepath but the standard vs.net setup does not have a file path dialog so he would have to type it.
Might be possible with orca( an msi database editing tool that comes with the installation sdk) to edit that.
The setup asks you for a file path in the installation path dialog(step 2 of the install)... couldn´t you have this other folder relative to that?

0
 

Author Comment

by:ardolino
ID: 12088977
My problem is that I need to find the location of the INETPUB directory.  I figured out how to query IIS using System.DirectoryServices, and I can obtain the default directory of Web Site (IIS://localhost/w3svc/1/Root).  I want to load the text box with the correct directory.  Right now, the value is hard-coded to c:\inetpub\wwwroot in the value property section of the text box for my setup project.

If this cannot be done, I have an alernate solution, but I'd rather do it this way.  I know you can pass custom data using CustomDataAction to the derived Installer class, but I need to know if there is a way to set property values from the Installer class, hence programatically modifying the setup.
0
 
LVL 5

Expert Comment

by:tomasX2
ID: 12089130
Let´s say a web server is setup up to have multiple sites but when you install your msi it goes to the one that is setup in the default web site.
Are you trying to set which web site to install your application to?
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
LVL 10

Expert Comment

by:ptmcomp
ID: 12091156
Is it a web setup project? I think they let you choose the path.
0
 
LVL 5

Expert Comment

by:tomasX2
ID: 12092264
They let you choose the path.... but the virtual directory still gets installed to the default web site.
0
 
LVL 5

Expert Comment

by:tomasX2
ID: 12095183
Correction
I think they only let you choose the name of the virtual directory.... but the virtual directory still gets installed to the default web site.
0
 

Author Comment

by:ardolino
ID: 12101686
no. this is not a web setup project.  it is a windows setup project.  The setup project installs a windows service which in turn will setup and create a web site based upon the user's selection.

There are lots of other sections on the windows setup project, such as file locations, registry, etc.  Each one of these items has a PROPERTY name.  My question is this - is there any way to modify these properties programatically, or can you only pass them into the installer class as parameters?
0
 
LVL 5

Accepted Solution

by:
tomasX2 earned 1000 total points
ID: 12102017
Don´t think you can do it... at least not without some hacking... I think the custom actions vs.net allows you to add are deferred action custom actions... although I´m not 100%
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/msi/setup/how_do_i_access_the_current_installer_session_from_inside_a_custom_action.asp
0
 

Author Comment

by:ardolino
ID: 12111554
Thank you tomasx2, this answers my question.
0
 
LVL 5

Expert Comment

by:tomasX2
ID: 12111560
Glad to help... good luck.
0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction Hi all and welcome to my first article on Experts Exchange. A while ago, someone asked me if i could do some tutorials on object oriented programming. I decided to do them on C#. Now you may ask me, why's that? Well, one of the re…
This article is for Object-Oriented Programming (OOP) beginners. An Interface contains declarations of events, indexers, methods and/or properties. Any class which implements the Interface should provide the concrete implementation for each Inter…
Michael from AdRem Software outlines event notifications and Automatic Corrective Actions in network monitoring. Automatic Corrective Actions are scripts, which can automatically run upon discovery of a certain undesirable condition in your network.…
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…
Suggested Courses

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question