コード例 #1
0
        private async void button3_Click(object sender, EventArgs e)
        {
            if (Configuration.UseDemoProcedure == false)
            {
                button3.Enabled = false;

                foreach (string s in ticketIds)
                {
                    try
                    {
                        await Service.SGSAPI.GetTicketImage(s);
                    }
                    catch (Exception error)
                    {
                        this.Close();
                        MessageBox.Show("Something went wrong! " + error.Message, "Error", MessageBoxButtons.OK);
                    }
                }

                button3.Enabled = true;
            }
            else
            {
                button3.Enabled = false;

                if (ticketIds.Length <= 0)
                {
                    await Demo(1);
                }
                else
                {
                    await Demo(ticketIds.Length);
                }

                button3.Enabled = true;
            }

            PanelParent.Switch(new Pages.SGSHome());
            Close();
        }
コード例 #2
0
 private void button1_Click(object sender, EventArgs e)
 {
     PanelParent.Switch(new Pages.SGSHome());
     Close();
 }