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. How to clear the SmartNavigation position programatically?

How to clear the SmartNavigation position programatically?

Scheduled Pinned Locked Moved ASP.NET
questiontutorial
3 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.
  • L Offline
    L Offline
    Lost User
    wrote on last edited by
    #1

    Hi, I have a long form that post back to itself at different places. At the very end, I have a button called "Next" that post back to itself again but some panels are hidden and some others are shown to simulate a "Next Page" effect. Since I have many controls that require post back, I need SmartNavigation to be turned on. However, when I press "Next" at the end of the page, the scroll position goes to the very bottom on the second page (where the same "Next" button is to go to page 3, for example). My question is, how do I clear the scroller position programatically? Example (I simplified the code for easy reading) Private Sub btnGoNextPage_Click ClearScrollerPosition() GoNextPage() 'Go to the top of next page End Sub Thanks! Carl

    D 1 Reply Last reply
    0
    • L Lost User

      Hi, I have a long form that post back to itself at different places. At the very end, I have a button called "Next" that post back to itself again but some panels are hidden and some others are shown to simulate a "Next Page" effect. Since I have many controls that require post back, I need SmartNavigation to be turned on. However, when I press "Next" at the end of the page, the scroll position goes to the very bottom on the second page (where the same "Next" button is to go to page 3, for example). My question is, how do I clear the scroller position programatically? Example (I simplified the code for easy reading) Private Sub btnGoNextPage_Click ClearScrollerPosition() GoNextPage() 'Go to the top of next page End Sub Thanks! Carl

      D Offline
      D Offline
      DFU23
      wrote on last edited by
      #2

      You could use an anchor tag to go to a certain spot on the page ... <a name="GoHere">Go Here</a> The trick would be getting that into the form action ... MyForm.aspx#GoHere

      Wally Atkins
      Newport News, VA, USA

      L 1 Reply Last reply
      0
      • D DFU23

        You could use an anchor tag to go to a certain spot on the page ... <a name="GoHere">Go Here</a> The trick would be getting that into the form action ... MyForm.aspx#GoHere

        Wally Atkins
        Newport News, VA, USA

        L Offline
        L Offline
        Lost User
        wrote on last edited by
        #3

        Hi, The problem with that is that my form once posted back would always go to that anchor, which is not what I want. I definately need to reset the scroll position in code (server-side). Thanks! Carl

        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