473,383 Members | 1,803 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,383 software developers and data experts.

C# 3.5 Setup Project

All,

I am currently creating a Visual Studio 2008 Setup Project using C#. I
am successfully running some custom actions and need to add another
based on the current directory the application is running in. So far I
have tried:

Directory.GetCurrentDirectory()
Environment.CurrentDirectory

Nothing in the Environment.GetEnvironmentVariables Dictionary helps me
either.

No matter how I try to get the current directory, it always ends up
being c:\windows\system32. This is the case no matter where I run this
application from.

If I run the application from c:\TEMP I expect the current directory to
be c:\TEMP.

Can anyone shed some light on this issue?

Thanks.

*** Sent via Developersdex http://www.developersdex.com ***
Nov 15 '07 #1
1 3383
I think you should be looking at the [SOURCEDIR] setup variable.

"Will" wrote:
All,

I am currently creating a Visual Studio 2008 Setup Project using C#. I
am successfully running some custom actions and need to add another
based on the current directory the application is running in. So far I
have tried:

Directory.GetCurrentDirectory()
Environment.CurrentDirectory

Nothing in the Environment.GetEnvironmentVariables Dictionary helps me
either.

No matter how I try to get the current directory, it always ends up
being c:\windows\system32. This is the case no matter where I run this
application from.

If I run the application from c:\TEMP I expect the current directory to
be c:\TEMP.

Can anyone shed some light on this issue?

Thanks.

*** Sent via Developersdex http://www.developersdex.com ***
Nov 15 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Scott Kaszyk | last post by:
I have created a setup project and was able to include the exe as well as the source code in the install. However, I have been unable to include the setup project source. Therefore, when I access...
4
by: pbj | last post by:
my application was created in vb.net, vs 2003. the setup project was also created in vs 2003. one of my application reviewers reported this: The .Net link that is included in the setup is not the...
2
by: serge calderara | last post by:
Dear all, I have build a setup project for my VB.NET application, I need to know the installation path of an application in order to add file in it. How can do that inside my setup project ?...
4
by: Nick | last post by:
Hi, I have a windows application, wherein the solution consists of 5 projects. When I try to create a setup and deployment project for this solution, I'm somehow unable to add anything in...
1
by: JJ | last post by:
Hi, I have gone the setup project route and added the setup project to my solution as in the guide. I have checked the dependancy's and they all seem to be there. Now do I just build the project...
0
by: Adam Clauss | last post by:
I have a C++ COM Addin I wrote for Outlook (2002) using VS.Net 2002. Having completed it, I am now looking to create a setup project and install it on another machine. I created a setup project...
4
by: Howard Kaikow | last post by:
When I build a setup project, the dependency in the setup project is tied to the version in which it was built. Is there a way to build a setup project that can be used in both versions of the...
1
by: rohan_from_mars | last post by:
I have a windows service and am also using Enterprise Library June 2005 version. Now i have created Setup and Deployment Project which installs the service. but how do i add EL dlls-...
6
by: andrewbb | last post by:
I want to deploy a service with a windows app and the setup program must conform to the Vista certification requirements. Can that be done with the standard .net setup project? Assuming cost is...
3
by: sanghavi | last post by:
how to create a set up project in vb.net..how to run an application on a different machine
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.