Add Users: Error - Object reference not set to an instance of an object
HiFor some reason I can no longer access to theAdd User or Add Group pages under session Site Actions => Site Settings =>People and Groups. Due to this I can't add / removeusers from Site. The same error observing in all the sites. The error message I get is Object reference not set to an instance of an object (Please find the error message below). Can anyone help please?Error Message:Object reference not set to an instance of an object. at Microsoft.SharePoint.SPRoleDefinitionCollection.Init() at Microsoft.SharePoint.SPRoleDefinitionCollection.Undirty() at Microsoft.SharePoint.SPBaseCollection.System.Collections.IEnumerable.GetEnumerator() at Microsoft.SharePoint.ApplicationPages.AclInv.InitPage() at Microsoft.SharePoint.ApplicationPages.CBaseAclPage.OnLoad(EventArgs e) at System.Web.UI.Control.LoadRecursive() at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
November 7th, 2008 4:06pm

Hi,are you site collection administrator?Can anyone else add users, or even click that link?Cheers, Daniel Bugday Web: SharePoint Forum Blog: Daniel Bugday's SharePoint Blog
Free Windows Admin Tool Kit Click here and download it now
November 7th, 2008 9:43pm

Hi DanielThanks for your reply!!Yes I am site collection administrator, even through I can't access this linkI checked in the Secondary Site Collection administrator login also, but the same.No one can click that link, the same error message.Please suggest the work aroundCheers, Guruprasad
November 10th, 2008 11:06am

Hi DanielI worked in the DB and Found the answers for this issue. Issue: This was the issue related two tables (Roles and Groups). Found few Records deleted by some manually and some were modified. Resolution: Now I have updated the tables with the actual records. Add Users, Delete Users and Advance Permissions features are working fine in SharePoint Server. Cheers, Guruprasad
Free Windows Admin Tool Kit Click here and download it now
November 11th, 2008 5:04pm

HiGuruprasad,I have the exactsame problem as you've had.I don't entirely understand how you resolved the issue, please can you give me more details?Thankscapitalpro
February 5th, 2009 5:50pm

Hi capitalproI could n't come across technet forfew daysStill you have the same problem!!Cheers, Guruprasad
Free Windows Admin Tool Kit Click here and download it now
February 16th, 2009 10:50am

Hi,you need to search in your database in the 'Perms' table for the entry of your web. itiseasy to find with the column scopeurl. The value from the column RoleDefWebId will point to an entry in the Roles table that does not exists. that was the problem in my database. You need to update this entry with a valid webid.
February 20th, 2009 5:51pm

Hi,How do you create a valid webid? I guess just copying one of the other rows and chaning the id, will corrupt the database???How did this error happen in the first place? I have the same problem, and I know that noone has tampered with the database....-KajMCSD
Free Windows Admin Tool Kit Click here and download it now
April 20th, 2009 12:21pm

Can someone give a laymens answer to this issue? I am not well versed in all this SQL stuff. Would be helpful for step by step directions.ThanksCarmine Iacullo
April 20th, 2009 11:22pm

Hi Carmino,I made it work, but the solution is back at my desk at work... I will try to put it in writing tomorrow. Hope u can wait so long... It requires a little SQL tweaking, and I must admit, that I cannot make any garantees that it will actually work...I would still like to know how this could happen in the first place.KajMCSD
Free Windows Admin Tool Kit Click here and download it now
April 20th, 2009 11:25pm

This is how i made it work.-- Find the siteid and webid(RoleDefWebId) from the Perms table select RoleDefWebId from Perms where scopeurl like '%my site url%' -- Insert the url to the site that causes the error here. -- Check that the roledefid doesn't match any rows in the roles table. The query below should result in zero rows. SELECT * FROM roles WHERE WebId='7FA23C47-0B57-4D4C-A5FD-F520851E156E' -- Insert the RoleDefWebId from the first query -- Replace the siteid and the webid below with the values from the Perms selection select '97D670D6-321D-4A55-AB55-0A41374F757C' as siteId, '7FA23C47-0B57-4D4C-A5FD-F520851E156E' as WebId, RoleId, Title, Description, PermMask, PermMaskDeny, Hidden, Type, WebGroupId, RoleOrder from roles where WebId = '7FA23C47-0B57-4D4C-A5FD-F520851E156E' -- Insert a webid that has all the right roles. Typically 5 diferent roles: "Full control, Read, Designer, Contributer, Limited access" -- Insert the values from above to the Roles table.I know this could be scripted in a much more generic way, but I haven't had the time to refine the solution. I hope u can make it work... otherwise leave a msg and I will try to reply asap. MCSD
April 21st, 2009 2:57pm

Thanks drkaj, I do not get the RoleDefWebId from the first query. I do however get a message "0 rows affected." CarmineCarmine Iacullo
Free Windows Admin Tool Kit Click here and download it now
April 22nd, 2009 4:29pm

I realize this is an old thread, but in case anyone else is having a similar issue, simply inherit permissions from the parent site and then edit permissions (break away from the parent) again. You will have to reassign your permissions, but I think inheriting permissions removes the corrupted entries from the database. I think it is a safer solution than editing the SharePoint database. It corrected the error for my site. Christopher W. Douglas
October 19th, 2010 5:22pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics