skip to Main Content

I am trying to figure out how to detect tab that is created straight by duplicating existing tab ( not by adding new tab and using the same URL) Duplicate tab seems sharing viewstate with the tab it was duplicated from and page created without being rendered from the server.
The simple approach by creating hidden input initializing it into empty string and assigning value on the first time page load is not working as on duplication the hidden input intermittently empty again… Any approach how specifically detect that page is result of the duplicate action on the browser in the page ‘load’ event added to the event listener..
Thanks

2

Answers


  1. Chosen as BEST ANSWER

    I tried the method listed, I might did something wrong, but I created hidden not server side input, but somehow on duplicate page it was still get initialize into empty so it did not work... eventually the following approach produced desirable result...

    hdnMasterPageIndx  this is server side hidden input.. value get stored in the session and increased every time page get rendered from the server... so on tab duplication it still in the local storage. It works on postbacks as the value got removed before come back
    

  2. ok, so no one is biting here.

    It turns out you CAN detect if the page in question was navigated to by back button, forward button, or in this case duplicate.

    How to do this is outlined in this post:

    How to realize when a browser tab has been duplicated

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search