|
@@ -755,15 +755,28 @@ namespace RF_TRIO_PLL_ZIG
|
755
|
755
|
private void button_Save_Click(object sender, EventArgs e)
|
756
|
756
|
{
|
757
|
757
|
Crc16 crc16 = new Crc16();
|
|
758
|
+ DialogResult ret;
|
758
|
759
|
byte[] temp_buf = new byte[6];
|
759
|
|
-
|
760
|
|
- temp_buf[0] = 0xbe;
|
761
|
|
- temp_buf[1] = 3;
|
762
|
|
- temp_buf[2] = 3;
|
763
|
|
- temp_buf[3] = 4;
|
764
|
|
- temp_buf[4] = crc16.STH30_CreateCrc(temp_buf, temp_buf[2]);
|
765
|
|
- temp_buf[5] = 0xeb;
|
766
|
|
- serial.Serial_DataSend(temp_buf, temp_buf[2] + 3);
|
|
760
|
+ ret = MessageBox.Show("저장 하시겠습니까?",
|
|
761
|
+ "Setting",
|
|
762
|
+ MessageBoxButtons.YesNo,
|
|
763
|
+ MessageBoxIcon.Question,
|
|
764
|
+ MessageBoxDefaultButton.Button1,
|
|
765
|
+ MessageBoxOptions.DefaultDesktopOnly);
|
|
766
|
+ if (ret == DialogResult.Yes)
|
|
767
|
+ {
|
|
768
|
+ temp_buf[0] = 0xbe;
|
|
769
|
+ temp_buf[1] = 3;
|
|
770
|
+ temp_buf[2] = 3;
|
|
771
|
+ temp_buf[3] = 4;
|
|
772
|
+ temp_buf[4] = crc16.STH30_CreateCrc(temp_buf, temp_buf[2]);
|
|
773
|
+ temp_buf[5] = 0xeb;
|
|
774
|
+ serial.Serial_DataSend(temp_buf, temp_buf[2] + 3);
|
|
775
|
+ }
|
|
776
|
+ else
|
|
777
|
+ {
|
|
778
|
+ this.BringToFront();
|
|
779
|
+ }
|
767
|
780
|
}
|
768
|
781
|
public void Message_Box_Open()
|
769
|
782
|
{
|