web page Save Dialog specify folder?

Discussion in 'ASP .Net' started by Bryan Ax, May 26, 2005.

  1. Bryan Ax

    Bryan Ax Guest

    Every time I've worked with saving files from the web, I have always
    used code like the following to force a save dialog where a consumer
    can choose to open or save the file.

    string fileName = "somefile.xml";
    Response.ContentType = "binary/octet";
    Response.AddHeader("Content-Disposition", "attachment; filename=" +
    fileName + "");
    Response.Flush();
    Response.Write(file);

    This works fine. However, I have a client with a request to force a
    default folder in the Save dialog window, i.e. default the save dialog
    to go to the user's My Documents folder, or some other. However, I
    don't believe this is possible. I've never found a way to do it, and my
    research in this group and others suggests that there is no way to
    force a Save dialog to start in a given folder (which makes sense, for
    security reasons, etc.). I'm just looking for confirmation of this that
    I can communicate to the client, or, if someone knows some code or a
    third party tool that can help assist with this client request, I'd
    appreciate that, too. I still stick to my guns that it's not
    possible...

    Sincerely,

    Bryan
     
    Bryan Ax, May 26, 2005
    #1
    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. =?Utf-8?B?bGVueWFkbw==?=
    Replies:
    2
    Views:
    427
    =?Utf-8?B?bGVueWFkbw==?=
    May 20, 2005
  2. Bob Barrows [MVP]

    Re: save file dialog window from a web page

    Bob Barrows [MVP], Sep 11, 2005, in forum: ASP .Net
    Replies:
    0
    Views:
    2,196
    Bob Barrows [MVP]
    Sep 11, 2005
  3. BusyBoy
    Replies:
    2
    Views:
    616
    =?Utf-8?B?TGVvbiBNYXluZQ==?=
    Oct 31, 2006
  4. hell2heaven
    Replies:
    0
    Views:
    428
    hell2heaven
    Oct 26, 2008
  5. Arnaud
    Replies:
    1
    Views:
    109
    Nathan Sweet
    Mar 3, 2004
Loading...

Share This Page