1-888-365-2779
+1-888-365-2779
Try Now
More in this section

Forums / General Discussions / An undocumented discovery

An undocumented discovery

2 posts, 0 answered
  1. higgsy
    higgsy avatar
    336 posts
    Registered:
    05 Aug 2010
    04 May 2011
    Link to this post
    Hi,

    I just discovered something today that I wasnt aware existed and I just wanted to validate my findings.

    If you add a custom control to the toolboxconfig file, like so:

    <add enabled="True" type="SitefinityControls.NewsletterSignup" title="Newsletter signup" description="" resourceClassId="" cssClass="" layoutTemplate="" moduleName="" Title="Sign up for news123!" Message="Sign up to our regular newsletter." name="NewsletterSignup" />

    If you have a public property in the control which matches the properties set in the config entry (in my example I have a public property for Title and Message) then Sitefinity will automatically set the values of those public properties to the values you have set in the config file.

    Is this a sitefinity thing, or just a .NET thing - it's awesome either way, and very helpful!

    higgsy
  2. Boyan Barnev
    Boyan Barnev avatar
    1429 posts
    Registered:
    16 Aug 2017
    09 May 2011
    Link to this post
    Hi higgsy,

    Yes, it is possible to make changes to the configuration straight from the .config files, you will need to restart the application so that those changes can be read and applied on application start/first call. However this is not a recommended practice since it's much easier for a user to mess up the configuration (e.g. a typo or wrong syntax) and no error handling is available for this level of intervention.
    I hope you find the above information useful. If you need any further assistance, please let me know.

    Greetings,
    Boyan Barnev
    the Telerik team
    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
2 posts, 0 answered