GetCurrentDirectory question

  • Thread starter Thread starter pb
  • Start date Start date
P

pb

I am using asp.net and have some code in a file in the App_Code
directory. I also have a text file in the same directory that I want
to access. This file will always br in the same directory but I will
not know the absolute path.

When I try...

Dim s As String = Directory.GetCurrentDirectory

I get

'c:\program files\microsoft visual studio 8\common7\IDE'

which is not the current directory of the code file that this is being
called from.

What am I missing?

Pb
 
pb said:
I am using asp.net and have some code in a file in the App_Code
directory. I also have a text file in the same directory that I want
to access. This file will always br in the same directory but I will
not know the absolute path.

When I try...

Dim s As String = Directory.GetCurrentDirectory

I get

'c:\program files\microsoft visual studio 8\common7\IDE'

which is not the current directory of the code file that this is being
called from.

What am I missing?

Mappath method in .Net Framework 2.0 and if it's .Net Framework 1.1, then
use Goole to find it out. I think it's MapServer in 1.1
 
Back
Top