Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8767387
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T16:47:53+00:00 2026-06-13T16:47:53+00:00

I am making a Sharepoint 2010 WebPart with functionality from another Main Web Application.

  • 0

I am making a Sharepoint 2010 WebPart with functionality from another Main Web Application.
To develop the Webpart quickly I have imported the business logic assemblies used in the Main Web Application. The Webpart works and pulls application specific configuration information from the Sharepoint web.config file.

Is this the best place to store this information?

If not..

Where/How should the application specific configuration data be stored in Sharepoint?

The config data contains items like locations of web services etc. The data will only need to be edited by system administrators.

Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T16:47:54+00:00Added an answer on June 13, 2026 at 4:47 pm

    Web.Config is, IMHO, a terrible place to store this sort of config information – its hard to deploy and hard to change, especially if you’re using multiple web front ends.

    The recommended way to do this is to use PropertyBag (key/value pairs) through the .Properties of SPFarm, SPWeb.RootWeb (for site collections), SPWeb, SPList etc (depending upon the scope that you need).

    MSDN – Managing Custom Configuration Options for a SharePoint Application

    There is a production ready code available as part of the

    MSDN – The SharePoint Guidance Library

    See Hierarchical configuration manager

    This gives you programmatic access to read/write these values. If you want to do this without using the guidance library then you would use something like the following code.

    SPWeb web = SPContext.Current.Web;
    if (web.Properties.ContainsKey("MyProperty"))
       string myProperty = web.Properties["MyProperty"];
    

    If you want a UI to allow admins to easily set the values then use something like SharePoint Property Bag Settings

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Our development team is making the move to TFS 2010 from VSS. The company
I want to change the trust level of a Sharepoint Web Application without having
I am making a simple birthday calendar webpart for Sharepoing 2010. I need to
I have SharePoint Designer 2010 Workflows in production environment and we need to make
I'm trying to setup a development project for making a SharePoint solution. We have
i am using WSS 2.0 with sharepoint portal server 2003. i am making web
I have a web application that has a WebDav share for Word that uses
I'm making a WebPart for SharePoint that will instantiate a Silverlight UserControl and feed
I modify the structure of a default page category.aspx from Sharepoint Blog template making
I am making a custom Activity for SharePoint 2010. When I drop the activity

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.