GetCurrentDirectory question

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • pb

    #1

    GetCurrentDirectory question

    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.GetCu rrentDirectory

    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

  • Mr. Arnold

    #2
    Re: GetCurrentDirec tory question


    "pb" <philbrierley@h otmail.comwrote in message
    news:1182041114 .798498.45540@n 15g2000prd.goog legroups.com...
    >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.GetCu rrentDirectory
    >
    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


    Comment

    Working...