| | |
| | | //using CodeProvider; |
| | | using DevExpress.Utils.Extensions; |
| | | using DevExpress.XtraEditors; |
| | | using DevExpress.XtraEditors.Controls; |
| | | using Yw; |
| | | using Yw.WinFrmUI; |
| | |
| | | { |
| | | public partial class IBoxFormProtocol : DocumentPage |
| | | { |
| | | private string startCode = "[&start&]"; |
| | | private string endCode = "[&end&]"; |
| | | private string paramCode = "[¶m&]"; |
| | | private string getprotocolCode = "getprotocol"; |
| | | private string saveprotocolCode = "saveprotocol"; |
| | | |
| | | public IBoxFormProtocol() |
| | | { |
| | | this.PageTitle.Caption = "协议配置"; |
| | |
| | | SendData?.Invoke(null, content); |
| | | } |
| | | |
| | | |
| | | |
| | | public void HideButton() |
| | | { |
| | | simpleButton1.Visible = false; |
| | | } |
| | | private void simpleButton1_Click(object sender, EventArgs e) |
| | | { |
| | | Save(); |
| | |
| | | /// </summary> |
| | | public void Save() |
| | | { |
| | | SendText(startCode + saveprotocolCode + paramCode + JsonHelper.Object2Json(GetData()) + endCode); |
| | | |
| | | SendText(IBoxHelper.startCode + IBoxHelper.saveprotocolCode + IBoxHelper.paramCode + JsonHelper.Object2Json(GetData()) + IBoxHelper.endCode); |
| | | } |
| | | |
| | | public void SetData() |
| | | { |
| | | |
| | |
| | | private void EboxFormProtocol_Load(object sender, EventArgs e) |
| | | { |
| | | Thread.Sleep(500); |
| | | SendText(startCode + getprotocolCode + paramCode + endCode); |
| | | SendText(IBoxHelper.startCode + IBoxHelper.getprotocolCode + IBoxHelper.paramCode + IBoxHelper.endCode); |
| | | } |
| | | |
| | | /// <summary> |