SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have some data for my SP feature that is using the hierarchical object store to persist the data. I would like to read this data using the Client Object Model in an application that will be running on the users desktop machine. I can't seem to find a class that would allow me to do that. Is this possible? If so, how would I access it? Below is sample code of my persisted object class. I create this object using the static method on the class in an Administrative Console page. I want to be able to read (in this example) the value of the _myFavoriteMeat property from a client application (my application is straight C# 3.5 Winforms application).

public class MyCustomSettings : SPPersistedObject
    string _myFavoriteMeat;

    public MyCustomSettings() : base() {}

    public MyCustomerSettings(SPPersistedObject parent)
        : base("MySettingsName", parent)

    public static MyCustomSettings GetSettings()
         MyCustomSettings settings = SPFarm.Local.GetChild<MyCustomSettings>("MySettingsName");
         if (settings == null)
              settings = new MyCustomSettings(SPFarm.Local);

         return settings;

    public string MyFavoriteMeat
             return _myFavoriteMeat;
             _myFavoriteMeat = value;
share|improve this question
up vote 2 down vote accepted

I could be wrong, but I think you can only access objects at Site Collection level and lower (so not SPFarm level), and as SPPersistedObjects are written to the config database (not the content database) this rules out objects above Site Collection level being accessable.

This is documented in Stefan Stanev's blog post about getting SharePoint Manager 2010 to work with the Client Object Model:

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.