ASP.NET Session State SQL Server Mode provides a good way to have a persistent session, especially for server farm configuration. Here are the steps to quickly configure the environment to do so using SQL Server Express edition (because sometimes, you don't need the full-blown version of SQL Server just to track sessions). Steps Download and install SQL Server Express. Open the file, … [Read more...]
How to Fix Obsolete ConfigurationSettings.GetConfig API
When you're upgrading code from .NET Framework 1.1 to 2.0, you will get a few warnings if you use an obsolete API such as ConfigurationSettings.GetConfig, you may see something similar to this: To which you have to replace it with ConfigurationManager.GetSection(). Or the same way with ConfigurationSettings.AppSettings.Get() to ConfigurationManager.AppSettings.Get(). The problem is after … [Read more...]
How to Resolve Login failed for user ‘DOMAIN\PCNAME$’
When migrating ASP.NET applications from Windows Server 2003 (IIS 6) to 2012 R2 (IIS 8.5), right away, one web application displayed the yellow screen of death with the following error message: System.Data.SqlClient.SqlException: Login failed for user 'DOMAIN\SERVERNAME$'. If your application is on a private network, depending on your situation, there is a few approaches you can … [Read more...]
Set ENTER key to submit Form using jQuery
This is based on a project using a ASP.NET Web Forms search page with a textbox txtSearchID and a search button btnSearch. The request was to make the submit button enabled by default when a user pressed on the ENTER key. The quickest solution is by adding a jQuery snippet at the end of the HTML doc, just before the closing </body> tag: … [Read more...]
Migrating ASP.NET 1.1 to Windows Server 2012
With Microsoft cutting the support for Windows 2003 by July 2015, many legacy web applications built with .NET Framework 1.1 have to be migrated to a newer Windows Server 2012 R2. The dilemma is that .NET Framework 1.1 is no longer supported (it's not even possible to manually install the .NET Framework 1.1 on these platforms) on Windows Server 2012 or Windows Server 2012 R2. The proposed … [Read more...]