public void ExecuteKits(User user)
        {
            StringBuilder builder = new StringBuilder();

            List <Kit> kitlist = KitReader.GetKitlist(Config.ConfigFolder + KitReader.File);

            foreach (Kit kit in kitlist)
            {
                builder.AppendFormat("<{0}> ", kit.Name);
            }

            ExecuteCommand("say", builder.ToString());
        }
Beispiel #2
0
        private void RefreshKitlist()
        {
            try
            {
                kitlist = KitReader.GetKitlist(Config.ConfigFolder + KitReader.File);
            }
            catch
            {
                kitlist = new List <Kit>();
            }
            try
            {
                listKitlist.DataSource = kitlist;

                this.comboBoxID.DisplayMember = "ToString"; // Propertyname aus dem Value Objekt im Dictionary
                this.comboBoxID.ValueMember   = "Value";
                this.comboBoxID.DataSource    = new BindingSource(mc.Items, null);
            }
            catch
            {
                MessageBox.Show("items.txt couldn't be found.\nCheck the Settings folder and add items.txt here");
            }
        }