Hi iam developing a new Plugin for he TV Server witch checks the next upcomings shedules and if the start time in the EPG has changed will change the schedule time too
Here in switzerland/germany channels is normal that the show is not coming on the same time everyday
, in this case the recording lands in the manuall folder
So the plugin works well in a testform, i'm now on the final steps.
But:
- How to i'am using the Gentle.Config to receive the SQL Connection String?
- How do i'am load/save settings from the plugin?
- how do i'am commit a schedule change to the TVServer?
thank you for the help, for me (my wife) is this plugin essantially... maybe for you too?
MoPhat
Here in switzerland/germany channels is normal that the show is not coming on the same time everyday
So the plugin works well in a testform, i'm now on the final steps.
But:
- How to i'am using the Gentle.Config to receive the SQL Connection String?
- How do i'am load/save settings from the plugin?
Code:
is this correct so?
public void SettingsLoad()
{
TvBusinessLayer layer = new TvBusinessLayer();
txtPreTime.Text = layer.GetSetting("Schedules_Corrector_PreTime", "-20").Value;
txtAfterTime.Text = layer.GetSetting("Schedules_Corrector_AfterTime", "20").Value;
txtIntervall.Text = layer.GetSetting("Schedules_Corrector_Intervall", "60").Value;
}
public void SettingsSave()
{
TvBusinessLayer layer = new TvBusinessLayer();
Setting setting = layer.GetSetting("Schedules_Corrector_PreTime", "-20");
setting.Value = txtPreTime.Text;
setting.Persist();
setting = layer.GetSetting("Schedules_Corrector_AfterTime", "20");
setting.Value = txtAfterTime.Text;
setting.Persist();
setting = layer.GetSetting("Schedules_Corrector_Intervall", "60");
setting.Value = txtIntervall.Text;
setting.Persist();
}
- how do i'am commit a schedule change to the TVServer?
thank you for the help, for me (my wife) is this plugin essantially... maybe for you too?
MoPhat