private void bSpeichern_Click(object sender, EventArgs e)
        {
            Einstellungen ein = new Einstellungen();

            ein.path = textBox1.Text;

            ein.alt       = checkAlt.Checked;
            ein.shift     = checkShift.Checked;
            ein.steuerung = checkSteuerung.Checked;

            ein.key = (Keys)Enum.Parse(typeof(Keys), bKey.Text);

            ein.autostart = checkAuto.Checked;

            RegistryKey rkApp = Registry.CurrentUser.OpenSubKey("SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run", true);

            if (ein.autostart)
            {
                Verknüpfung.VerknüpfungErstellen(Application.ExecutablePath, Application.StartupPath, Application.StartupPath + "\\logo.ico", "startup");
                System.IO.File.SetAttributes(Application.StartupPath + "\\OpenTools V2.0.lnk", System.IO.FileAttributes.Hidden);

                rkApp.SetValue(Application.ProductName, Application.StartupPath + "\\OpenTools V2.0.lnk");
            }
            else
            {
                rkApp.DeleteValue(Application.ProductName, false);
                System.IO.File.Delete(Application.StartupPath + "\\OpenTools V2.0.lnk");
            }


            ein.save();

            Close();
        }
 private void desktopverknüpfungErstellenToolStripMenuItem_Click(object sender, EventArgs e)
 {
     if (listToolgruppen.SelectedItems.Count != 0)
     {
         Verknüpfung.DesktopverknüpfungErstellen(einstellungen.path + "\\OpenTools V2.0\\" + listToolgruppen.SelectedItem + ".tg");
     }
 }
        private void bFertig_Click(object sender, EventArgs e)
        {
            //TODO: IF textbox.text leer

            if (textBox1.Text != String.Empty)
            {
                if (IS.creatable(textBox1.Text) == true)
                {
                    if (!System.IO.File.Exists(einstellungen.path + "OpenTools V2.0\\" + textBox1.Text + ".tg"))
                    {
                        //Toolgruppe nicht vorhanden --> Erstellen

                        toolgruppe.Dateien        = Dateien;
                        toolgruppe.Ordner         = Ordner;
                        toolgruppe.Internetseiten = Internetseiten;

                        toolgruppe.name = textBox1.Text;

                        toolgruppe.save(einstellungen.path + "\\OpenTools V2.0\\" + textBox1.Text + ".tg");

                        //DesktopShortcut erstellen
                        if (checkShortcut.Checked)
                        {
                            Verknüpfung.DesktopverknüpfungErstellen(einstellungen.path + "\\OpenTools V2.0\\" + textBox1.Text + ".tg");
                        }
                    }
                    else
                    {
                        //Toolgruppe bereits vorhanden:

                        MessageBox.Show("Toolgruppe bereits vorhanden!", "Bereits vorhanden", MessageBoxButtons.OK, MessageBoxIcon.Error);
                        this.DialogResult = DialogResult.None;
                        textBox1.Select();
                        textBox1.SelectionStart  = 0;
                        textBox1.SelectionLength = textBox1.Text.Length;
                    }
                }
                else
                {
                    MessageBox.Show("Die Zeichen \\ / ? : * \" < > | dürfen nicht verwendet werden!", "FAIL!", MessageBoxButtons.OK, MessageBoxIcon.Error);
                    this.DialogResult = DialogResult.None;
                    textBox1.Select();
                    textBox1.SelectionStart  = 0;
                    textBox1.SelectionLength = textBox1.Text.Length;
                }
            }
            else
            {
                MessageBox.Show("Bitte gib deiner Toolgruppe einen Namen! Sie ist sonst traurig", "Name --> Toolgruppe traurig", MessageBoxButtons.OK, MessageBoxIcon.Error);
                this.DialogResult = DialogResult.None;
                textBox1.Select();
                textBox1.SelectionStart  = 0;
                textBox1.SelectionLength = textBox1.Text.Length;
            }
        }