Custom Configuration Items in Module
Hi All,
I am at the end of a SF4 development but due to some last minute changes i need to update my custom modules configuration to include a couple of extra strings but i cant seem figure out how?
I simply want to add a couple of string config items to this configuration below, can anyone point me in the right direction?
using System;using System.Collections.Generic;using System.Linq;using System.Text;using Telerik.Sitefinity.Modules.GenericContent.Configuration;using Telerik.Sitefinity.Configuration;using BlocksModule.Data;namespace BlocksModule.Config public class BlocksConfig : ContentModuleConfigBase public override string DefaultProvider get return "Linq2SqlDataProvider"; protected override void InitializeDefaultProviders(Telerik.Sitefinity.Configuration.ConfigElementDictionary<string, Telerik.Sitefinity.Configuration.DataProviderSettings> providers) providers.Add(new DataProviderSettings(this.Providers) Name = "Linq2SqlDataProvider", Description = "A provider that stores blocks data in a database using Linq2Sql.", ProviderType = typeof(Linq2SqlDataProvider) ); protected override void InitializeDefaultViews(Telerik.Sitefinity.Configuration.ConfigElementDictionary<string, Telerik.Sitefinity.Web.UI.ContentUI.Config.ContentViewControlElement> contentViewControls) Can anyone help me with this, i am very stuck :(
Rob
Hello Roberto,
There is a help section that explains how to work with configurations and how to create custom configuration. Does the articles help?
Greetings,
Ivan Dimitrov
the Telerik team
Hi Ivan,
I did find that but coudnt figure out how it was related, i will take another loo. I dont want to create a new configuration section, i have one, it already exists in my module, but past the basic provider setting that is in there i dont know how i can add to it (i want to add a url key etc), if you look at my code that is the config code of my module, can i use code that is in the config section documentation you linked to in that? if so, is there any chance you could provide a simple example that is related to my code?
Thanks,
Rob
Thanks Ivan,
Woke up this morning took another look at the docs and found that was exactly what i needed. Updated this thread to accept your response as the answer.
Thanks again,
Rob