예제 #1
0
        private void button1_Click(object sender, EventArgs e)
        {
            if (textBox3.Text.Length > 1)
            {
                SQLManager.AddGame(currentPublisher, textBox3.Text, richTextBox1.Text, numericUpDown1.Value.ToString());

                dataGridView1.Rows.Clear();

                List <GameItem> publisherGames = SQLManager.GetPublisherGames(currentPublisher);
                foreach (GameItem publisherGame in publisherGames)
                {
                    dataGridView1.Rows.Add(publisherGame.title, publisherGame.price + "$");
                }

                textBox3.Text        = null;
                richTextBox1.Text    = null;
                numericUpDown1.Value = 12;
            }
        }