15 votes
Accepted

Move users / roles / passwords to new core database

There are a few options to transfer Users and Roles from one instance to another. Sitecore Packages You can use the standard Package Designer application from the Development Tools menu in the ...
jammykam's user avatar
  • 13.8k
12 votes

How to send email, when users roles change - User Manager customization

One option is to hook into Sitecore's user:updated event (and optionally user:updated:remote). This event is raised when a user has been updated, the remote event handler is raised when a user was ...
Thomas D's user avatar
  • 1,703
7 votes

Getting User Roles from Username

To get a user by a username you can use : public class UserRepository { public static User GetUser(string domainName, string userName) { if (User.Exists(domainName + @"\" + userName)) ...
Vlad Iobagiu's user avatar
  • 18.2k
6 votes
Accepted

How to run custom logic when a user has been added to a particular role?

You can do this using Sitecore's eventing engine, by creating event handlers for the roles:usersAdded event, the roles:usersAdded:remote event, or both. The roles:usersAdded event is raised when ...
Zachary Kniebel's user avatar
6 votes

Why we should keep all user profile data in Sitecore?

If you have a lot of custom user profile data, especially if you have 500k+ users, then your best bet is probably going to be to create a custom SQL database and store your user data, with a key for ...
Zachary Kniebel's user avatar
5 votes

Sitecore Virtual User is lost on new page request

I recently came across with the same situation where we have created Virtual user and also created some custom property. At the early stage it was working properly as Sitecore user works but one day ...
Yogesh Sharma's user avatar
5 votes
Accepted

Prepopulate WFFM field with username

Based on this blog post the only valid options are Comment, Name and Full Name. You can try changing your value from User Name to Full Name but I'm not sure if it will give you what you need. You may ...
Christian Hagelid's user avatar
4 votes
Accepted

Renaming user names in Sitecore Membership Database

You need to change the LoweredUserName column as well. I just tried that and it seems to work. I couldn't verify if the affected user can still logon or whether he encountered any issues after the ...
Gatogordo's user avatar
  • 20k
4 votes

How to run custom logic when a user has been added to a particular role?

Thought I would give a more complete answer. If you would like to use Sitecore PowerShell Extensions to run custom scripts for events you can make use of the Events integration point. There is an ...
Michael West's user avatar
  • 17.9k
3 votes

Why we should keep all user profile data in Sitecore?

Typically I like to keep users in Sitecore unless there is a third party membership provider, active directory, OAuth, or SSO solution. If you do not need to use an external membership provider, then ...
C Sigmon's user avatar
  • 421
2 votes

How to validate a "Disabled" user account

If login fails, you could try to fetch the user and check the Membership user object properties for the status. You can detect the IsApproved flag this way, but not verify the password. But you ...
Gatogordo's user avatar
  • 20k
2 votes

Create users from API

If all you really need to do, is create users based on "Name" and "Email", you don't have to put this in Sitecore at all. Sitecore runs on a completely standard ASP.NET Membership Provider ...
Mark Cassidy's user avatar
1 vote
Accepted

Error logging in after resetting admin password

Did you recently switch your hashing algorithm to SHA512? If so, you'll need a different password value: USE [sitecorecmsSitecore_Core]; UPDATE [aspnet_Membership] SET [Password]='...
Dan Sinclair's user avatar
  • 5,335
1 vote

Entity Framework Code First - Sitecore Databases

I agree with the comments about not using EF CodeFirst approach with any of the default Sitecore databases. I would suggest using a custom database or only using the core database to query data from ...
jammykam's user avatar
  • 13.8k
1 vote
Accepted

How to validate a "Disabled" user account

You could override the SqlMembershipProvider and configure ASP.NET (and Sitecore) to use your version, but the extensibility points are so limited that I feel it's not really worth it. Also, the goal ...
maz's user avatar
  • 1,813

Only top scored, non community-wiki answers of a minimum length are eligible