Exemple #1
0
        public LoginForm(DecoderParam Params)
        {
            this._DecoderParams = Params;
            InitializeComponent();

            this.cb_User.SelectedIndex = 0;
        }
Exemple #2
0
        private void _LoadDecoderParam()
        {
            XmlSerializer xs = new XmlSerializer(typeof(DecoderParam));

            string pName = Directory.GetCurrentDirectory() + "\\DecoderParam.xml";

            FileStream fs = new FileStream(pName, FileMode.OpenOrCreate, FileAccess.ReadWrite);

            fs.Position = 0;

            try
            {
                _DParams = (DecoderParam)xs.Deserialize(fs);
            }
            catch (Exception ex)
            {
                string message = "打开解码器配置文件失败,错误信息:\r\n";
                message += ex.Message + "\r\n";
                if (ex.InnerException != null)
                {
                    message += ex.InnerException.Message;
                }
                MessageBox.Show(message, "错误", MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
            finally
            {
                fs.Close();
            }
        }
Exemple #3
0
 public PwdModForm(DecoderParam Params)
 {
     this._DecoderParams = Params;
     InitializeComponent();
 }