|
Hello,
I get a "Could not find any recognizable digits" error when going to the next CreateUserWizard step. Anyone an idea why this happens? I've been cracking my head on it, but no luck...
Regards,
Joep
--
Server Error in '/' Application.
--------------------------------------------------------------------------------
Could not find any recognizable digits.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.FormatException: Could not find any recognizable digits.
Source Error:
Line 1536: byte[] returnBytes = new byte[hexString.Length / 2];
Line 1537: for (int i = 0; i < returnBytes.Length; i++)
Line 1538: returnBytes[i] = Convert.ToByte(hexString.Substring(i * 2, 2), 16);
Line 1539: return returnBytes;
Line 1540: }
Source File: e:\linkedpapers.com\wwwroot\App_Code\MySQLMembershipProvider.cs Line: 1538
Stack Trace:
[FormatException: Could not find any recognizable digits.]
System.ParseNumbers.StringToInt(String s, Int32 radix, Int32 flags, Int32* currPos) +0
System.Convert.ToByte(String value, Int32 fromBase) +41
Andri.Web.MySqlMembershipProvider.HexToByte(String hexString) in e:\linkedpapers.com\wwwroot\App_Code\MySQLMembershipProvider.cs:1538
Andri.Web.MySqlMembershipProvider.EncodePassword(String password) in e:\linkedpapers.com\wwwroot\App_Code\MySQLMembershipProvider.cs:1490
Andri.Web.MySqlMembershipProvider.CreateUser(String username, String password, String email, String passwordQuestion, String passwordAnswer, Boolean isApproved, Object providerUserKey, MembershipCreateStatus& status) in e:\linkedpapers.com\wwwroot\App_Code\MySQLMembershipProvider.cs:453
System.Web.UI.WebControls.CreateUserWizard.AttemptCreateUser() +305
System.Web.UI.WebControls.CreateUserWizard.OnNextButtonClick(WizardNavigationEventArgs e) +105
System.Web.UI.WebControls.Wizard.OnBubbleEvent(Object source, EventArgs e) +453
System.Web.UI.WebControls.CreateUserWizard.OnBubbleEvent(Object source, EventArgs e) +149
System.Web.UI.WebControls.WizardChildTable.OnBubbleEvent(Object source, EventArgs args) +17
System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) +35
System.Web.UI.WebControls.Button.OnCommand(CommandEventArgs e) +115
System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +163
System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +7
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +11
System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +33
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1746
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.1433; ASP.NET Version:2.0.50727.1433
|
|
|
|
|
hi
can someone pls tell me how to add custom fields and provide the updation using andris mysql membership provider
thanks
|
|
|
|
|
Hi
I am having a problem on my login page with this provider. In the loggedIn event of my login control i am trying to get the currently logged in user with this code
Dim u As MembershipUser = Membership.GetUser
but i am getting the error object not set to instance of object
any help much appreciated
thanks
|
|
|
|
|
hi all,
i am using this cs files. work nicely. my last was about navigation error, but that because of tables. now all working fine. Here i am troubling of custom error messages. In change password, i dont want any construction for new messages. but password error or any error occured is shown as "Password incorrect or New Password invalid. New Password length minimum: 7. Non-alphanumeric characters required: 1.". I want to delete the second sentence. how i customize. any possibility
|
|
|
|
|
hi,
i used MySQLProvider and MyRole Provider as well.
All r fine. if any logn problem it Login control show the error.
But after enter the correct username and password, Login Control shows as Logged In but didnt redirect to requested page. The same login page will show. Wat is the problem. any one help me. please
|
|
|
|
|
How change the time of the Cookies Time Expires to 5 days?
All time I get the value: "#12:00:00 AM#"
Example from web.config:
<authentication mode="Forms">
<forms loginurl="login.aspx" name="MYWEBAPP.ASPXAUTH" protection="All" timeout="3000000">
Help...
|
|
|
|
|
Is it possible to use this code for a oracle database. how to create a role provider for connecting to oracle database.
|
|
|
|
|
This article is VERY good; however, MySQL also has an ASP.NET Provider available for download from their site (MySQL Connector/Net 5.2.1).
I've documented my experiences with 5.2.1 (which is alpha at this time) at http://tinyurl.com/28qd33[link]
modified on Saturday, March 8, 2008 1:24 PM
|
|
|
|
|
Using the method on your blog, I see the following error when I go to the ASP.NET Web Site Administration Tool provider tab, click “Select a Different Provider (advanced)” and test the MySQLMembershipProviderprovider:
Could not establish a connection to the database.
If you have not yet created the SQL Server database, exit the Web Site Administration tool, use the aspnet_regsql command-line utility to create and configure the database, and then return to this tool to set the provider.
Any thoughts? I can't find any documentation on how to get the MySql Connection/Net Profile Provider anywhere...yours was the closest I found.
What are you coding as the provider type? "MySql.Data, Version=5.2.1.0, Culture=neutral, PublicKeyToken=C5687FC88969C44D"?
You say "After the tables are built, you’ll want to setup your web application’s web.config (using your machine.config as a template)"...can you be a bit more specific? Would you mind posting a full blown example?
|
|
|
|
|
I tried the example in this article and got most of the way through but ended up getting connection problems.
I tried the example from your link (to the blog) and it was quicker and easier. After a couple of configuration tweaks I was up and running.
|
|
|
|
|
I've spent days looking, and I keep getting this page! I've tried this code and found the same problems others have listed.
I'm using VWD 2008 Express, MySQL 5.0, and .NET 2.0. I cannot be alone in using this set of tools, yet I can't find one fully-working example of using the built-in membership, roles, personalization, etc. tools with MySQL *anywhere*!
Has anyone got a set of files with instructions that I can use?
Whew!
|
|
|
|
|
I'm using vs2008 and the rest set of tools just like yours... and i managed to get them working properly but ... only on my local host using local MySQL server....
when i try to connect to my testing website using web hosted MySQL server ... the web site administration tool gives me an error when trying to display the security tab... i tried various connection string combinations but still.. no luck.
if someone has a suggestion i would be more then grateful ...
P.S
i used the "Simple.Providers" that I've found here on "the code project" in some other post if I'm not mistaken .
|
|
|
|
|
My provider supports mysql only with odbc: what could I do in this case? I tried to change Mysql objects in Odbc objects, but I can't login... is there a workaround? Please help...
Thank you
|
|
|
|
|
Hi all... I am using this table and control,
1. If the user is giving invalid password it will give one messge as
"Your login attempt was not successful. Please try again."
2. If the attempt for more than 5 times with invalid password the user will be locked... at this time also gives same message as
"Your login attempt was not successful. Please try again."
I need different message to be displayed let me know how to do this,,,
Regards
BalaJi
modified on Monday, January 28, 2008 2:27:42 AM
|
|
|
|
|
Hi,
I have used the work created by Andri (thanks Andri ). But when I uploaded the files to the server I got the following error:
Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.
Parser Error Message: Could not load type 'Andri.Web.MySqlRoleProvider'.
Source Error:
Line 92: <add><br />
Line 93: name="MySqlRoleProvider"<br />
Line 94: type="Andri.Web.MySqlRoleProvider"<br />
Line 95: connectionStringName="ConnString"<br />
Line 96: applicationName="Skillconnect"</add>
Source File: C:\Domains\techniel.com\wwwroot\web.config Line: 94
Version Information: Microsoft .NET Framework Version:2.0.50727.832; ASP.NET Version:2.0.50727.832
Any suggestions on how I can resolve it?
Thanks,
-Haniel
|
|
|
|
|
|
I'm having the same problem. Can you clarify which dll to which bin folder please?
Thanks
|
|
|
|
|
Hi
I had this same error (Parser Error Message: Could not load type 'Andri.Web.MySqlRoleProvider') and after 2.5 hrs searching the net I still had no answer.
To make matters worse I had a test project I created a year or so ago using this same code and it worked fine but there seemed to be no differance in the code.
Then I read the instructions again where it says (3. Upload the two files to ~/App_Code)
I realised that what I had done was right clicked on the project and selected 'Add Exsisting Item'.
After clicking Yes to a message asking if I would like to place these classes in a folder called App_Code, VS2005 automaticaly created this folder and placed the classes into it.
Then I got the error.
Now I know this sounds stupid but....
I decided to delete App_Code folder and recreate it manualy.
I then right clicked on this new App_Code folder and selected 'Add Exsisting Item'.
Selected the 2 classes
Ran the project and it worked great!!!
I hope this helps some of you guys.
All the best
Hawkmoth
|
|
|
|
|
On our server we donot have SQLserver or SQLExpress, but when ever I launch the website it is failing to connect to SqlServer.
I donot have any connection strings in the web.config file pointing to SQLserver.
I am using your role and membership provider files to connect to the MYSQL database.
It looks like whenever we launch the website, it tries to create ASPNETDB.MDF in the app_data directory and since we donot have SQLServer it fails to create.
Any help will be appreciated.
|
|
|
|
|
Hi,
Can any one tell me what switches yu to use to compile from the command line please ?
I've tried:
csc /t:library MySqlRoleProvider.cs /reference:MySql.Data.dll
Which creates the .dll. Is this all I need to do ?
I hoping this will all work with the VWD Express 2005 tool
Many thanks in advance and a good christmas to all who read this
|
|
|
|
|
in between table creations
"What you think you become."
Aw, So that's why I'm a nerd!
|
|
|
|
|
The code provided up to, whilst mostly correct, didn't work for me first time. I had to edit the code a little. To save other people the trouble, I've placed the working SQL code (exported from my local database) for others to use:
CREATE TABLE `roles` (<br />
`Rolename` varchar(255) collate latin1_general_ci NOT NULL,<br />
`ApplicationName` varchar(255) collate latin1_general_ci NOT NULL,<br />
KEY `Rolename` (`Rolename`,`ApplicationName`)<br />
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_general_ci;<br />
<br />
<br />
CREATE TABLE `users` (<br />
`PKID` varchar(36) collate latin1_general_ci NOT NULL,<br />
`Username` varchar(255) collate latin1_general_ci NOT NULL,<br />
`ApplicationName` varchar(100) collate latin1_general_ci NOT NULL,<br />
`Email` varchar(100) collate latin1_general_ci NOT NULL,<br />
`Comment` varchar(255) collate latin1_general_ci default NULL,<br />
`Password` varchar(128) collate latin1_general_ci NOT NULL,<br />
`PasswordQuestion` varchar(255) collate latin1_general_ci default NULL,<br />
`PasswordAnswer` varchar(255) collate latin1_general_ci default NULL,<br />
`IsApproved` tinyint(1) default NULL,<br />
`LastActivityDate` datetime default NULL,<br />
`LastLoginDate` datetime default NULL,<br />
`LastPasswordChangedDate` datetime default NULL,<br />
`CreationDate` datetime default NULL,<br />
`IsOnLine` tinyint(1) default NULL,<br />
`IsLockedOut` tinyint(1) default NULL,<br />
`LastLockedOutDate` datetime default NULL,<br />
`FailedPasswordAttemptCount` int(11) default NULL,<br />
`FailedPasswordAttemptWindowStart` datetime default NULL,<br />
`FailedPasswordAnswerAttemptCount` int(11) default NULL,<br />
`FailedPasswordAnswerAttemptWindowStart` datetime default NULL,<br />
PRIMARY KEY (`PKID`)<br />
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_general_ci;<br />
<br />
CREATE TABLE `usersinroles` (<br />
`Username` varchar(255) collate latin1_general_ci NOT NULL,<br />
`Rolename` varchar(255) collate latin1_general_ci NOT NULL,<br />
`ApplicationName` varchar(255) collate latin1_general_ci NOT NULL,<br />
KEY `Username` (`Username`,`Rolename`,`ApplicationName`)<br />
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_general_ci;<br />
That will work with MySQL 5 in PhpMyAdmin. Happy ASP.NETing
Thanks
-Bursh.
|
|
|
|
|
|
|
excellent work, and I think I am close getting it working but am missing somehting. I have MySQL located on one computer and am running Expression web on anther. I have created a simple website and added the .cs files to the app_data folder on my website as directed. I added the script in web.cfg file as directed and have a connection string set up as follows:
<connectionstrings>
<add name="Mysqqlconn" connectionstring="Dsn=MySQL" providername="System.Data.Odbc">
The above connection string does check out ok and I have created the tables on the MySQL server as directed. I have replaced the connection string name in the new script with Mysqqlconn as indicated above. I added the create new user asp control to an asp page on my website. When preview it in a browser and try to create the new user I get:
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.
Compiler Error Message: CS0246: The type or namespace name 'MySql' could not be found (are you missing a using directive or an assembly reference?)
Source Error:
Line 4: using System;
Line 5: using System.Data;
Line 6: using MySql.Data.MySqlClient;
Line 7: using System.Configuration;
Line 8: using System.Diagnostics;
indicating line 6 as the problem. What do I need to do?
Thanks for your help.
Bill
|
|
|
|
|