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. General Programming
  3. C#
  4. HttpWebRequest/Response check for connectivity

HttpWebRequest/Response check for connectivity

Scheduled Pinned Locked Moved C#
question
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.
  • S Offline
    S Offline
    softwarejaeger
    wrote on last edited by
    #1

    Hello, how is it possible to check, that the client is connected, before i response to that? I have a lot time-intensive tasks, doing with HttpRequests and i don't want to work in my application and the client is disconnected. Is there any way? Thank you

    D 1 Reply Last reply
    0
    • S softwarejaeger

      Hello, how is it possible to check, that the client is connected, before i response to that? I have a lot time-intensive tasks, doing with HttpRequests and i don't want to work in my application and the client is disconnected. Is there any way? Thank you

      D Offline
      D Offline
      Dave Kreskowiak
      wrote on last edited by
      #2

      No, because Http doesn't maintain a connection to the server. The connection is only around long enough to request the page and wait for the HTTP response to be returned. If you've got processing during the Response, then you can assume the client is still there. If you're doing the processing outside of the Response, there's no way to reliably determine if the client is still around from the server side.

      A guide to posting questions on CodeProject[^]
      Dave Kreskowiak

      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