Tag Archives: dewacorp-development-services

Troubleshooting on Legacy Survey App running on ASP.NET 2.0

We built this legacy application back in 2007 and have a major upgrade on 2009 and been running since then but then there is no much activity since 2014. Then reassure-ct again in late 2015.

Couple findings

  • Error on the session

This is a bit shock cause .cs file is never being change since 2009 !!!

Solution: Change the code accordingly to handle the missing handling of Session.

Find another one which is relating on Debug mode. Set: <compilation debug=”false”> in Web.Config. There is a possibility that there is a bug previously and didn’t set back into False.

http://blogs.msdn.com/b/prashant_upadhyay/archive/2011/07/15/pros-and-cons-of-using-debug-true-in-asp-net-applications-in-production-environment.aspx

  • Validation of viewstate MAC failed. If this application is hosted by a Web Farm or cluster, ensure that <machineKey> configuration specifies the same validationKey and validation algorithm. AutoGenerate cannot be used in a cluster.

Turn out that the database server is registered under web.config still using the new production server. Need to change to a new server.

  • The application message came up: “You have a duplicate in MostLeast Preferred section. The option only can be used once of those questions. Please re-select it again.” Check the answer in the application and no duplicate answer.

Turn out that the actual matrix answer records in the database table has a duplicate for that particular question. Looks like entering twice. Not sure causing this at this stage. However by removing the duplicated entries, it solve the problem.