OUTPUT SCREENSHOTS

Problem 1 - COUNTER

It shows the web page rendered to increment the counter by 2 every time the button is clicked to increment.



Incremented by 2

This screenshot shows that the counter has been incremented by 2. Before it was 12 in the previous screenshot and now it has become 14. And YES the counter value would not be same for different browser windows and different clients, as ViewState is page specific, so for different page objects the value of counter will be different depending on how many times that specific user has incremented the counter.



Problem 2 - Making ViewState Secure

ViewState can be made secure by either making a change in web.config file or in the page directive of .aspx file. I have made it secure by making a change in web.config file. I have attached the screenshots of before and after making changes in the web.config file. Basically i set the viewStateEncryptionMode = "Always".


Before


After


Problem 3 - WebForm that stores 3 objects of customers in ViewState and Retrieve them

It shows the web page rendered to store 3 customer objects and then retrieve them simply by clicking store and retrieve buttons.


Store


Retrieve


Back to Home