Пример #1
0
 private void bt등록_Click(object sender, EventArgs e)
 {
     Entry entry = new Entry();
     entry.Year = Convert.ToInt32(tb경기날짜.Text.Substring(0, 4));
     entry.Month = Convert.ToInt32(tb경기날짜.Text.Substring(4, 2));
     entry.Day = Convert.ToInt32(tb경기날짜.Text.Substring(6, 2));
     entry.HomeTeam = tb홈팀.Text;
     entry.AwayTeam = tb어웨이팀.Text;
     entry.PlayerId = Convert.ToInt32(tb선수ID.Text);
     entry.PlayerName = tb선수이름.Text;
     entry.PitcherId = Convert.ToInt32(tb선발ID.Text);
     entry.PitcherName = tb선발이름.Text;
     entry.BatNumber = Convert.ToInt32(tb타순.Text);
     Regist(entry);
 }
Пример #2
0
 private void Regist(Entry entry)
 {
     List<Entry> entries = new List<Entry>();
     entries.Add(entry);
     dbMgr.Save<Entry>(entries);
 }