Hi,
I need to get the membership user and I have the EPiServer.Security.PrincipalInfo.CurrentPrincipal.GetUserGuid() in a variable.
I tried Membership
Membership.GetUser(guidVariable);ProviderUserKey is Obsolete.
but it returns null, since the GetUserGuid property is not the membership GUID.
After a lot of searches, I came up with this code:
Mediachase.Commerce.Customers.CustomerContext customerContext = new Mediachase.Commerce.Customers.CustomerContext();
Mediachase.Commerce.Customers.CustomerContact userContact = customerContext.GetContactById(modifierId);
return Membership.GetUser(userContact.ProviderUserKey.ToString());
which simes to work but
What shall I do?
Thanks in advance,
Ashkan