Question

I have some validation on my code where I enter my address, city, phone number etc. This function works perfectly fine and returns errors as needed. When I switch from one view to another and then back on a side bar I have, the validation errors are still there. I'd like to clear these values so that I dont see them everytime I go back to the tab. I've tried

modelstate.clear() 

and that doesnt work, so any other ideas would be appreciated. Thanks!

Was it helpful?

Solution

Session.Clear() fixed my problem.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top