NationCodeInfo.cs 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. using System;
  2. using System.Collections.Generic;
  3. using System.ComponentModel;
  4. using System.Data;
  5. using System.Drawing;
  6. using System.Linq;
  7. using System.Text;
  8. using System.Threading.Tasks;
  9. using System.Windows.Forms;
  10. namespace PTMedicalInsurance.Forms
  11. {
  12. public partial class NationCodeInfo : Form
  13. {
  14. public string NationCode = "", NationName = "";
  15. public NationCodeInfo(string standardCode)
  16. {
  17. InitializeComponent();
  18. tb_NationCode.Text = standardCode;
  19. }
  20. private void btn_OK_Click(object sender, EventArgs e)
  21. {
  22. NationCode = tb_NationCode.Text;
  23. NationName = tb_NatiionName.Text;
  24. if (string.IsNullOrEmpty(NationCode))
  25. {
  26. MessageBox.Show("贯标代码不能为空!");
  27. return;
  28. }
  29. DialogResult = DialogResult.OK;
  30. }
  31. private void NationCodeInfo_Shown(object sender, EventArgs e)
  32. {
  33. tb_NationCode.Focus();
  34. }
  35. private void btn_Cancel_Click(object sender, EventArgs e)
  36. {
  37. DialogResult = DialogResult.Cancel;
  38. }
  39. }
  40. }