Link to home
Create AccountLog in
Avatar of webressurs
webressursFlag for Norway

asked on

Howto clear cache after deleting MemberShipProvider user

I need to clear the membershipprovider cache after a user is deleted. How can this be done.Now, after deleting a user I need to run IIS reset to see that the user really is deleted!


Microsoft.Samples.SqlStoredProcedureProfileProvider._appName = appName;
MembershipProvider mp = Membership.Providers[appName];
 
mp.DeleteUser(userName, true);

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of ChetOS82
ChetOS82
Flag of United States of America image

Link to home
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
See answer
Avatar of webressurs

ASKER

After the user is deleted I bind all users to a datagrid. The deleted user is still there, even if I press ctrl-F5. If I run IIS reset, the deleted user disappears from the datagrid. It really seems like it is cached...
You are right, there is no caching in the MembershipProvider. It was my own caching who caused this problem!