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. Confirmation of Exit

Confirmation of Exit

Scheduled Pinned Locked Moved ASP.NET
questioncsharpasp-net
4 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.
  • K Offline
    K Offline
    kmaclean
    wrote on last edited by
    #1

    We have a system requirement for an ASP.NET application to prompt the user to save any changes before leaving the page. This is in a system with 30+ pages that are editable. We're multi-tiered, and all of our pages inherit from a base page, where we are able to put common functionality. Additionally, we have our own navigation 'toolbar', from which users can save the page that they're on, navigate to other pages within the application, etc. This toolbar is in a separate frame from the editable windows. So, specifically, if a page has a combination of controls, such as a text box, a drop-down list, and maybe a couple of checkboxes, can we mark the page as "changed" when the user interacts with those controls? Can this be done in a central location for all pages or does it have to be on a per-control basis? I had thought maybe monitoring the state bag on the page between Postbacks would work, but didn't want to explore that too deeply if someone has a better idea. We would really rather not have to change every page in our application if there's a way to do this cheaply. "Forgetting what is behind and straining toward what is ahead, I press on toward the goal to win the prize for which God has called me heavenward"

    J 2 Replies Last reply
    0
    • K kmaclean

      We have a system requirement for an ASP.NET application to prompt the user to save any changes before leaving the page. This is in a system with 30+ pages that are editable. We're multi-tiered, and all of our pages inherit from a base page, where we are able to put common functionality. Additionally, we have our own navigation 'toolbar', from which users can save the page that they're on, navigate to other pages within the application, etc. This toolbar is in a separate frame from the editable windows. So, specifically, if a page has a combination of controls, such as a text box, a drop-down list, and maybe a couple of checkboxes, can we mark the page as "changed" when the user interacts with those controls? Can this be done in a central location for all pages or does it have to be on a per-control basis? I had thought maybe monitoring the state bag on the page between Postbacks would work, but didn't want to explore that too deeply if someone has a better idea. We would really rather not have to change every page in our application if there's a way to do this cheaply. "Forgetting what is behind and straining toward what is ahead, I press on toward the goal to win the prize for which God has called me heavenward"

      J Offline
      J Offline
      Javier Lozano
      wrote on last edited by
      #2

      Check out this article[^] by Scott Mitchell from 4GuysFromRolla.com, the shows you how to prompt a user to save before leaving a web page. ~Javier Lozano

      1 Reply Last reply
      0
      • K kmaclean

        We have a system requirement for an ASP.NET application to prompt the user to save any changes before leaving the page. This is in a system with 30+ pages that are editable. We're multi-tiered, and all of our pages inherit from a base page, where we are able to put common functionality. Additionally, we have our own navigation 'toolbar', from which users can save the page that they're on, navigate to other pages within the application, etc. This toolbar is in a separate frame from the editable windows. So, specifically, if a page has a combination of controls, such as a text box, a drop-down list, and maybe a couple of checkboxes, can we mark the page as "changed" when the user interacts with those controls? Can this be done in a central location for all pages or does it have to be on a per-control basis? I had thought maybe monitoring the state bag on the page between Postbacks would work, but didn't want to explore that too deeply if someone has a better idea. We would really rather not have to change every page in our application if there's a way to do this cheaply. "Forgetting what is behind and straining toward what is ahead, I press on toward the goal to win the prize for which God has called me heavenward"

        J Offline
        J Offline
        Javier Lozano
        wrote on last edited by
        #3

        Sorry, I over this other article[^] in which he, Scott, shows you how to do this in ASP.NET. ~Javier Lozano

        K 1 Reply Last reply
        0
        • J Javier Lozano

          Sorry, I over this other article[^] in which he, Scott, shows you how to do this in ASP.NET. ~Javier Lozano

          K Offline
          K Offline
          kmaclean
          wrote on last edited by
          #4

          Thank you! I'm reviewing now, but at the very least this is giving me some great ideas.

          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