473,383 Members | 1,872 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.

Path of the application in Vs 2005

RC
I have a Web application accessible through pages Aspx and WebServices and
have the necessity to know the physical path where the application is
installed (in order to manage some directory of documents).

In Vs 2003 I used the command:
System.IO.Path.GetDirectoryName(System.Reflection. Assembly.GetExecutingAssembly().GetName().CodeBase )

In Vs 2005 instead such command returns me the path of one temporary
directory:

How I can make?

Note
The command: Request.ServerVariables["APPL_PHYSICAL_PATH "] does not go
well in how much usable one only to the inside of the Apsx pages and they do
not give on the WebServices!

Nov 19 '05 #1
1 950
What if you did a
Server.MapPath(Request.ApplicationPath)

?

Karl

--
MY ASP.Net tutorials
http://www.openmymind.net/
http://openmymind.net/redirector.aspx?documentId=51 - Learn about AJAX!

"RC" <RC@discussions.microsoft.com> wrote in message
news:4A**********************************@microsof t.com...
I have a Web application accessible through pages Aspx and WebServices and
have the necessity to know the physical path where the application is
installed (in order to manage some directory of documents).

In Vs 2003 I used the command:
System.IO.Path.GetDirectoryName(System.Reflection. Assembly.GetExecutingAssembly().GetName().CodeBase )

In Vs 2005 instead such command returns me the path of one temporary
directory:

How I can make?

Note
The command: Request.ServerVariables["APPL_PHYSICAL_PATH "] does not go
well in how much usable one only to the inside of the Apsx pages and they
do
not give on the WebServices!

Nov 19 '05 #2

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

Similar topics

3
by: lkrubner | last post by:
Hi. I'm messing around with some stuff in an .htaccess file. Among other things, I'd like to send my html files to the PHP parser. I'd also like to rewrite the urls using Apache mod_rewrite, so...
19
by: Steve Franks | last post by:
I am using VS.NET 2005 beta 2. When I run my project locally using the default ASP.NET Development Web Server it runs using a root address like this: http://localhost:11243/testsite/ However...
13
by: Adam | last post by:
Trying to get an asp.net 2.0 app running and am receiving this error. I see a bunch of people with this error on the net, but no solution: Works fine on my local machine, deployed to a server it...
3
by: David Thielen | last post by:
Hi; I created a virtual directory in IIS 6.0 and my asp.net app runs fine. But when it tries to write a file I get: Access to the path is denied. - C:\Inetpub\wwwroot\RunReportASP\images ...
3
by: den 2005 | last post by:
Hi everybody, I like to allow user to select and browse to which location to save the pdf file of a crystal report viewed on a web page, how can i do this in ASP.Net? I need to get the path...
9
by: larrybud2002 | last post by:
I've read about this error in this group and others from early 2006 but without any resolution, so I thought I'd bump it up to see if there's a solution. Trying to build a website on ...
4
by: John Smith | last post by:
Hello, I'm not sure if these are the appropriate forums for my question since it is closer to about Visual Studio 2005 than it is about .NET framework. So please pardon me and direct me to a...
1
by: =?Utf-8?B?SWJyYWhpbQ==?= | last post by:
I have probelm to deploy ASP.net2 Application implement in this Application the Virtual path provider techinque what I have done : 1- built the web Application with Asp.net2 as File system...
1
by: Stefan Pascal | last post by:
Hello. I have a very strange problem on my system with running C# applications from a longer than usual (>127 chars) path. I was able to reproduce the following 2 cases: 1. Socket s = new...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
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: 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:
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
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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.