c# - retain value after page refresh -


i using button control("validation button") in c#. define global variable in project. when clicked button form validation happens , button("save button") gets visible. problem when click validation button, current page refreshes , global variable doesn't contain values. shows null. how cal maintain value in global variable after page refresh.

this asp.net, correct?
store value in session session["myvariable"] = value , read session value = session["myvaraible"]
there other alternatives, viewstate, application or use static variable using session simple enough you.


Comments

Popular posts from this blog

c# - how to write client side events functions for the combobox items -

exception - Python, pyPdf OCR error: pyPdf.utils.PdfReadError: EOF marker not found -