Wednesday, March 23, 2011

ASP.NET Membership User Locked

PROBLEM:
ASP.NET membership user password cannot be reset

CAUSE:
User account is locked (caused by incorrect password being entered numerous times)

SOLUTION:
Unlock user account using SQL query:

DECLARE     @return_value int

EXEC  @return_value = [dbo].[aspnet_Membership_UnlockUser]
            @ApplicationName = N‘applicationName’,
            @UserName = N‘user’
SELECT      ‘Return Value’ = @return_value
GO


SOURCE:
http://codinglifestyle.wordpress.com/2010/02/13/unlock-user-via-database-query-asp-net-membership/

Thursday, March 3, 2011

ASP.NET AJAX JS Error - Sys.InvalidOperationException: Two components with the same id 'x' can't be added to the application.

ERROR:
Sys.InvalidOperationException: Two components with the same id 'x' can't be added to the application.

CAUSE:
ASP.NET Ajax Control Toolkit generated javascript code is in debug mode, which has extra checks that throw this error.

SOLUTION:
Set debug="false" in the web.config.