コード例 #1
0
ファイル: MainForm.cs プロジェクト: Ondurur/VIS
 public void refreshListBox()
 {
     ac = new AkceServices();
     eventsListBox.Items.Clear();
     for (int i = 0; i < ac.IDs.Length; i++)
     {
         int?price;
         if (ac.prices[i] == null)
         {
             price = 0;
         }
         else
         {
             price = ac.prices[i];
         }
         eventsListBox.Items.Add(ac.IDs[i] + "\t" + ac.names[i] + "\t" + price + "\t" + ac.dateTimes[i].ToString());
     }
 }
コード例 #2
0
        public NewEvent(MainForm mainForm)
        {
            InitializeComponent();
            ac = new AkceServices();
            vs = new VedouciServices();
            mf = mainForm;

            this.allResp = vs.GetAll();
            this.allHodn = ac.GetHodnosti();

            comboBoxRankRestriction.Items.Clear();
            comboBoxResponsible.Items.Clear();

            for (int i = 0; i < allResp.Count(); i++)
            {
                comboBoxResponsible.Items.Add(allResp[i].Jmeno);
            }

            for (int i = 0; i < allHodn.Count(); i++)
            {
                comboBoxRankRestriction.Items.Add(allHodn[i].Nazev);
            }
        }