tidstagning/Tidstagning/ConfigUI.cs
Jens True 7eeb0e102a
Some checks failed
continuous-integration/drone/push Build is failing
Release 0.1.0
2021-07-17 15:06:25 +02:00

65 lines
1.6 KiB
C#

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.Text.RegularExpressions;
namespace Tidstagning
{
public partial class ConfigUI : Form
{
private String OnCommand = "";
private String OffCommand = "";
public ConfigUI()
{
InitializeComponent();
}
private void buttonFolderInput_Click(object sender, EventArgs e)
{
folderBrowserInput.ShowDialog();
textPathInput.Text = folderBrowserInput.SelectedPath;
}
private void buttonFolderOutput_Click(object sender, EventArgs e)
{
folderBrowserOutput.ShowDialog();
textPathOutput.Text = folderBrowserOutput.SelectedPath;
}
private void buttonCancel_Click(object sender, EventArgs e)
{
this.Close();
}
private void buttonSave_Click(object sender, EventArgs e)
{
Properties.Settings.Default.Save();
this.Close();
}
private void checkBoxRelay_CheckedChanged(object sender, EventArgs e)
{
panelRelaySettings.Enabled = checkBoxRelay.Enabled;
}
private void textBox1_TextChanged(object sender, EventArgs e)
{
try
{
textBox3.Text = Regex.Unescape(textBox1.Text);
}
catch
{
textBox3.Text = "";
}
}
}
}