Possible to do a File SaveAs Dialog In ASP.NET

Discussion in 'ASP .Net' started by Jeffrey A. Voigt, Jun 16, 2004.

  1. ?? Is there an easy solution to this?

    Thanks,
    - J
     
    Jeffrey A. Voigt, Jun 16, 2004
    #1
    1. Advertisements

  2. Ken Cox [Microsoft MVP], Jun 16, 2004
    #2
    1. Advertisements

  3. Jeffrey A. Voigt

    Raterus Guest

    Why don't you explain what you want a little bit more, I could interpret this many ways.
     
    Raterus, Jun 16, 2004
    #3
  4. Hi Ken,

    What we are trying to do is create a type of file check-in/out system where
    the user can checkout a file from a location. When they checkout the file
    we have to ask them where they want to put it... So we need a type of dialog
    box that asks them to select a directory on their location machine....

    Since we are doing this in ASP.NET, what type of controls are available for
    this?

    Thanks,
    - Jeff
     
    Jeffrey A. Voigt, Jun 16, 2004
    #4
  5. Basically, we need a control to display to the user a listing of directories
    on their machine so they can select one. The result will be sent to the
    server in the form.

    Very similar to the HTML input type="file" control, only we need to be able
    to use it to select directories instead of files.

    Thanks,
    - J

    Why don't you explain what you want a little bit more, I could interpret
    this many ways.
     
    Jeffrey A. Voigt, Jun 16, 2004
    #5
  6. Jeffrey A. Voigt

    bloomfield Guest

    The solution is to make the user "download" the file. This way the
    browser will ask the user where to put the file somewhere on his disk -
    save as dialog. The simplest yay to do this is to provide a link to file
    when the user does a check-out. When the user click the link the browser
    will download the file. The problem with this approach is that if the
    browser "knows" the file type - like for pdf for example - it will
    directly open the file in the window instead of showing a save as
    dialog. This can be avoided by writing the file binary in the response
    and to set some custom http headers. See the following link for more
    information:
    http://support.microsoft.com/defaul...port/kb/articles/Q260/5/19.ASP&NoWebContent=1

    Hope this helps
    ____________________
    www.bloomfield.as.ro
     
    bloomfield, Jun 17, 2004
    #6
  7. Yeah, I figured that was the way to go... Got it working with that already..

    Thanks!
    - J
     
    Jeffrey A. Voigt, Jun 17, 2004
    #7
    1. Advertisements

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.