Not Getting perfect path

Discussion in 'ASP .Net' started by Hitesh Panchal, Mar 3, 2004.

  1. Hi,

    I have a ASP.NET application. IN which i have included one xml file. Now to
    getting values from that XML file if I am going through Load Method of
    XMLDOC it is fetching file from "C:\WINDOWS\SYSTEM32". I want to set in such
    a way that it can fetch my XML file.

    How can i set the path of my application directory.
     
    Hitesh Panchal, Mar 3, 2004
    #1
    1. Advertising

  2. Please use the server.mapath method. For example
    string XMLFilePath = Server.MapPath("Sample.xml")
    would return you the full path of the Sample.xml file that is present in
    your ASP.Net application

    Regards
    Mohamed El Ashmawy
    MEA Developer Support Center
    ITWorx on behalf of Microsoft EMEA GTSC




    "Hitesh Panchal" <> wrote in message
    news:...
    > Hi,
    >
    > I have a ASP.NET application. IN which i have included one xml file. Now

    to
    > getting values from that XML file if I am going through Load Method of
    > XMLDOC it is fetching file from "C:\WINDOWS\SYSTEM32". I want to set in

    such
    > a way that it can fetch my XML file.
    >
    > How can i set the path of my application directory.
    >
    >
     
    Mohamed El Ashmawy, Mar 3, 2004
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    0
    Views:
    8,317
  2. C A Upsdell

    Re: Why not perfect alignment?

    C A Upsdell, Oct 25, 2009, in forum: HTML
    Replies:
    7
    Views:
    539
    dorayme
    Oct 25, 2009
  3. Harlan Messinger

    Re: Why not perfect alignment?

    Harlan Messinger, Oct 25, 2009, in forum: HTML
    Replies:
    8
    Views:
    640
    Jan C. Faerber
    Nov 13, 2009
  4. Jan C. Faerber

    Re: Why not perfect alignment?

    Jan C. Faerber, Oct 28, 2009, in forum: HTML
    Replies:
    0
    Views:
    496
    Jan C. Faerber
    Oct 28, 2009
  5. dorayme

    Re: Why not perfect alignment?

    dorayme, Oct 31, 2009, in forum: HTML
    Replies:
    1
    Views:
    531
    dorayme
    Oct 31, 2009
Loading...

Share This Page