SharePoint Blog - René Hézser

Anmelden  RSS Feed RSS Feed
Startet die Suche

Archive

Kategorien

Links

Andere Blogs




ITaCS GmbH


Using the PropertyBag  

May 202008

A nice feature of a SPWeb, SPSite or SPWebApplication is the Properties Property. You can save information to this Hashtable.

e.g. webApplication.Properties["MyProperty"] = "5";

After a change to the PropertyBag, you have to webApplication.Update() the changes. But here comes the problem. The account updating the Properties has to be a member of the "Farm Administrators" group to be able to save the changes to the SPWebApplication, because you change a SPPersistantObject of your farm!

Additionally the account needs rights to 4 stored procedures in your config Database, which might not be set.

Permission Stored Procedure Database Role
EXECUTE proc_putObject WSS_Content_Application_Pools
EXECUTE proc_putClass WSS_Content_Application_Pools
EXECUTE proc_dropObject WSS_Content_Application_Pools
EXECUTE proc_getNewObjects WSS_Content_Application_Pools

 

Technorati Tags:
 
Posted by René Hézser | 2  Comments | Trackback Url  | 0  Links to this post | Bookmark this post with:        
Tags: Development, SharePoint
Technorati Tags: ,

Links to this post

Comments

commented on  Friday, September 11, 2009  7:23 PM  by  Varun
Hi Rene,
I am facing the same issue with adding values to propertybag.

Just wondered how you have given access to these stored procedures. Did you do it in the database directly if so does this not invalidate the Sharepoint Licence?

Thank you,
Varun

commented on  Monday, September 14, 2009  9:00 PM  by  René Hézser
Hi Varun,
if you can set the values from the central administration, you can avoid the problem.
Or you can make the application pool account a member of the administrator group.
I know, both ways are not pretty :-(

René

Name *:
URL:
Email:
Kommentar:


CAPTCHA Image Validation