private void button1_Click(object sender, EventArgs e) { if (textBox1.Text.Trim() == "hadikay" || textBox1.Text == "ha.dk") { this.Hide(); TestDataForm a = new TestDataForm(); a.ShowDialog(); } else { MessageBox.Show("Sai mật khẩu mời bạn thử lại", "Thông báo", MessageBoxButtons.OK, MessageBoxIcon.Error); } }
public void TestGetRegList() { string s; s = string.Format("{0}2R|15|^^^90080^^^^|Âm Tính|||||F||||20130715165316||{1}{2}D0{3}{4}", DeviceHelper.STX, DeviceHelper.CR, DeviceHelper.ETX, DeviceHelper.CR, DeviceHelper.LF); //s = string.Format("{0}2R|15|^^^90080^^^^|Am Tinh|||||F||||20130715165316||{1}{2}D0{3}{4}", // DeviceHelper.STX, DeviceHelper.CR, DeviceHelper.ETX, DeviceHelper.CR, // DeviceHelper.LF); //s = // System.IO.File.ReadAllText( // @"D:\_PROJECT\Vietbait.CobasAdapter\Vietbait.CobasAdapter\bin\TestCheckSum.log"); string x = TestDataForm.GetCheckSumValue2(s); Console.WriteLine(s); }