示例#1
0
        private void ViewShow(object sender, EventArgs e)
        {
            int showNo = -1;

            if (showListBox.SelectedItems.Count != 0 && !IsNew)
            {
                string selectedShow = showListBox.SelectedItems[0].ToString();
                selectedShow = selectedShow.Substring(15, 10);
                foreach (ShowItem entry in Year.ShowList)
                {
                    string dateString = entry.Date.ToString("MM/dd/yyyy");
                    if (dateString == selectedShow)
                    {
                        showNo = entry.No;
                        break;
                    }
                }
            }

            if (showNo >= 0)
            {
                ShowListForm showList = new ShowListForm(Year.ClubID, Year.Year, showNo);
                showList.FormClosing += new FormClosingEventHandler(this.RefreshOnClose);
                showList.Visible = true;
            }
        }
示例#2
0
 private void NewShow(object sender, EventArgs e)
 {
     if (!IsNew)
     {
         ShowListForm showList = new ShowListForm(Year.ClubID, Year.Year);
         showList.FormClosing += new FormClosingEventHandler(this.RefreshOnClose);
         showList.Visible = true;
     }
 }