Click here to Skip to main content
15,508,473 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
after click on submit button i can easily saved all value but if page post back i can retreive those values again and i found in my database also if someone has any relevant info plz share it.

thanks..

What I have tried:

i tried javascript to stop it and some tags to clear the value of html inputs but not working...
Posted
Updated 14-Aug-16 23:01pm
Comments
Swinkaran 15-Aug-16 0:29am    
So, do you want to clear the HTML input controls after saving?
Have you tried from server side?
rahulkumar013 15-Aug-16 13:06pm    
yes sir

document.getElementById("myForm").reset();
 
Share this answer
 
try this
protected void Page_Load(object sender, EventArgs e)
{
    if (!Page.IsPostBack)
    {
        //your code
    }

}


hope it will helpfull for you.
 
Share this answer
 
Comments
rahulkumar013 15-Aug-16 10:31am    
i tried this but not working
rahulkumar013 15-Aug-16 10:35am    
if i refresh my page after submit data then again same data with filled on my database
abdul subhan mohammed 18-Aug-16 2:29am    
could plz elobrate more

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900