Click here to Skip to main content
16,008,299 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: How to use Class in ASP.NET (C#)? Pin
Sandeep Akhare22-Oct-07 21:48
Sandeep Akhare22-Oct-07 21:48 
QuestionEncrypting TheUser Pin
SreejithAchutan21-Oct-07 19:12
SreejithAchutan21-Oct-07 19:12 
AnswerRe: Encrypting TheUser Pin
Bino B21-Oct-07 19:52
Bino B21-Oct-07 19:52 
Questionit doesnt display anything from anyother system [modified] Pin
asifbhura21-Oct-07 19:01
asifbhura21-Oct-07 19:01 
QuestionUser based Tabs Format..., Pin
Member 387988121-Oct-07 18:54
Member 387988121-Oct-07 18:54 
QuestionASP .NET 2.0 Login Control Pin
kenexcelon21-Oct-07 14:25
kenexcelon21-Oct-07 14:25 
AnswerRe: ASP .NET 2.0 Login Control Pin
MoustafaS21-Oct-07 14:35
MoustafaS21-Oct-07 14:35 
QuestionA very weird behaviour of Sql Membership Provider! Pin
Dr Odin Nordic21-Oct-07 10:36
Dr Odin Nordic21-Oct-07 10:36 
Recently I developed a website using asp.net and SQL Express. The database file is uploaded into App_Data folder. The website is using two membership providers, one is SqlMemership provider with default name AspNet…. With such configuration:

<membership>
<providers>
<clear>
<add connectionstringname="LocalSqlServer" enablepasswordretrieval="false" enablepasswordreset="true" requiresquestionandanswer="true" requiresuniqueemail="false" passwordformat="Hashed" maxinvalidpasswordattempts="500" minrequiredpasswordlength="7" minrequirednonalphanumericcharacters="0" passwordattemptwindow="1000" passwordstrengthregularexpression="" applicationname="/" name="AspNetSqlMembershipProvider" type="System.Web.Security.SqlMembershipProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<add connectionstringname="LocalSqlServer" enablepasswordretrieval="false" enablepasswordreset="true" requiresquestionandanswer="true" requiresuniqueemail="false" passwordformat="Hashed" maxinvalidpasswordattempts="500" minrequiredpasswordlength="7" minrequirednonalphanumericcharacters="0" passwordattemptwindow="1000" passwordstrengthregularexpression="" applicationname="/" name=" MySqlMembershipProvider " type="MyProviders.MySqlMembershipProvider">



The second provider is my own override of Microsoft toolkit provider's sample with some extra features. The both are using the same schema and everything.
But the problem: Sometimes (not always) you can not login though your security information is correct. And the most weird thing is when I want to use Membership.ValidateUser in those times It gives me following error:

System.InvalidCastException: Specified cast is not valid. at System.Data.SqlClient.SqlBuffer.get_Int32() at System.Data.SqlClient.SqlDataReader.GetInt32(Int32 i) at System.Web.Security.SqlMembershipProvider.GetPasswordWithFormat(String username, Boolean updateLastLoginActivityDate, Int32& status, String& password, Int32& passwordFormat, String& passwordSalt, Int32& failedPasswordAttemptCount, Int32& failedPasswordAnswerAttemptCount, Boolean& isApproved, DateTime& lastLoginDate, DateTime& lastActivityDate) at System.Web.Security.SqlMembershipProvider.CheckPassword(String username, String password, Boolean updateLastLoginActivityDate, Boolean failIfNotApproved, String& salt, Int32& passwordFormat) at System.Web.Security.SqlMembershipProvider.CheckPassword(String username, String password, Boolean updateLastLoginActivityDate, Boolean failIfNotApproved) at System.Web.Security.SqlMembershipProvider.ValidateUser(String username, String password) at System.Web.Security.Membership.ValidateUser(String username, String password) at ….
But when I reset IIS or SQL Express It works!!!!!!!!!!!!!
Does anybody have an idea?
QuestionWhich database? Pin
Sam Heller21-Oct-07 10:04
Sam Heller21-Oct-07 10:04 
AnswerRe: Which database? Pin
Christian Graus21-Oct-07 11:46
protectorChristian Graus21-Oct-07 11:46 
GeneralRe: Which database? Pin
Sam Heller21-Oct-07 22:22
Sam Heller21-Oct-07 22:22 
Questionhelp in my project Pin
cool_neha21-Oct-07 8:27
cool_neha21-Oct-07 8:27 
AnswerRe: help in my project Pin
Christian Graus21-Oct-07 11:51
protectorChristian Graus21-Oct-07 11:51 
GeneralRe: help in my project Pin
cool_neha21-Oct-07 21:48
cool_neha21-Oct-07 21:48 
AnswerRe: help in my project Pin
Bino B21-Oct-07 19:57
Bino B21-Oct-07 19:57 
GeneralRe: help in my project Pin
cool_neha21-Oct-07 21:54
cool_neha21-Oct-07 21:54 
QuestionRedirectly Form Using Timer Urgently need help Pin
HatakeKaKaShi21-Oct-07 4:33
HatakeKaKaShi21-Oct-07 4:33 
AnswerRe: Redirectly Form Using Timer Urgently need help Pin
Bassam Saoud21-Oct-07 8:59
Bassam Saoud21-Oct-07 8:59 
AnswerRe: Redirectly Form Using Timer Urgently need help Pin
Christian Graus21-Oct-07 11:56
protectorChristian Graus21-Oct-07 11:56 
QuestionGridView add Button Pin
Muhammad Nauman Yousuf21-Oct-07 2:27
Muhammad Nauman Yousuf21-Oct-07 2:27 
AnswerRe: GridView add Button Pin
Bino B21-Oct-07 19:58
Bino B21-Oct-07 19:58 
QuestionLooking for advice Pin
Ahmad Adnan20-Oct-07 23:20
Ahmad Adnan20-Oct-07 23:20 
AnswerRe: Looking for advice Pin
Christian Graus21-Oct-07 0:12
protectorChristian Graus21-Oct-07 0:12 
AnswerRe: Looking for advice Pin
Bino B21-Oct-07 20:00
Bino B21-Oct-07 20:00 
QuestionHow to store images in sql database, asp.net with c# Pin
yogesh_softworld12320-Oct-07 20:22
yogesh_softworld12320-Oct-07 20:22 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.