Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.ComponentModel;
- using System.Data;
- using System.Drawing;
- using System.Linq;
- using System.Text;
- using System.Windows.Forms;
- namespace Kadai01
- {
- public partial class FrmNyuryoku : Form
- {
- public FrmNyuryoku()
- {
- InitializeComponent();
- }
- private void btnOK_Click(object sender, EventArgs e)
- {
- if (txtGakusekiNo.Text != "" && txtName.Text != "")
- {
- FrmKakunin form = new FrmKakunin();
- form.str1 = txtGakusekiNo.Text;
- form.str2 = txtName.Text;
- DialogResult ret = form.ShowDialog();
- if (ret == DialogResult.OK)
- {
- txtGakusekiNo.Text = "";
- txtName.Text = "";
- }
- }
- }
- private void btnEnd_Click(object sender, EventArgs e)
- {
- this.Close();
- }
- private void FrmNyuryoku_FormClosing(object sender, FormClosingEventArgs e)
- {
- DialogResult ret = MessageBox.Show("終了してもいいですか?", "終了確認", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
- if (ret == DialogResult.No)
- {
- e.Cancel = true;
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement