Welcome to WindowsClient.net | My Blog | Sign in | Join

Windows Client Videos

How Do I: Use ASP.NET Membership Provider for WPF Authentication

The ASP.NET Membership Provider is not just for ASP.NET. It can be used to authenticate users in a WPF application as well. In this video, Todd Miranda will demonstrate how to use the ASP.NET Membership provider in a WPF application.

Author: Todd Miranda

Comments

rachidadukes@live.com said:

thanks so much for putting this video, I was for this for a long time.

Rachida

# December 2, 2009 3:59 PM

rachidadukes@live.com said:

Hi Todd!

Is it possible to do a tutorial video about the same concept: ASP.NET Membership Provider for Silverlight 4 Authentication using the the silverlight Business template from WCF Ria services?

I'm struggling to learn how to use authentication in Silverlight 4. There's no material available to learn from.

thanks again for the good job.

Rachida Dukes

# December 3, 2009 2:59 PM

TheGaffer said:

Hi Todd

Outstanding tutorial and so easy to follow and understand!

my question is .. once validated, how do you  go from here to entering the main program?

Is there someway you can point me in the right direction or tutorial.

Once again a great tutorial and looking forward to learning more from you.

Regards

Steve

# December 8, 2009 9:20 AM

afrika said:

Hi Todd,

first of all, I must say many thanks for this video. I had been searching online for .net membership authentication for a while now.

I did all you said, however. In importing the namespace System.Web I got an problem.

when I type

Using System.Web;

thats about it, it doesnt allow me to access

Using System.Web.Security;

It stops at .web

what am i doing wrong and how do i correct it

thanks

Ehi

# January 1, 2010 5:05 PM

stoicstudies said:

Hi Todd,

What has to be done to get this feature to work for .NET 4?

Thanks

# January 7, 2010 7:26 AM

vegeta4ss said:

I am using dot net 4.0 and I am unable to add a reference to system.web.  It's not in the list of choices.

Can I use similar steps to also add in the roles provider and call User.IsUserInRole() from my code behind too?  Or is the Membership provider the only one of these providers available so far?

# March 17, 2010 4:11 PM

vegeta4ss said:

I guess we use "Client Application Services" with 4.0 and going forward?

msdn.microsoft.com/.../bb384312%28VS.100%29.aspx

msdn.microsoft.com/.../dev10.query

# March 17, 2010 4:15 PM

nelusan said:

Hi great job! Thx! But why are all the forums/blogs not showing the date at which the article was written? It is soooo anoying in our world where everything moves so quickly.

# April 20, 2011 5:24 AM

sbjcat1 said:

I've followed your instructions to the letter; however I am getting two exceptions.  First when I call

 Membership.ValidateUser(user, pw);

it throws an exception saying

 Argument must be null or empty.

 Parameter name: pw

If I empty pw, it complains about user in the same way.

I've searched for "Argument must be null or empty." and can't find it anywhere on google.

The second, when I call

 MembershipCreateStatus status;

 Membership.CreateUser(user, pw, "x@email.com", "Q", "A", true, out status);

it throws

 Specified method is not supported.

I am at a total loss.

# April 28, 2011 2:25 PM

sbjcat1 said:

Never mind, small brain freeze; all is good

# April 28, 2011 2:49 PM

kabilan9929 said:

Really Nice video.. thank you
# March 2, 2012 3:45 AM