12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273 |
- 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 LYFZ.Software.MainBusiness.MembershipManage.SuperSmallForm
- {
- public partial class EnterPasswordSuperSmallForm : LYFZ.Software.UI.MembershipManage.SuperSmallForm.EnterPasswordSuperSmallForm
- {
- public EnterPasswordSuperSmallForm()
- {
- }
- /// <summary>
- /// 窗体要显示的中文名
- /// </summary>
- public string Pwd = "";
- /// <summary>
- /// 是否保存
- /// </summary>
- public bool IsSaveed = false;
- public string StrWindowText = "请输入密码";
- /// <summary>
- /// 窗体加载事件
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- protected override void EnterPasswordSuperSmallForm_Load(object sender, EventArgs e)
- {
- this.Text = this.StrWindowText;
- this.txtPassWord.Text = "";
- this.IsSaveed = false;
- this.txtPassWord.Focus();
- }
- /// <summary>
- /// 确定
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- protected override void btnOK_Click(object sender, EventArgs e)
- {
- if (this.txtPassWord.Text.Trim() != "")
- {
- this.Pwd = LYFZ.Command.Command_MD5.md5(this.txtPassWord.Text.Trim());
- this.IsSaveed = true;
- this.Close();
- }
- else { MessageBoxCustom.Show("请输入密码"); }
- }
- /// <summary>
- /// 取消
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- protected override void btnCancel_Click(object sender, EventArgs e)
- { this.Close(); }
- /// <summary>
- /// 回车
- /// </summary>
- /// <param name="sender"></param>
- /// <param name="e"></param>
- protected override void txtPassWord_KeyDown(object sender, KeyEventArgs e)
- {
- if (e.KeyCode == Keys.Enter)
- { this.btnOK_Click(this, null); }
- }
- }
- }
|