Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. File Uploading/Downloading problem.

File Uploading/Downloading problem.

Scheduled Pinned Locked Moved ASP.NET
helpcssdatabasesysadmintutorial
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    TheMajorRager
    wrote on last edited by
    #1

    Hi, I am working on this web application that needs to allow the user to upload files. The problem I am having is that when I upload a file with a pound sign, and try to access it I get an error. For example, the file 'AMS.doc' would upload fine to the server and when I try to download that file when it shows up in my grid, everything will go as expected. However, if I rename the file to 'AM#S.doc' and then upload it, it will get uploaded to the server and the file name will get saved to the database, however, when I click to try to download that file, I get an error message. Is there a way to fix this? I have tried Server.UrlDecode and Encode, as well as HtmlEncode and decode, and none have fixed the issue. Thanks, TheMajorRager

    E 1 Reply Last reply
    0
    • T TheMajorRager

      Hi, I am working on this web application that needs to allow the user to upload files. The problem I am having is that when I upload a file with a pound sign, and try to access it I get an error. For example, the file 'AMS.doc' would upload fine to the server and when I try to download that file when it shows up in my grid, everything will go as expected. However, if I rename the file to 'AM#S.doc' and then upload it, it will get uploaded to the server and the file name will get saved to the database, however, when I click to try to download that file, I get an error message. Is there a way to fix this? I have tried Server.UrlDecode and Encode, as well as HtmlEncode and decode, and none have fixed the issue. Thanks, TheMajorRager

      E Offline
      E Offline
      Expert Coming
      wrote on last edited by
      #2

      What kind of error are you getting? Are you sure it is trying to access it the same way it is stored in the database? Sometimes when you pull things out of the database, if it thinks there is a SQL Injection risk, it will stop reading. It would help to get an error message, and some relevant code...

      The best way to accelerate a Macintosh is at 9.8m/sec² - Marcus Dolengo

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups