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
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Web Development
  3. ASP.NET
  4. error in the code

error in the code

Scheduled Pinned Locked Moved ASP.NET
help
3 Posts 3 Posters 1 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.
  • D Offline
    D Offline
    Dotnetdeveloper06
    wrote on last edited by
    #1

    Response.ContentType = "application/pdf" Dim Str1 As String = "\\aflarchive2\aflreports\" + DDLJN.SelectedValue + "\20050413\AFL" + DDLRID.SelectedValue + ".pdf" Response.Redirect("http:Str1")

    C 1 Reply Last reply
    0
    • D Dotnetdeveloper06

      Response.ContentType = "application/pdf" Dim Str1 As String = "\\aflarchive2\aflreports\" + DDLJN.SelectedValue + "\20050413\AFL" + DDLRID.SelectedValue + ".pdf" Response.Redirect("http:Str1")

      C Offline
      C Offline
      Christian Graus
      wrote on last edited by
      #2

      Well, now. You've put Str1 inside the quotes, when you want this: Response.Redirect(Str1) and put the http: inside the string definition. But I'd suggest that this indicates you need to learn some basic programming before you go off and write web sites that shunt PDFs around the place. Christian Graus - Microsoft MVP - C++

      G 1 Reply Last reply
      0
      • C Christian Graus

        Well, now. You've put Str1 inside the quotes, when you want this: Response.Redirect(Str1) and put the http: inside the string definition. But I'd suggest that this indicates you need to learn some basic programming before you go off and write web sites that shunt PDFs around the place. Christian Graus - Microsoft MVP - C++

        G Offline
        G Offline
        Guffa
        wrote on last edited by
        #3

        Also the url is totally wrong. It points to a file on a local server, that file will not be possible to reach at that address using the http protocol. If the file will be access in an intranet, you don't use the http protocol to get the file. If the file should be accessible from the web using the http protocol, the url has to point to a web site on the web server where file is located. --- b { font-weight: normal; }

        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