Updating a session variable without postback
Text Changed Session("Usr Name") = Nothing Session. Selected Value End Sub its not working wid on click event too on page load i m adding the value to text boxes Protected Sub Page_Load(By Val sender As Object, By Val e As System.
So the selected value will alwaws be the first added item in the dropdown..
Re check your code Anto George -------- If you miss an opportunity, do not cloud your eyes with tears; keep your vision clear so that you will not miss the next one.
The code I extracted this from needs the ddl.selectedvalue to equal the same as the screen after autopostback.
I could use the querystring to do this but I dont think thats the way its meant to work. you can use the query string...its better you store the value in a session because storing simple string values in session is recommended than storing heavy datatables or so.....unlike querystring, session values will never be shown in url also...its secure too.
Text=Session("Usr Email") I think you wrong direction, why in not is postback page load event you set session from textbox?
) that I store in the session's variable after updating/inserting. 4, Second or more time (if I CHANGE NOTHING) all it's OK.
Query String("Request Quote") If Query Stg = "Previous" Then wrd1.
Selected Value = Session("Category Select") End If End Sub And that's your problem. Is Post Back) block, otherwise you'd be resetting the value of the textbox and so causing the subsequent error when trying to set the session value after.
Can anyone help or explain where my logic is wrong?
The problem I am having is that I need to track a number on an website. Thanks yes it is the way to go to convert strings to integers/etc when doing calculations.