示例#1
0
    protected void OnSavesettingsbuttonClicked(object sender, EventArgs e)
    {
        ApplicationConfigSection settings = new ApplicationConfigSection();

        settings.ConfigElement.directory = directorybox.Text;
        settings.ConfigElement.interval  = intervalbox.ValueAsInt;

        AppCfg.SaveConfiguration(settings);

        loadSettings();
    }
示例#2
0
    protected void loadSettings()
    {
        // Load configuration file
        config = AppCfg.LoadConfiguration();

        // Set snapshotter settings
        settings settings = new settings();

        settings.interval  = config.ConfigElement.interval;
        settings.directory = config.ConfigElement.directory;

        ss.settings = settings;

        // Update UI

        directorybox.Text = config.ConfigElement.directory;
        intervalbox.Value = config.ConfigElement.interval;
        folderchooserbutton.SetCurrentFolder(config.ConfigElement.directory);
    }
 public HttpFunctions(ApplicationConfigSection appConfig)
 {
     this.AppConfig = appConfig;
 }