I have multiple providers, How do i get a user on a specific provider? I know the GUID of the provider or the application id, Need to get user id on this particular application id
Windows 8 Professional 64 Bit.
Visual Studio 2012
Sql Server 2012
-------------------------------------
www.HermesWritings.com
bhanu2217
Member
527 Points
458 Posts
Get Users UserID on particular/specific Provider or application
Dec 13, 2012 07:08 AM|LINK
How can i get a particular Users UserID on a particular Provider GUID?
MembershipUser newUser = System.Web.Security.Membership.CreateUser(_Email, _Password, _Email, null, null, true, _ApplicationID, out createStatus); //Get Regsitered User UserID _UserID = new Guid(Membership.GetUser(newUser).ProviderUserKey.ToString());How do i enter Povider GUID in get user? I want userid of a user on a specific application name
Visual Studio 2012
Sql Server 2012
-------------------------------------
www.HermesWritings.com
BozoDav
Member
45 Points
52 Posts
Re: Get Users UserID on particular/specific Provider or application
Dec 13, 2012 07:36 AM|LINK
This might be what you're looking for.
bhanu2217
Member
527 Points
458 Posts
Re: Get Users UserID on particular/specific Provider or application
Dec 13, 2012 07:42 AM|LINK
I have multiple providers, How do i get a user on a specific provider? I know the GUID of the provider or the application id, Need to get user id on this particular application id
Visual Studio 2012
Sql Server 2012
-------------------------------------
www.HermesWritings.com
Chen Yu - MS...
All-Star
21598 Points
2493 Posts
Microsoft
Re: Get Users UserID on particular/specific Provider or application
Dec 17, 2012 09:08 AM|LINK
Hi,
If you know the specific provider name, you could use below code to get that provider. Then use GerUser() to get the user.
MembershipProvider membershipProvider = Membership.Providers["Name"];
http://msdn.microsoft.com/en-us/library/sfka4yf8.aspx
http://stackoverflow.com/questions/6707529/get-specific-membership-provider
Thanks.
Feedback to us
Develop and promote your apps in Windows Store