添加项目文件。
This commit is contained in:
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<configuration>
|
||||
<startup>
|
||||
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.8"/>
|
||||
</startup>
|
||||
</configuration>
|
||||
@@ -0,0 +1,103 @@
|
||||
using HslCommunication;
|
||||
using HslCommunication.BasicFramework;
|
||||
using HslCommunication.Core;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace PLCCommunication
|
||||
{
|
||||
public class DemoUtils
|
||||
{
|
||||
public static readonly string IpAddressInputWrong = "IpAddress input wrong";
|
||||
|
||||
public static readonly string PortInputWrong = "Port input wrong";
|
||||
|
||||
public static readonly string SlotInputWrong = "Slot input wrong";
|
||||
|
||||
public static readonly string BaudRateInputWrong = "Baud rate input wrong";
|
||||
|
||||
public static readonly string DataBitsInputWrong = "Data bit input wrong";
|
||||
|
||||
public static readonly string StopBitInputWrong = "Stop bit input wrong";
|
||||
|
||||
public static void ReadResultRender<T>(OperateResult<T> result, string address, TextBox textBox)
|
||||
{
|
||||
if (result.IsSuccess)
|
||||
{
|
||||
textBox.AppendText(DateTime.Now.ToString("[HH:mm:ss] ") + $"[{address}] {result.Content}{Environment.NewLine}");
|
||||
return;
|
||||
}
|
||||
MessageBox.Show(DateTime.Now.ToString("[HH:mm:ss] ") + "[" + address + "] Read Failed " + Environment.NewLine + "Reason:" + result.ToMessageShowString());
|
||||
}
|
||||
|
||||
public static void ReadResultRender<T>(OperateResult<T[]> result, string address, TextBox textBox)
|
||||
{
|
||||
string resTemp = string.Empty;
|
||||
if (result.IsSuccess)
|
||||
{
|
||||
for (int i = 0; i < result.Content.Length; i++)
|
||||
{
|
||||
resTemp = string.Concat(resTemp, result.Content[i], ",");
|
||||
}
|
||||
string Result = resTemp.Substring(0, resTemp.Length - 1);
|
||||
textBox.AppendText(DateTime.Now.ToString("[HH:mm:ss] ") + "[" + address + "] " + Result + Environment.NewLine);
|
||||
}
|
||||
else
|
||||
{
|
||||
MessageBox.Show(DateTime.Now.ToString("[HH:mm:ss] ") + "[" + address + "] Read Failed " + Environment.NewLine + "Reason:" + result.ToMessageShowString());
|
||||
}
|
||||
}
|
||||
|
||||
public static void WriteResultRender(OperateResult result, string address)
|
||||
{
|
||||
if (result.IsSuccess)
|
||||
{
|
||||
MessageBox.Show(DateTime.Now.ToString("[HH:mm:ss] ") + "[" + address + "] Write Success");
|
||||
return;
|
||||
}
|
||||
MessageBox.Show(DateTime.Now.ToString("[HH:mm:ss] ") + "[" + address + "] Write Failed " + Environment.NewLine + " Reason:" + result.ToMessageShowString());
|
||||
}
|
||||
|
||||
public static void WriteResultRender(Func<OperateResult> write, string address)
|
||||
{
|
||||
try
|
||||
{
|
||||
OperateResult result = write();
|
||||
if (result.IsSuccess)
|
||||
{
|
||||
MessageBox.Show(DateTime.Now.ToString("[HH:mm:ss] ") + "[" + address + "] Write Success");
|
||||
return;
|
||||
}
|
||||
MessageBox.Show(DateTime.Now.ToString("[HH:mm:ss] ") + "[" + address + "] Write Failed " + Environment.NewLine + " Reason:" + result.ToMessageShowString());
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
MessageBox.Show("Data for writting is not corrent: " + ex.Message);
|
||||
}
|
||||
}
|
||||
|
||||
public static void BulkReadRenderResult(IReadWriteNet readWrite, TextBox addTextBox, TextBox lengthTextBox, TextBox resultTextBox)
|
||||
{
|
||||
try
|
||||
{
|
||||
OperateResult<byte[]> read = readWrite.Read(addTextBox.Text, ushort.Parse(lengthTextBox.Text));
|
||||
if (read.IsSuccess)
|
||||
{
|
||||
resultTextBox.Text = "Result:" + SoftBasic.ByteToHexString(read.Content);
|
||||
}
|
||||
else
|
||||
{
|
||||
MessageBox.Show("Read Failed:" + read.ToMessageShowString());
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
MessageBox.Show("Read Failed:" + ex.Message);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,60 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace PLCCommunication
|
||||
{
|
||||
public class IniHelper
|
||||
{
|
||||
public string path;
|
||||
public IniHelper(string INIPath)
|
||||
{
|
||||
path = INIPath;
|
||||
}
|
||||
[DllImport("kernel32", CharSet = CharSet.Unicode)]
|
||||
private static extern long WritePrivateProfileString(string section, string key, string val, string filePath);
|
||||
|
||||
[DllImport("kernel32", CharSet = CharSet.Unicode)]
|
||||
private static extern int GetPrivateProfileString(string section, string key, string def, StringBuilder retVal, int size, string filePath);
|
||||
|
||||
[DllImport("kernel32", CharSet = CharSet.Unicode)]
|
||||
private static extern int GetPrivateProfileString(string section, string key, string defVal, byte[] retVal, int size, string filePath);
|
||||
public void IniWriteValue(string Section, string Key, string Value)
|
||||
{
|
||||
WritePrivateProfileString(Section, Key, Value, path);
|
||||
}
|
||||
public string IniReadValue(string Section, string Key)
|
||||
{
|
||||
try
|
||||
{
|
||||
StringBuilder temp = new StringBuilder(255);
|
||||
int i = GetPrivateProfileString(Section, Key, "", temp, 255, path);
|
||||
return temp.ToString();
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
public byte[] IniReadValues(string section, string key)
|
||||
{
|
||||
byte[] temp = new byte[255];
|
||||
int i = GetPrivateProfileString(section, key, "", temp, 255, path);
|
||||
return temp;
|
||||
}
|
||||
|
||||
public void ClearAllSection()
|
||||
{
|
||||
IniWriteValue(null, null, null);
|
||||
}
|
||||
|
||||
public void ClearSection(string Section)
|
||||
{
|
||||
IniWriteValue(Section, null, null);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace PLCCommunication
|
||||
{
|
||||
public enum DataFormatType
|
||||
{
|
||||
/// <summary>
|
||||
/// 按照顺序排序
|
||||
/// </summary>
|
||||
ABCD,
|
||||
/// <summary>
|
||||
/// 按照单字反转
|
||||
/// </summary>
|
||||
BADC,
|
||||
/// <summary>
|
||||
/// 按照双字反转
|
||||
/// </summary>
|
||||
CDAB,
|
||||
/// <summary>
|
||||
/// 按照倒序排序
|
||||
/// </summary>
|
||||
DCBA
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,59 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace PLCCommunication
|
||||
{
|
||||
[Serializable]
|
||||
public class PLCConfig
|
||||
{
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public int Index;
|
||||
/// <summary>
|
||||
/// PLC IP地址
|
||||
/// </summary>
|
||||
public string IP;
|
||||
/// <summary>
|
||||
/// PLC端口号
|
||||
/// </summary>
|
||||
public int Port;
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
public int JobCount;
|
||||
/// <summary>
|
||||
/// 是否启用心跳消息
|
||||
/// </summary>
|
||||
public bool HeartBeat;
|
||||
/// <summary>
|
||||
/// 心跳设置地址
|
||||
/// </summary>
|
||||
public string HeartAddr;
|
||||
/// <summary>
|
||||
/// 扫描间隔时间
|
||||
/// </summary>
|
||||
public int ScanTime;
|
||||
/// <summary>
|
||||
/// 上位机的节点地址,假如你的电脑的Ip地址为192.168.1.30,那么这个值就是30
|
||||
/// </summary>
|
||||
public int SA1;
|
||||
/// <summary>
|
||||
/// PLC的插槽号,通常都为0
|
||||
/// </summary>
|
||||
public int Solt;
|
||||
/// <summary>
|
||||
/// 如果设置为True,当数据读取失败的时候,会自动变更当前的SA1值,会选择自动增加,但不会和DA1一致,本值需要在对象实例化之后立即设置。
|
||||
/// </summary>
|
||||
public bool ChangeSA1;
|
||||
/// <summary>
|
||||
/// 获取或设置在解析字符串的时候是否将字节按照字单位反转,获取或设置数据解析的格式,可选ABCD, BADC,CDAB,DCBA格式
|
||||
/// </summary>
|
||||
public int DataFormat;
|
||||
|
||||
public List<TriggerParams> lstTgrParams;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace PLCCommunication
|
||||
{
|
||||
public class TriggerParams
|
||||
{
|
||||
public int Index;
|
||||
|
||||
public string ThreadName;
|
||||
|
||||
public string TriggerAddr;
|
||||
|
||||
public string TriggerCmd;
|
||||
|
||||
public VarType TriggerType;
|
||||
|
||||
public string ResultAddr;
|
||||
|
||||
public VarType ResultType;
|
||||
|
||||
public bool IsRead;
|
||||
|
||||
public string ReadAddr;
|
||||
|
||||
public int ReadLength;
|
||||
|
||||
public VarType ReadType;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace PLCCommunication
|
||||
{
|
||||
public enum VarType
|
||||
{
|
||||
Bit,
|
||||
Short,
|
||||
Int,
|
||||
Float,
|
||||
String,
|
||||
Byte
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
+86
@@ -0,0 +1,86 @@
|
||||
|
||||
namespace PLCCommunication
|
||||
{
|
||||
partial class FrmOmronPLCCom
|
||||
{
|
||||
/// <summary>
|
||||
/// 必需的设计器变量。
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// 清理所有正在使用的资源。
|
||||
/// </summary>
|
||||
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if (disposing && (components != null))
|
||||
{
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region Windows 窗体设计器生成的代码
|
||||
|
||||
/// <summary>
|
||||
/// 设计器支持所需的方法 - 不要修改
|
||||
/// 使用代码编辑器修改此方法的内容。
|
||||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.tabCt_MePlcUI = new System.Windows.Forms.TabControl();
|
||||
this.tabPage1 = new System.Windows.Forms.TabPage();
|
||||
this.tabCt_MePlcUI.SuspendLayout();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// tabCt_MePlcUI
|
||||
//
|
||||
this.tabCt_MePlcUI.Controls.Add(this.tabPage1);
|
||||
this.tabCt_MePlcUI.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.tabCt_MePlcUI.ItemSize = new System.Drawing.Size(85, 28);
|
||||
this.tabCt_MePlcUI.Location = new System.Drawing.Point(0, 0);
|
||||
this.tabCt_MePlcUI.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.tabCt_MePlcUI.Name = "tabCt_MePlcUI";
|
||||
this.tabCt_MePlcUI.SelectedIndex = 0;
|
||||
this.tabCt_MePlcUI.Size = new System.Drawing.Size(1828, 974);
|
||||
this.tabCt_MePlcUI.SizeMode = System.Windows.Forms.TabSizeMode.Fixed;
|
||||
this.tabCt_MePlcUI.TabIndex = 1;
|
||||
//
|
||||
// tabPage1
|
||||
//
|
||||
this.tabPage1.Location = new System.Drawing.Point(4, 32);
|
||||
this.tabPage1.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.tabPage1.Name = "tabPage1";
|
||||
this.tabPage1.Padding = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.tabPage1.Size = new System.Drawing.Size(1820, 938);
|
||||
this.tabPage1.TabIndex = 0;
|
||||
this.tabPage1.Text = "1#通讯块";
|
||||
this.tabPage1.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// FrmOmronPLCCom
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 15F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.BackColor = System.Drawing.Color.White;
|
||||
this.ClientSize = new System.Drawing.Size(1828, 974);
|
||||
this.Controls.Add(this.tabCt_MePlcUI);
|
||||
this.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.MaximizeBox = false;
|
||||
this.Name = "FrmOmronPLCCom";
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
|
||||
this.Text = "欧姆龙PLC通讯";
|
||||
this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.FrmOmronPLCCom_FormClosing);
|
||||
this.tabCt_MePlcUI.ResumeLayout(false);
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
|
||||
#endregion
|
||||
private System.Windows.Forms.TabControl tabCt_MePlcUI;
|
||||
private System.Windows.Forms.TabPage tabPage1;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,217 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.IO;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace PLCCommunication
|
||||
{
|
||||
public partial class FrmOmronPLCCom : Form
|
||||
{
|
||||
/// <summary>
|
||||
/// 定义MelsecPLCUI自定义控件List集合
|
||||
/// </summary>
|
||||
public List<OmronPLCUI> lstMcUI = new List<OmronPLCUI>();
|
||||
/// <summary>
|
||||
/// 配置文件实体类
|
||||
/// </summary>
|
||||
private List<PLCConfig> lstPLCConfig = new List<PLCConfig>();
|
||||
/// <summary>
|
||||
/// PLC读取寄存器配置文件
|
||||
/// </summary>
|
||||
private string ConfigPath = Path.Combine(System.Windows.Forms.Application.StartupPath, "Config\\PlcConfig.ini");
|
||||
|
||||
/// <summary>
|
||||
/// 加载lstMcUI窗口次数
|
||||
/// </summary>
|
||||
private int ComCount;
|
||||
|
||||
public FrmOmronPLCCom(string path)
|
||||
{
|
||||
InitializeComponent();
|
||||
ConfigPath = path;
|
||||
ComCount = int.Parse(new IniHelper(ConfigPath).IniReadValue("SystemConfig", "ComCount"));
|
||||
ReadPlcConfig(ComCount);
|
||||
LoadUI(ComCount);
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 读取配置文件
|
||||
/// </summary>
|
||||
/// <param name="Count"></param>
|
||||
public void ReadPlcConfig(int Count)
|
||||
{
|
||||
try
|
||||
{
|
||||
for (int j = 0; j < Count; j++)
|
||||
{
|
||||
PLCConfig plcConfig = new PLCConfig();
|
||||
plcConfig.Index = j + 1;
|
||||
plcConfig.IP = new IniHelper(ConfigPath).IniReadValue(plcConfig.Index + "#PLCParameter", "IP");
|
||||
plcConfig.Port = int.Parse(new IniHelper(ConfigPath).IniReadValue(plcConfig.Index + "#PLCParameter", "Port"));
|
||||
plcConfig.JobCount = int.Parse(new IniHelper(ConfigPath).IniReadValue(plcConfig.Index + "#PLCParameter", "JobCount"));
|
||||
plcConfig.HeartBeat = bool.Parse(new IniHelper(ConfigPath).IniReadValue(plcConfig.Index + "#PLCParameter", "HeartBeat"));
|
||||
plcConfig.HeartAddr = new IniHelper(ConfigPath).IniReadValue(plcConfig.Index + "#PLCParameter", "HeartAddr");
|
||||
plcConfig.ScanTime = int.Parse(new IniHelper(ConfigPath).IniReadValue(plcConfig.Index + "#PLCParameter", "ScanTime"));
|
||||
plcConfig.Solt = int.Parse(new IniHelper(ConfigPath).IniReadValue(plcConfig.Index + "#PLCParameter", "Solt"));
|
||||
List<TriggerParams> lstTgrParamsTemp = new List<TriggerParams>();
|
||||
for (int i = 0; i < plcConfig.JobCount; i++)
|
||||
{
|
||||
TriggerParams trigger = new TriggerParams();
|
||||
trigger.Index = i + 1;
|
||||
trigger.ThreadName=new IniHelper(ConfigPath).IniReadValue(plcConfig.Index + "#PLCParameter", i + 1 + "#ThreadName");
|
||||
trigger.TriggerAddr = new IniHelper(ConfigPath).IniReadValue(plcConfig.Index + "#PLCParameter", i + 1 + "#RecvAddr");
|
||||
string recvType = new IniHelper(ConfigPath).IniReadValue(plcConfig.Index + "#PLCParameter", i + 1 + "#RecvType");
|
||||
trigger.TriggerType = (VarType)Enum.Parse(typeof(VarType), recvType, false);
|
||||
string bb = new IniHelper(ConfigPath).IniReadValue(plcConfig.Index + "#PLCParameter", i + 1 + "#IsRead");
|
||||
|
||||
if (bb == "True")
|
||||
{
|
||||
trigger.IsRead = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
trigger.IsRead = false;
|
||||
}
|
||||
|
||||
trigger.ReadAddr = new IniHelper(ConfigPath).IniReadValue(plcConfig.Index + "#PLCParameter", i + 1 + "#ReadAddr");
|
||||
trigger.ReadLength =Convert.ToInt16(new IniHelper(ConfigPath).IniReadValue(plcConfig.Index + "#PLCParameter", i + 1 + "#ReadLength"));
|
||||
string readType = new IniHelper(ConfigPath).IniReadValue(plcConfig.Index + "#PLCParameter", i + 1 + "#ReadType");
|
||||
trigger.ReadType = (VarType)Enum.Parse(typeof(VarType), readType, false);
|
||||
trigger.TriggerCmd = new IniHelper(ConfigPath).IniReadValue(plcConfig.Index + "#PLCParameter", i + 1 + "#TriggerCmd");
|
||||
trigger.ResultAddr = new IniHelper(ConfigPath).IniReadValue(plcConfig.Index + "#PLCParameter", i + 1 + "#WriteAddr");
|
||||
string writeype = new IniHelper(ConfigPath).IniReadValue(plcConfig.Index + "#PLCParameter", i + 1 + "#WriteType");
|
||||
trigger.ResultType = (VarType)Enum.Parse(typeof(VarType), writeype, false);
|
||||
lstTgrParamsTemp.Add(trigger);
|
||||
}
|
||||
plcConfig.lstTgrParams = lstTgrParamsTemp;
|
||||
lstPLCConfig.Add(plcConfig);
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
MessageBox.Show(ex.Message);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 加载MelsecPLCUI窗口
|
||||
/// </summary>
|
||||
/// <param name="Count"></param>
|
||||
public void LoadUI(int Count)
|
||||
{
|
||||
tabCt_MePlcUI.TabPages.Clear();
|
||||
for (int i = 0; i < Count; i++)
|
||||
{
|
||||
tabCt_MePlcUI.TabPages.Add(i + 1 + "#通讯模块");
|
||||
Panel panelUI = new Panel();
|
||||
panelUI.Dock = DockStyle.Fill;
|
||||
tabCt_MePlcUI.TabPages[i].Controls.Add(panelUI);
|
||||
OmronPLCUI plcUI = new OmronPLCUI(lstPLCConfig[i]);
|
||||
plcUI.Dock = DockStyle.Fill;
|
||||
plcUI.SaveParamsEvent += plcUI_SaveParamsEvent;
|
||||
lstMcUI.Add(plcUI);
|
||||
panelUI.Controls.Add(plcUI);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
#region 参数保存
|
||||
/// <summary>
|
||||
/// 循环保存参数
|
||||
/// </summary>
|
||||
/// <param name="plcIndex"></param>
|
||||
/// <param name="trgIndex"></param>
|
||||
private void plcUI_SaveParamsEvent(int plcIndex, int trgIndex)
|
||||
{
|
||||
if (trgIndex == 0)
|
||||
{
|
||||
for (int i = 0; i < lstMcUI[plcIndex - 1].JobCount; i++)
|
||||
{
|
||||
SaveTrgParam(plcIndex, i + 1, lstMcUI[plcIndex - 1].lstTrgUI[i].TrgParams);
|
||||
}
|
||||
SavePLCParam(plcIndex);
|
||||
}
|
||||
else
|
||||
{
|
||||
SaveTrgParam(plcIndex, trgIndex, lstMcUI[plcIndex - 1].lstTrgUI[trgIndex - 1].TrgParams);
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// 界面设置参数写入到配置文件
|
||||
/// </summary>
|
||||
/// <param name="plcIndex"></param>
|
||||
/// <param name="trgIndex"></param>
|
||||
/// <param name="triggerParams"></param>
|
||||
public void SaveTrgParam(int plcIndex, int trgIndex, TriggerParams triggerParams)
|
||||
{
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", trgIndex + "#RecvAddr", triggerParams.TriggerAddr);
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", trgIndex + "#RecvType", triggerParams.TriggerType.ToString());
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", trgIndex + "#WriteAddr", triggerParams.ResultAddr);
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", trgIndex + "#WriteType", triggerParams.ResultType.ToString());
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", trgIndex + "#TriggerCmd", triggerParams.TriggerCmd);
|
||||
if (triggerParams.IsRead)
|
||||
{
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", trgIndex + "#IsRead", "True");
|
||||
}
|
||||
else
|
||||
{
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", trgIndex + "#IsRead", "False");
|
||||
}
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", trgIndex + "#IsRead", triggerParams.IsRead==true?"True":"False");
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", trgIndex + "#ReadAddr", triggerParams.ReadAddr);
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", trgIndex + "#ReadType", triggerParams.ReadType.ToString());
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", trgIndex + "#ReadLength", triggerParams.ReadLength.ToString());
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
///
|
||||
/// </summary>
|
||||
/// <param name="plcIndex"></param>
|
||||
public void SavePLCParam(int plcIndex)
|
||||
{
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", "Index", lstMcUI[plcIndex - 1].PlcConfig.Index.ToString());
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", "IP", lstMcUI[plcIndex - 1].PlcConfig.IP.ToString());
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", "Port", lstMcUI[plcIndex - 1].PlcConfig.Port.ToString());
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", "JobCount", lstMcUI[plcIndex - 1].PlcConfig.JobCount.ToString());
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", "HeartBeat", lstMcUI[plcIndex - 1].PlcConfig.HeartBeat.ToString());
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", "HeartAddr", lstMcUI[plcIndex - 1].PlcConfig.HeartAddr.ToString());
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", "ScanTime", lstMcUI[plcIndex - 1].PlcConfig.ScanTime.ToString());
|
||||
new IniHelper(ConfigPath).IniWriteValue(plcIndex + "#PLCParameter", "Solt", lstMcUI[plcIndex - 1].PlcConfig.Solt.ToString());
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
/// <summary>
|
||||
/// 关闭lstMcUI窗口
|
||||
/// </summary>
|
||||
public void ShutDown()
|
||||
{
|
||||
for (int i = 0; i < ComCount; i++)
|
||||
{
|
||||
if (lstMcUI[i] != null)
|
||||
{
|
||||
lstMcUI[i].Shutdown();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 关闭本窗口
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
private void FrmOmronPLCCom_FormClosing(object sender, FormClosingEventArgs e)
|
||||
{
|
||||
this.Visible = false;
|
||||
e.Cancel = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,120 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
</root>
|
||||
Generated
+848
@@ -0,0 +1,848 @@
|
||||
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace PLCCommunication
|
||||
{
|
||||
partial class OmronPLCUI
|
||||
{
|
||||
/// <summary>
|
||||
/// 必需的设计器变量。
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// 清理所有正在使用的资源。
|
||||
/// </summary>
|
||||
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if (disposing && (components != null))
|
||||
{
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region 组件设计器生成的代码
|
||||
|
||||
/// <summary>
|
||||
/// 设计器支持所需的方法 - 不要修改
|
||||
/// 使用代码编辑器修改此方法的内容。
|
||||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.components = new System.ComponentModel.Container();
|
||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(OmronPLCUI));
|
||||
this.label2 = new System.Windows.Forms.Label();
|
||||
this.txtReadTestLength = new System.Windows.Forms.TextBox();
|
||||
this.txtWriteValue = new System.Windows.Forms.TextBox();
|
||||
this.cbTest = new System.Windows.Forms.CheckBox();
|
||||
this.label9 = new System.Windows.Forms.Label();
|
||||
this.groupBox3 = new System.Windows.Forms.GroupBox();
|
||||
this.lstResWrite = new System.Windows.Forms.ListView();
|
||||
this.columnHeader5 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
||||
this.columnHeader6 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
||||
this.imageList1 = new System.Windows.Forms.ImageList(this.components);
|
||||
this.lstSend = new System.Windows.Forms.ListView();
|
||||
this.columnHeader1 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
||||
this.columnHeader2 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
||||
this.groupBox2 = new System.Windows.Forms.GroupBox();
|
||||
this.btnClearRecv = new System.Windows.Forms.Button();
|
||||
this.cbDispCurrent = new System.Windows.Forms.CheckBox();
|
||||
this.lstTrgCmd = new System.Windows.Forms.ListView();
|
||||
this.columnHeader3 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
||||
this.columnHeader4 = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
||||
this.lstRecv = new System.Windows.Forms.ListView();
|
||||
this.InfoTime = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
||||
this.InfoContent = ((System.Windows.Forms.ColumnHeader)(new System.Windows.Forms.ColumnHeader()));
|
||||
this.button1 = new System.Windows.Forms.Button();
|
||||
this.txtReadResultTest = new System.Windows.Forms.TextBox();
|
||||
this.panel1 = new System.Windows.Forms.Panel();
|
||||
this.txtSolt = new System.Windows.Forms.TextBox();
|
||||
this.label4 = new System.Windows.Forms.Label();
|
||||
this.btnStart = new System.Windows.Forms.Button();
|
||||
this.btnSaveConfig = new System.Windows.Forms.Button();
|
||||
this.label1 = new System.Windows.Forms.Label();
|
||||
this.txtPort = new System.Windows.Forms.TextBox();
|
||||
this.label26 = new System.Windows.Forms.Label();
|
||||
this.txtIP = new System.Windows.Forms.TextBox();
|
||||
this.label27 = new System.Windows.Forms.Label();
|
||||
this.BtnDisConnect = new System.Windows.Forms.Button();
|
||||
this.BtnConnect = new System.Windows.Forms.Button();
|
||||
this.PanelTest = new System.Windows.Forms.Panel();
|
||||
this.lblTip = new System.Windows.Forms.Label();
|
||||
this.BtnWriteTest = new System.Windows.Forms.Button();
|
||||
this.label7 = new System.Windows.Forms.Label();
|
||||
this.cboReadType = new System.Windows.Forms.ComboBox();
|
||||
this.txtReadAddrTest = new System.Windows.Forms.TextBox();
|
||||
this.label6 = new System.Windows.Forms.Label();
|
||||
this.BtnReadTest = new System.Windows.Forms.Button();
|
||||
this.gb_RWTest = new System.Windows.Forms.GroupBox();
|
||||
this.groupBox4 = new System.Windows.Forms.GroupBox();
|
||||
this.label3 = new System.Windows.Forms.Label();
|
||||
this.txtHeartAddr = new System.Windows.Forms.TextBox();
|
||||
this.cbHeartBeat = new System.Windows.Forms.CheckBox();
|
||||
this.groupBox1 = new System.Windows.Forms.GroupBox();
|
||||
this.tabConTrgUI = new System.Windows.Forms.TabControl();
|
||||
this.skinTabPage1 = new System.Windows.Forms.TabPage();
|
||||
this.skinTabPage2 = new System.Windows.Forms.TabPage();
|
||||
this.lblConnectStatus = new System.Windows.Forms.PictureBox();
|
||||
this.groupBox3.SuspendLayout();
|
||||
this.groupBox2.SuspendLayout();
|
||||
this.panel1.SuspendLayout();
|
||||
this.PanelTest.SuspendLayout();
|
||||
this.gb_RWTest.SuspendLayout();
|
||||
this.groupBox4.SuspendLayout();
|
||||
this.groupBox1.SuspendLayout();
|
||||
this.tabConTrgUI.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.lblConnectStatus)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// label2
|
||||
//
|
||||
this.label2.AutoSize = true;
|
||||
this.label2.Font = new System.Drawing.Font("黑体", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||
this.label2.Location = new System.Drawing.Point(8, 198);
|
||||
this.label2.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
|
||||
this.label2.Name = "label2";
|
||||
this.label2.Size = new System.Drawing.Size(89, 20);
|
||||
this.label2.TabIndex = 24;
|
||||
this.label2.Text = "写入值:";
|
||||
//
|
||||
// txtReadTestLength
|
||||
//
|
||||
this.txtReadTestLength.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.txtReadTestLength.Location = new System.Drawing.Point(505, 124);
|
||||
this.txtReadTestLength.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.txtReadTestLength.Name = "txtReadTestLength";
|
||||
this.txtReadTestLength.Size = new System.Drawing.Size(153, 32);
|
||||
this.txtReadTestLength.TabIndex = 22;
|
||||
this.txtReadTestLength.Text = "1";
|
||||
//
|
||||
// txtWriteValue
|
||||
//
|
||||
this.txtWriteValue.Font = new System.Drawing.Font("宋体", 12F);
|
||||
this.txtWriteValue.Location = new System.Drawing.Point(111, 194);
|
||||
this.txtWriteValue.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.txtWriteValue.Name = "txtWriteValue";
|
||||
this.txtWriteValue.Size = new System.Drawing.Size(357, 30);
|
||||
this.txtWriteValue.TabIndex = 23;
|
||||
this.txtWriteValue.Text = "1";
|
||||
//
|
||||
// cbTest
|
||||
//
|
||||
this.cbTest.AutoSize = true;
|
||||
this.cbTest.Location = new System.Drawing.Point(156, 0);
|
||||
this.cbTest.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.cbTest.Name = "cbTest";
|
||||
this.cbTest.Size = new System.Drawing.Size(66, 21);
|
||||
this.cbTest.TabIndex = 13;
|
||||
this.cbTest.Text = "测试";
|
||||
this.cbTest.UseVisualStyleBackColor = true;
|
||||
this.cbTest.CheckedChanged += new System.EventHandler(this.cbTest_CheckedChanged);
|
||||
//
|
||||
// label9
|
||||
//
|
||||
this.label9.AutoSize = true;
|
||||
this.label9.Location = new System.Drawing.Point(501, 88);
|
||||
this.label9.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
|
||||
this.label9.Name = "label9";
|
||||
this.label9.Size = new System.Drawing.Size(120, 22);
|
||||
this.label9.TabIndex = 25;
|
||||
this.label9.Text = "读取长度:";
|
||||
//
|
||||
// groupBox3
|
||||
//
|
||||
this.groupBox3.Controls.Add(this.lstResWrite);
|
||||
this.groupBox3.Controls.Add(this.lstSend);
|
||||
this.groupBox3.Font = new System.Drawing.Font("黑体", 10F);
|
||||
this.groupBox3.Location = new System.Drawing.Point(727, 372);
|
||||
this.groupBox3.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.groupBox3.Name = "groupBox3";
|
||||
this.groupBox3.Padding = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.groupBox3.Size = new System.Drawing.Size(1085, 474);
|
||||
this.groupBox3.TabIndex = 18;
|
||||
this.groupBox3.TabStop = false;
|
||||
this.groupBox3.Text = "发送显示";
|
||||
//
|
||||
// lstResWrite
|
||||
//
|
||||
this.lstResWrite.BackColor = System.Drawing.SystemColors.Control;
|
||||
this.lstResWrite.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
|
||||
this.columnHeader5,
|
||||
this.columnHeader6});
|
||||
this.lstResWrite.Font = new System.Drawing.Font("宋体", 9F);
|
||||
this.lstResWrite.HeaderStyle = System.Windows.Forms.ColumnHeaderStyle.None;
|
||||
this.lstResWrite.HideSelection = false;
|
||||
this.lstResWrite.Location = new System.Drawing.Point(516, 16);
|
||||
this.lstResWrite.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.lstResWrite.Name = "lstResWrite";
|
||||
this.lstResWrite.Size = new System.Drawing.Size(551, 449);
|
||||
this.lstResWrite.SmallImageList = this.imageList1;
|
||||
this.lstResWrite.TabIndex = 23;
|
||||
this.lstResWrite.UseCompatibleStateImageBehavior = false;
|
||||
this.lstResWrite.View = System.Windows.Forms.View.Details;
|
||||
//
|
||||
// columnHeader5
|
||||
//
|
||||
this.columnHeader5.Width = 220;
|
||||
//
|
||||
// columnHeader6
|
||||
//
|
||||
this.columnHeader6.Width = 600;
|
||||
//
|
||||
// imageList1
|
||||
//
|
||||
this.imageList1.ImageStream = ((System.Windows.Forms.ImageListStreamer)(resources.GetObject("imageList1.ImageStream")));
|
||||
this.imageList1.TransparentColor = System.Drawing.Color.Transparent;
|
||||
this.imageList1.Images.SetKeyName(0, "info.png");
|
||||
this.imageList1.Images.SetKeyName(1, "error.png");
|
||||
//
|
||||
// lstSend
|
||||
//
|
||||
this.lstSend.BackColor = System.Drawing.SystemColors.Control;
|
||||
this.lstSend.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
|
||||
this.columnHeader1,
|
||||
this.columnHeader2});
|
||||
this.lstSend.Font = new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||
this.lstSend.HeaderStyle = System.Windows.Forms.ColumnHeaderStyle.None;
|
||||
this.lstSend.HideSelection = false;
|
||||
this.lstSend.Location = new System.Drawing.Point(3, 16);
|
||||
this.lstSend.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.lstSend.Name = "lstSend";
|
||||
this.lstSend.Size = new System.Drawing.Size(504, 449);
|
||||
this.lstSend.SmallImageList = this.imageList1;
|
||||
this.lstSend.TabIndex = 22;
|
||||
this.lstSend.UseCompatibleStateImageBehavior = false;
|
||||
this.lstSend.View = System.Windows.Forms.View.Details;
|
||||
//
|
||||
// columnHeader1
|
||||
//
|
||||
this.columnHeader1.Width = 220;
|
||||
//
|
||||
// columnHeader2
|
||||
//
|
||||
this.columnHeader2.Width = 400;
|
||||
//
|
||||
// groupBox2
|
||||
//
|
||||
this.groupBox2.Controls.Add(this.btnClearRecv);
|
||||
this.groupBox2.Controls.Add(this.cbDispCurrent);
|
||||
this.groupBox2.Controls.Add(this.lstTrgCmd);
|
||||
this.groupBox2.Controls.Add(this.lstRecv);
|
||||
this.groupBox2.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
|
||||
this.groupBox2.Font = new System.Drawing.Font("黑体", 10F);
|
||||
this.groupBox2.Location = new System.Drawing.Point(727, 71);
|
||||
this.groupBox2.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.groupBox2.Name = "groupBox2";
|
||||
this.groupBox2.Padding = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.groupBox2.Size = new System.Drawing.Size(1085, 294);
|
||||
this.groupBox2.TabIndex = 17;
|
||||
this.groupBox2.TabStop = false;
|
||||
this.groupBox2.Text = "接收显示";
|
||||
//
|
||||
// btnClearRecv
|
||||
//
|
||||
this.btnClearRecv.BackColor = System.Drawing.SystemColors.ControlDark;
|
||||
this.btnClearRecv.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
|
||||
this.btnClearRecv.Font = new System.Drawing.Font("黑体", 9F);
|
||||
this.btnClearRecv.Location = new System.Drawing.Point(257, -4);
|
||||
this.btnClearRecv.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.btnClearRecv.Name = "btnClearRecv";
|
||||
this.btnClearRecv.Size = new System.Drawing.Size(104, 28);
|
||||
this.btnClearRecv.TabIndex = 22;
|
||||
this.btnClearRecv.Text = "清空接收";
|
||||
this.btnClearRecv.UseVisualStyleBackColor = false;
|
||||
this.btnClearRecv.Click += new System.EventHandler(this.btnClearRecv_Click);
|
||||
//
|
||||
// cbDispCurrent
|
||||
//
|
||||
this.cbDispCurrent.AutoSize = true;
|
||||
this.cbDispCurrent.Location = new System.Drawing.Point(115, 0);
|
||||
this.cbDispCurrent.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.cbDispCurrent.Name = "cbDispCurrent";
|
||||
this.cbDispCurrent.Size = new System.Drawing.Size(102, 21);
|
||||
this.cbDispCurrent.TabIndex = 23;
|
||||
this.cbDispCurrent.Text = "显示实时";
|
||||
this.cbDispCurrent.UseVisualStyleBackColor = true;
|
||||
this.cbDispCurrent.CheckedChanged += new System.EventHandler(this.cbDispCurrent_CheckedChanged);
|
||||
//
|
||||
// lstTrgCmd
|
||||
//
|
||||
this.lstTrgCmd.BackColor = System.Drawing.SystemColors.Control;
|
||||
this.lstTrgCmd.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
|
||||
this.columnHeader3,
|
||||
this.columnHeader4});
|
||||
this.lstTrgCmd.Font = new System.Drawing.Font("宋体", 9F);
|
||||
this.lstTrgCmd.HeaderStyle = System.Windows.Forms.ColumnHeaderStyle.None;
|
||||
this.lstTrgCmd.HideSelection = false;
|
||||
this.lstTrgCmd.Location = new System.Drawing.Point(515, 28);
|
||||
this.lstTrgCmd.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.lstTrgCmd.Name = "lstTrgCmd";
|
||||
this.lstTrgCmd.Size = new System.Drawing.Size(561, 258);
|
||||
this.lstTrgCmd.SmallImageList = this.imageList1;
|
||||
this.lstTrgCmd.TabIndex = 22;
|
||||
this.lstTrgCmd.UseCompatibleStateImageBehavior = false;
|
||||
this.lstTrgCmd.View = System.Windows.Forms.View.Details;
|
||||
//
|
||||
// columnHeader3
|
||||
//
|
||||
this.columnHeader3.Width = 220;
|
||||
//
|
||||
// columnHeader4
|
||||
//
|
||||
this.columnHeader4.Width = 600;
|
||||
//
|
||||
// lstRecv
|
||||
//
|
||||
this.lstRecv.BackColor = System.Drawing.SystemColors.Control;
|
||||
this.lstRecv.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
|
||||
this.InfoTime,
|
||||
this.InfoContent});
|
||||
this.lstRecv.Font = new System.Drawing.Font("宋体", 9F);
|
||||
this.lstRecv.HeaderStyle = System.Windows.Forms.ColumnHeaderStyle.None;
|
||||
this.lstRecv.HideSelection = false;
|
||||
this.lstRecv.Location = new System.Drawing.Point(8, 28);
|
||||
this.lstRecv.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.lstRecv.Name = "lstRecv";
|
||||
this.lstRecv.Size = new System.Drawing.Size(499, 258);
|
||||
this.lstRecv.SmallImageList = this.imageList1;
|
||||
this.lstRecv.TabIndex = 21;
|
||||
this.lstRecv.UseCompatibleStateImageBehavior = false;
|
||||
this.lstRecv.View = System.Windows.Forms.View.Details;
|
||||
//
|
||||
// InfoTime
|
||||
//
|
||||
this.InfoTime.Width = 220;
|
||||
//
|
||||
// InfoContent
|
||||
//
|
||||
this.InfoContent.Width = 400;
|
||||
//
|
||||
// button1
|
||||
//
|
||||
this.button1.Location = new System.Drawing.Point(1004, 0);
|
||||
this.button1.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.button1.Name = "button1";
|
||||
this.button1.Size = new System.Drawing.Size(139, 44);
|
||||
this.button1.TabIndex = 34;
|
||||
this.button1.Text = "启动";
|
||||
this.button1.UseVisualStyleBackColor = true;
|
||||
this.button1.Visible = false;
|
||||
this.button1.Click += new System.EventHandler(this.button1_Click);
|
||||
//
|
||||
// txtReadResultTest
|
||||
//
|
||||
this.txtReadResultTest.Font = new System.Drawing.Font("宋体", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||
this.txtReadResultTest.Location = new System.Drawing.Point(111, 54);
|
||||
this.txtReadResultTest.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.txtReadResultTest.Multiline = true;
|
||||
this.txtReadResultTest.Name = "txtReadResultTest";
|
||||
this.txtReadResultTest.Size = new System.Drawing.Size(365, 105);
|
||||
this.txtReadResultTest.TabIndex = 19;
|
||||
//
|
||||
// panel1
|
||||
//
|
||||
this.panel1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
|
||||
this.panel1.Controls.Add(this.lblConnectStatus);
|
||||
this.panel1.Controls.Add(this.button1);
|
||||
this.panel1.Controls.Add(this.txtSolt);
|
||||
this.panel1.Controls.Add(this.label4);
|
||||
this.panel1.Controls.Add(this.btnStart);
|
||||
this.panel1.Controls.Add(this.btnSaveConfig);
|
||||
this.panel1.Controls.Add(this.label1);
|
||||
this.panel1.Controls.Add(this.txtPort);
|
||||
this.panel1.Controls.Add(this.label26);
|
||||
this.panel1.Controls.Add(this.txtIP);
|
||||
this.panel1.Controls.Add(this.label27);
|
||||
this.panel1.Controls.Add(this.BtnDisConnect);
|
||||
this.panel1.Controls.Add(this.BtnConnect);
|
||||
this.panel1.Font = new System.Drawing.Font("宋体", 9F);
|
||||
this.panel1.Location = new System.Drawing.Point(16, 5);
|
||||
this.panel1.Margin = new System.Windows.Forms.Padding(4, 5, 4, 5);
|
||||
this.panel1.Name = "panel1";
|
||||
this.panel1.Size = new System.Drawing.Size(1795, 56);
|
||||
this.panel1.TabIndex = 15;
|
||||
//
|
||||
// txtSolt
|
||||
//
|
||||
this.txtSolt.Font = new System.Drawing.Font("黑体", 12.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||
this.txtSolt.Location = new System.Drawing.Point(508, 15);
|
||||
this.txtSolt.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.txtSolt.Name = "txtSolt";
|
||||
this.txtSolt.Size = new System.Drawing.Size(71, 32);
|
||||
this.txtSolt.TabIndex = 26;
|
||||
this.txtSolt.Text = "0";
|
||||
//
|
||||
// label4
|
||||
//
|
||||
this.label4.AutoSize = true;
|
||||
this.label4.Font = new System.Drawing.Font("黑体", 12.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||
this.label4.Location = new System.Drawing.Point(417, 20);
|
||||
this.label4.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
|
||||
this.label4.Name = "label4";
|
||||
this.label4.Size = new System.Drawing.Size(76, 22);
|
||||
this.label4.TabIndex = 25;
|
||||
this.label4.Text = "Solt:";
|
||||
this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
|
||||
//
|
||||
// btnStart
|
||||
//
|
||||
this.btnStart.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.btnStart.Location = new System.Drawing.Point(787, 5);
|
||||
this.btnStart.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.btnStart.Name = "btnStart";
|
||||
this.btnStart.Size = new System.Drawing.Size(127, 44);
|
||||
this.btnStart.TabIndex = 24;
|
||||
this.btnStart.Text = "启动";
|
||||
this.btnStart.UseVisualStyleBackColor = true;
|
||||
this.btnStart.Click += new System.EventHandler(this.btnStart_Click);
|
||||
//
|
||||
// btnSaveConfig
|
||||
//
|
||||
this.btnSaveConfig.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.btnSaveConfig.Location = new System.Drawing.Point(617, 5);
|
||||
this.btnSaveConfig.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.btnSaveConfig.Name = "btnSaveConfig";
|
||||
this.btnSaveConfig.Size = new System.Drawing.Size(127, 44);
|
||||
this.btnSaveConfig.TabIndex = 23;
|
||||
this.btnSaveConfig.Text = "保存配置";
|
||||
this.btnSaveConfig.UseVisualStyleBackColor = true;
|
||||
this.btnSaveConfig.Click += new System.EventHandler(this.btnSaveConfig_Click);
|
||||
//
|
||||
// label1
|
||||
//
|
||||
this.label1.AutoSize = true;
|
||||
this.label1.Font = new System.Drawing.Font("黑体", 10F);
|
||||
this.label1.Location = new System.Drawing.Point(1169, 15);
|
||||
this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
|
||||
this.label1.Name = "label1";
|
||||
this.label1.Size = new System.Drawing.Size(98, 17);
|
||||
this.label1.TabIndex = 20;
|
||||
this.label1.Text = "连接状态:";
|
||||
//
|
||||
// txtPort
|
||||
//
|
||||
this.txtPort.Font = new System.Drawing.Font("黑体", 12.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||
this.txtPort.Location = new System.Drawing.Point(319, 15);
|
||||
this.txtPort.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.txtPort.Name = "txtPort";
|
||||
this.txtPort.Size = new System.Drawing.Size(71, 32);
|
||||
this.txtPort.TabIndex = 19;
|
||||
this.txtPort.Text = "44818";
|
||||
//
|
||||
// label26
|
||||
//
|
||||
this.label26.AutoSize = true;
|
||||
this.label26.Font = new System.Drawing.Font("黑体", 12.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||
this.label26.Location = new System.Drawing.Point(252, 22);
|
||||
this.label26.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
|
||||
this.label26.Name = "label26";
|
||||
this.label26.Size = new System.Drawing.Size(76, 22);
|
||||
this.label26.TabIndex = 18;
|
||||
this.label26.Text = "端口:";
|
||||
//
|
||||
// txtIP
|
||||
//
|
||||
this.txtIP.Font = new System.Drawing.Font("黑体", 12.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||
this.txtIP.Location = new System.Drawing.Point(84, 15);
|
||||
this.txtIP.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.txtIP.Name = "txtIP";
|
||||
this.txtIP.Size = new System.Drawing.Size(159, 32);
|
||||
this.txtIP.TabIndex = 17;
|
||||
this.txtIP.Text = "192.168.1.50";
|
||||
//
|
||||
// label27
|
||||
//
|
||||
this.label27.AutoSize = true;
|
||||
this.label27.Font = new System.Drawing.Font("黑体", 12.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||
this.label27.Location = new System.Drawing.Point(0, 20);
|
||||
this.label27.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
|
||||
this.label27.Name = "label27";
|
||||
this.label27.Size = new System.Drawing.Size(98, 22);
|
||||
this.label27.TabIndex = 16;
|
||||
this.label27.Text = "IP地址:";
|
||||
this.label27.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
|
||||
//
|
||||
// BtnDisConnect
|
||||
//
|
||||
this.BtnDisConnect.Enabled = false;
|
||||
this.BtnDisConnect.Font = new System.Drawing.Font("黑体", 12.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||
this.BtnDisConnect.Location = new System.Drawing.Point(1611, 4);
|
||||
this.BtnDisConnect.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.BtnDisConnect.Name = "BtnDisConnect";
|
||||
this.BtnDisConnect.Size = new System.Drawing.Size(127, 44);
|
||||
this.BtnDisConnect.TabIndex = 5;
|
||||
this.BtnDisConnect.Text = "断开连接";
|
||||
this.BtnDisConnect.UseVisualStyleBackColor = true;
|
||||
this.BtnDisConnect.Click += new System.EventHandler(this.BtnDisConnect_Click);
|
||||
//
|
||||
// BtnConnect
|
||||
//
|
||||
this.BtnConnect.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.BtnConnect.Location = new System.Drawing.Point(1459, 4);
|
||||
this.BtnConnect.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.BtnConnect.Name = "BtnConnect";
|
||||
this.BtnConnect.Size = new System.Drawing.Size(127, 44);
|
||||
this.BtnConnect.TabIndex = 4;
|
||||
this.BtnConnect.Text = "开始连接";
|
||||
this.BtnConnect.UseVisualStyleBackColor = true;
|
||||
this.BtnConnect.Click += new System.EventHandler(this.BtnConnect_Click);
|
||||
//
|
||||
// PanelTest
|
||||
//
|
||||
this.PanelTest.Controls.Add(this.txtWriteValue);
|
||||
this.PanelTest.Controls.Add(this.lblTip);
|
||||
this.PanelTest.Controls.Add(this.label9);
|
||||
this.PanelTest.Controls.Add(this.label2);
|
||||
this.PanelTest.Controls.Add(this.txtReadTestLength);
|
||||
this.PanelTest.Controls.Add(this.txtReadResultTest);
|
||||
this.PanelTest.Controls.Add(this.BtnWriteTest);
|
||||
this.PanelTest.Controls.Add(this.label7);
|
||||
this.PanelTest.Controls.Add(this.cboReadType);
|
||||
this.PanelTest.Controls.Add(this.txtReadAddrTest);
|
||||
this.PanelTest.Controls.Add(this.label6);
|
||||
this.PanelTest.Controls.Add(this.BtnReadTest);
|
||||
this.PanelTest.Font = new System.Drawing.Font("黑体", 12.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||
this.PanelTest.Location = new System.Drawing.Point(8, 36);
|
||||
this.PanelTest.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.PanelTest.Name = "PanelTest";
|
||||
this.PanelTest.Size = new System.Drawing.Size(681, 246);
|
||||
this.PanelTest.TabIndex = 1;
|
||||
//
|
||||
// lblTip
|
||||
//
|
||||
this.lblTip.AutoSize = true;
|
||||
this.lblTip.Location = new System.Drawing.Point(108, 169);
|
||||
this.lblTip.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
|
||||
this.lblTip.Name = "lblTip";
|
||||
this.lblTip.Size = new System.Drawing.Size(252, 22);
|
||||
this.lblTip.TabIndex = 26;
|
||||
this.lblTip.Text = "(多个写入时用\',\'隔开)";
|
||||
//
|
||||
// BtnWriteTest
|
||||
//
|
||||
this.BtnWriteTest.Location = new System.Drawing.Point(500, 194);
|
||||
this.BtnWriteTest.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.BtnWriteTest.Name = "BtnWriteTest";
|
||||
this.BtnWriteTest.Size = new System.Drawing.Size(160, 38);
|
||||
this.BtnWriteTest.TabIndex = 21;
|
||||
this.BtnWriteTest.Text = "写入";
|
||||
this.BtnWriteTest.UseVisualStyleBackColor = true;
|
||||
this.BtnWriteTest.Click += new System.EventHandler(this.BtnWriteTest_Click);
|
||||
//
|
||||
// label7
|
||||
//
|
||||
this.label7.AutoSize = true;
|
||||
this.label7.Font = new System.Drawing.Font("黑体", 12F);
|
||||
this.label7.Location = new System.Drawing.Point(23, 64);
|
||||
this.label7.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
|
||||
this.label7.Name = "label7";
|
||||
this.label7.Size = new System.Drawing.Size(69, 20);
|
||||
this.label7.TabIndex = 18;
|
||||
this.label7.Text = "结果:";
|
||||
//
|
||||
// cboReadType
|
||||
//
|
||||
this.cboReadType.FormattingEnabled = true;
|
||||
this.cboReadType.Location = new System.Drawing.Point(316, 14);
|
||||
this.cboReadType.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.cboReadType.Name = "cboReadType";
|
||||
this.cboReadType.Size = new System.Drawing.Size(160, 29);
|
||||
this.cboReadType.TabIndex = 17;
|
||||
//
|
||||
// txtReadAddrTest
|
||||
//
|
||||
this.txtReadAddrTest.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.txtReadAddrTest.Location = new System.Drawing.Point(112, 14);
|
||||
this.txtReadAddrTest.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.txtReadAddrTest.Name = "txtReadAddrTest";
|
||||
this.txtReadAddrTest.Size = new System.Drawing.Size(175, 32);
|
||||
this.txtReadAddrTest.TabIndex = 16;
|
||||
this.txtReadAddrTest.Text = "W1000";
|
||||
//
|
||||
// label6
|
||||
//
|
||||
this.label6.AutoSize = true;
|
||||
this.label6.Font = new System.Drawing.Font("黑体", 12F);
|
||||
this.label6.Location = new System.Drawing.Point(23, 16);
|
||||
this.label6.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
|
||||
this.label6.Name = "label6";
|
||||
this.label6.Size = new System.Drawing.Size(69, 20);
|
||||
this.label6.TabIndex = 15;
|
||||
this.label6.Text = "地址:";
|
||||
//
|
||||
// BtnReadTest
|
||||
//
|
||||
this.BtnReadTest.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.BtnReadTest.Location = new System.Drawing.Point(505, 8);
|
||||
this.BtnReadTest.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.BtnReadTest.Name = "BtnReadTest";
|
||||
this.BtnReadTest.Size = new System.Drawing.Size(159, 39);
|
||||
this.BtnReadTest.TabIndex = 20;
|
||||
this.BtnReadTest.Text = "读取";
|
||||
this.BtnReadTest.UseVisualStyleBackColor = true;
|
||||
this.BtnReadTest.Click += new System.EventHandler(this.BtnReadTest_Click);
|
||||
//
|
||||
// gb_RWTest
|
||||
//
|
||||
this.gb_RWTest.Controls.Add(this.PanelTest);
|
||||
this.gb_RWTest.Controls.Add(this.cbTest);
|
||||
this.gb_RWTest.Font = new System.Drawing.Font("黑体", 10F);
|
||||
this.gb_RWTest.Location = new System.Drawing.Point(16, 70);
|
||||
this.gb_RWTest.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.gb_RWTest.Name = "gb_RWTest";
|
||||
this.gb_RWTest.Padding = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.gb_RWTest.Size = new System.Drawing.Size(703, 295);
|
||||
this.gb_RWTest.TabIndex = 16;
|
||||
this.gb_RWTest.TabStop = false;
|
||||
this.gb_RWTest.Text = "读写测试";
|
||||
//
|
||||
// groupBox4
|
||||
//
|
||||
this.groupBox4.Controls.Add(this.label3);
|
||||
this.groupBox4.Controls.Add(this.txtHeartAddr);
|
||||
this.groupBox4.Controls.Add(this.cbHeartBeat);
|
||||
this.groupBox4.Font = new System.Drawing.Font("黑体", 10F);
|
||||
this.groupBox4.Location = new System.Drawing.Point(16, 781);
|
||||
this.groupBox4.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.groupBox4.Name = "groupBox4";
|
||||
this.groupBox4.Padding = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.groupBox4.Size = new System.Drawing.Size(703, 65);
|
||||
this.groupBox4.TabIndex = 20;
|
||||
this.groupBox4.TabStop = false;
|
||||
this.groupBox4.Text = "心跳包设置";
|
||||
//
|
||||
// label3
|
||||
//
|
||||
this.label3.AutoSize = true;
|
||||
this.label3.Font = new System.Drawing.Font("黑体", 10F);
|
||||
this.label3.Location = new System.Drawing.Point(44, 31);
|
||||
this.label3.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
|
||||
this.label3.Name = "label3";
|
||||
this.label3.Size = new System.Drawing.Size(116, 17);
|
||||
this.label3.TabIndex = 25;
|
||||
this.label3.Text = "心跳包地址:";
|
||||
//
|
||||
// txtHeartAddr
|
||||
//
|
||||
this.txtHeartAddr.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.txtHeartAddr.Location = new System.Drawing.Point(173, 24);
|
||||
this.txtHeartAddr.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.txtHeartAddr.Name = "txtHeartAddr";
|
||||
this.txtHeartAddr.Size = new System.Drawing.Size(149, 32);
|
||||
this.txtHeartAddr.TabIndex = 24;
|
||||
this.txtHeartAddr.Text = "W100";
|
||||
this.txtHeartAddr.TextChanged += new System.EventHandler(this.txtHeartAddr_TextChanged);
|
||||
//
|
||||
// cbHeartBeat
|
||||
//
|
||||
this.cbHeartBeat.AutoSize = true;
|
||||
this.cbHeartBeat.Location = new System.Drawing.Point(347, 29);
|
||||
this.cbHeartBeat.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.cbHeartBeat.Name = "cbHeartBeat";
|
||||
this.cbHeartBeat.Size = new System.Drawing.Size(66, 21);
|
||||
this.cbHeartBeat.TabIndex = 0;
|
||||
this.cbHeartBeat.Text = "启用";
|
||||
this.cbHeartBeat.UseVisualStyleBackColor = true;
|
||||
this.cbHeartBeat.CheckedChanged += new System.EventHandler(this.cbHeartBeat_CheckedChanged);
|
||||
//
|
||||
// groupBox1
|
||||
//
|
||||
this.groupBox1.Controls.Add(this.tabConTrgUI);
|
||||
this.groupBox1.Font = new System.Drawing.Font("黑体", 10F);
|
||||
this.groupBox1.Location = new System.Drawing.Point(16, 372);
|
||||
this.groupBox1.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.groupBox1.Name = "groupBox1";
|
||||
this.groupBox1.Padding = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.groupBox1.Size = new System.Drawing.Size(703, 399);
|
||||
this.groupBox1.TabIndex = 21;
|
||||
this.groupBox1.TabStop = false;
|
||||
this.groupBox1.Text = "参数设置";
|
||||
//
|
||||
// tabConTrgUI
|
||||
//
|
||||
this.tabConTrgUI.Controls.Add(this.skinTabPage1);
|
||||
this.tabConTrgUI.Controls.Add(this.skinTabPage2);
|
||||
this.tabConTrgUI.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.tabConTrgUI.Font = new System.Drawing.Font("宋体", 9F);
|
||||
this.tabConTrgUI.ItemSize = new System.Drawing.Size(85, 28);
|
||||
this.tabConTrgUI.Location = new System.Drawing.Point(4, 24);
|
||||
this.tabConTrgUI.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.tabConTrgUI.Name = "tabConTrgUI";
|
||||
this.tabConTrgUI.SelectedIndex = 0;
|
||||
this.tabConTrgUI.Size = new System.Drawing.Size(695, 371);
|
||||
this.tabConTrgUI.SizeMode = System.Windows.Forms.TabSizeMode.Fixed;
|
||||
this.tabConTrgUI.TabIndex = 0;
|
||||
//
|
||||
// skinTabPage1
|
||||
//
|
||||
this.skinTabPage1.BackColor = System.Drawing.Color.White;
|
||||
this.skinTabPage1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.skinTabPage1.Font = new System.Drawing.Font("宋体", 9F);
|
||||
this.skinTabPage1.Location = new System.Drawing.Point(4, 32);
|
||||
this.skinTabPage1.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.skinTabPage1.Name = "skinTabPage1";
|
||||
this.skinTabPage1.Size = new System.Drawing.Size(687, 335);
|
||||
this.skinTabPage1.TabIndex = 0;
|
||||
this.skinTabPage1.Text = "skinTabPage1";
|
||||
//
|
||||
// skinTabPage2
|
||||
//
|
||||
this.skinTabPage2.BackColor = System.Drawing.Color.White;
|
||||
this.skinTabPage2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.skinTabPage2.Font = new System.Drawing.Font("宋体", 9F);
|
||||
this.skinTabPage2.Location = new System.Drawing.Point(4, 32);
|
||||
this.skinTabPage2.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.skinTabPage2.Name = "skinTabPage2";
|
||||
this.skinTabPage2.Size = new System.Drawing.Size(687, 335);
|
||||
this.skinTabPage2.TabIndex = 1;
|
||||
this.skinTabPage2.Text = "skinTabPage2";
|
||||
//
|
||||
// lblConnectStatus
|
||||
//
|
||||
this.lblConnectStatus.Image = global::PLCCommunication.Properties.Resources.red;
|
||||
this.lblConnectStatus.Location = new System.Drawing.Point(1294, 3);
|
||||
this.lblConnectStatus.Name = "lblConnectStatus";
|
||||
this.lblConnectStatus.Size = new System.Drawing.Size(50, 50);
|
||||
this.lblConnectStatus.SizeMode = System.Windows.Forms.PictureBoxSizeMode.Zoom;
|
||||
this.lblConnectStatus.TabIndex = 35;
|
||||
this.lblConnectStatus.TabStop = false;
|
||||
//
|
||||
// OmronPLCUI
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 15F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.BackColor = System.Drawing.Color.White;
|
||||
this.Controls.Add(this.groupBox1);
|
||||
this.Controls.Add(this.groupBox2);
|
||||
this.Controls.Add(this.groupBox4);
|
||||
this.Controls.Add(this.groupBox3);
|
||||
this.Controls.Add(this.panel1);
|
||||
this.Controls.Add(this.gb_RWTest);
|
||||
this.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
|
||||
this.Name = "OmronPLCUI";
|
||||
this.Size = new System.Drawing.Size(1819, 856);
|
||||
this.Load += new System.EventHandler(this.MelsecPLCUI_Load);
|
||||
this.groupBox3.ResumeLayout(false);
|
||||
this.groupBox2.ResumeLayout(false);
|
||||
this.groupBox2.PerformLayout();
|
||||
this.panel1.ResumeLayout(false);
|
||||
this.panel1.PerformLayout();
|
||||
this.PanelTest.ResumeLayout(false);
|
||||
this.PanelTest.PerformLayout();
|
||||
this.gb_RWTest.ResumeLayout(false);
|
||||
this.gb_RWTest.PerformLayout();
|
||||
this.groupBox4.ResumeLayout(false);
|
||||
this.groupBox4.PerformLayout();
|
||||
this.groupBox1.ResumeLayout(false);
|
||||
this.tabConTrgUI.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.lblConnectStatus)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private Label label2;
|
||||
|
||||
private TextBox txtReadTestLength;
|
||||
|
||||
private TextBox txtWriteValue;
|
||||
|
||||
private CheckBox cbTest;
|
||||
|
||||
private Label label9;
|
||||
|
||||
private GroupBox groupBox3;
|
||||
|
||||
private GroupBox groupBox2;
|
||||
|
||||
private TextBox txtReadResultTest;
|
||||
|
||||
private Panel panel1;
|
||||
|
||||
private TextBox txtPort;
|
||||
|
||||
private Label label26;
|
||||
|
||||
private TextBox txtIP;
|
||||
|
||||
private Label label27;
|
||||
|
||||
private Button BtnDisConnect;
|
||||
|
||||
private Button BtnConnect;
|
||||
|
||||
private Panel PanelTest;
|
||||
|
||||
private Button BtnWriteTest;
|
||||
|
||||
private Label label7;
|
||||
|
||||
private ComboBox cboReadType;
|
||||
|
||||
private TextBox txtReadAddrTest;
|
||||
|
||||
private Label label6;
|
||||
|
||||
private Button BtnReadTest;
|
||||
|
||||
private GroupBox gb_RWTest;
|
||||
|
||||
private Label label1;
|
||||
|
||||
private GroupBox groupBox4;
|
||||
|
||||
private Label label3;
|
||||
|
||||
private TextBox txtHeartAddr;
|
||||
|
||||
private CheckBox cbHeartBeat;
|
||||
|
||||
private ListView lstSend;
|
||||
|
||||
private ColumnHeader columnHeader1;
|
||||
|
||||
private ColumnHeader columnHeader2;
|
||||
|
||||
private ListView lstRecv;
|
||||
|
||||
private ColumnHeader InfoTime;
|
||||
|
||||
private ColumnHeader InfoContent;
|
||||
|
||||
private ImageList imageList1;
|
||||
|
||||
private Button btnClearRecv;
|
||||
|
||||
private Label lblTip;
|
||||
|
||||
private GroupBox groupBox1;
|
||||
|
||||
private Button btnSaveConfig;
|
||||
|
||||
private ListView lstTrgCmd;
|
||||
|
||||
private ColumnHeader columnHeader3;
|
||||
|
||||
private ColumnHeader columnHeader4;
|
||||
|
||||
private ListView lstResWrite;
|
||||
|
||||
private ColumnHeader columnHeader5;
|
||||
|
||||
private ColumnHeader columnHeader6;
|
||||
|
||||
private CheckBox cbDispCurrent;
|
||||
|
||||
public Button btnStart;
|
||||
private System.Windows.Forms.TabControl tabConTrgUI;
|
||||
private System.Windows.Forms.TabPage skinTabPage1;
|
||||
private System.Windows.Forms.TabPage skinTabPage2;
|
||||
public Button button1;
|
||||
private TextBox txtSolt;
|
||||
private Label label4;
|
||||
private PictureBox lblConnectStatus;
|
||||
}
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,173 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<metadata name="imageList1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
<data name="imageList1.ImageStream" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>
|
||||
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj00LjAuMC4w
|
||||
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
|
||||
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAAAo
|
||||
CQAAAk1TRnQBSQFMAgEBAgEAAUgBAAFIAQABEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
|
||||
AwABQAMAARADAAEBAQABCAYAAQQYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA
|
||||
AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5
|
||||
AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA
|
||||
AWYDAAGZAwABzAIAATMDAAIzAgABMwFmAgABMwGZAgABMwHMAgABMwH/AgABZgMAAWYBMwIAAmYCAAFm
|
||||
AZkCAAFmAcwCAAFmAf8CAAGZAwABmQEzAgABmQFmAgACmQIAAZkBzAIAAZkB/wIAAcwDAAHMATMCAAHM
|
||||
AWYCAAHMAZkCAALMAgABzAH/AgAB/wFmAgAB/wGZAgAB/wHMAQABMwH/AgAB/wEAATMBAAEzAQABZgEA
|
||||
ATMBAAGZAQABMwEAAcwBAAEzAQAB/wEAAf8BMwIAAzMBAAIzAWYBAAIzAZkBAAIzAcwBAAIzAf8BAAEz
|
||||
AWYCAAEzAWYBMwEAATMCZgEAATMBZgGZAQABMwFmAcwBAAEzAWYB/wEAATMBmQIAATMBmQEzAQABMwGZ
|
||||
AWYBAAEzApkBAAEzAZkBzAEAATMBmQH/AQABMwHMAgABMwHMATMBAAEzAcwBZgEAATMBzAGZAQABMwLM
|
||||
AQABMwHMAf8BAAEzAf8BMwEAATMB/wFmAQABMwH/AZkBAAEzAf8BzAEAATMC/wEAAWYDAAFmAQABMwEA
|
||||
AWYBAAFmAQABZgEAAZkBAAFmAQABzAEAAWYBAAH/AQABZgEzAgABZgIzAQABZgEzAWYBAAFmATMBmQEA
|
||||
AWYBMwHMAQABZgEzAf8BAAJmAgACZgEzAQADZgEAAmYBmQEAAmYBzAEAAWYBmQIAAWYBmQEzAQABZgGZ
|
||||
AWYBAAFmApkBAAFmAZkBzAEAAWYBmQH/AQABZgHMAgABZgHMATMBAAFmAcwBmQEAAWYCzAEAAWYBzAH/
|
||||
AQABZgH/AgABZgH/ATMBAAFmAf8BmQEAAWYB/wHMAQABzAEAAf8BAAH/AQABzAEAApkCAAGZATMBmQEA
|
||||
AZkBAAGZAQABmQEAAcwBAAGZAwABmQIzAQABmQEAAWYBAAGZATMBzAEAAZkBAAH/AQABmQFmAgABmQFm
|
||||
ATMBAAGZATMBZgEAAZkBZgGZAQABmQFmAcwBAAGZATMB/wEAApkBMwEAApkBZgEAA5kBAAKZAcwBAAKZ
|
||||
Af8BAAGZAcwCAAGZAcwBMwEAAWYBzAFmAQABmQHMAZkBAAGZAswBAAGZAcwB/wEAAZkB/wIAAZkB/wEz
|
||||
AQABmQHMAWYBAAGZAf8BmQEAAZkB/wHMAQABmQL/AQABzAMAAZkBAAEzAQABzAEAAWYBAAHMAQABmQEA
|
||||
AcwBAAHMAQABmQEzAgABzAIzAQABzAEzAWYBAAHMATMBmQEAAcwBMwHMAQABzAEzAf8BAAHMAWYCAAHM
|
||||
AWYBMwEAAZkCZgEAAcwBZgGZAQABzAFmAcwBAAGZAWYB/wEAAcwBmQIAAcwBmQEzAQABzAGZAWYBAAHM
|
||||
ApkBAAHMAZkBzAEAAcwBmQH/AQACzAIAAswBMwEAAswBZgEAAswBmQEAA8wBAALMAf8BAAHMAf8CAAHM
|
||||
Af8BMwEAAZkB/wFmAQABzAH/AZkBAAHMAf8BzAEAAcwC/wEAAcwBAAEzAQAB/wEAAWYBAAH/AQABmQEA
|
||||
AcwBMwIAAf8CMwEAAf8BMwFmAQAB/wEzAZkBAAH/ATMBzAEAAf8BMwH/AQAB/wFmAgAB/wFmATMBAAHM
|
||||
AmYBAAH/AWYBmQEAAf8BZgHMAQABzAFmAf8BAAH/AZkCAAH/AZkBMwEAAf8BmQFmAQAB/wKZAQAB/wGZ
|
||||
AcwBAAH/AZkB/wEAAf8BzAIAAf8BzAEzAQAB/wHMAWYBAAH/AcwBmQEAAf8CzAEAAf8BzAH/AQAC/wEz
|
||||
AQABzAH/AWYBAAL/AZkBAAL/AcwBAAJmAf8BAAFmAf8BZgEAAWYC/wEAAf8CZgEAAf8BZgH/AQAC/wFm
|
||||
AQABIQEAAaUBAANfAQADdwEAA4YBAAOWAQADywEAA7IBAAPXAQAD3QEAA+MBAAPqAQAD8QEAA/gBAAHw
|
||||
AfsB/wEAAaQCoAEAA4ADAAH/AgAB/wMAAv8BAAH/AwAB/wEAAf8BAAL/AgAD/wUAAf8B8gHCAp4BwgHy
|
||||
Af8IAAH/ARoBBwJNAQcBGgH/JwAB8gGeBpcBngHyBgAB8wFNBiUBTQHzJQAMlwQADCUjAAEIDJcBCAIA
|
||||
AZkMJQGZIQAB/wHADJcBwAL/AU0CJQEWAfQBFgIlARYB9AEWAiUBTQH/IAAB8gSXAXgC9AF4BpcB8gEa
|
||||
AyUB9AEAAf8CFgH/AQAB9AMlARogAAEIA5cBeAT0AXgFlwEIAQcDJQEWAf8BAAL/AQAB/wEWAyUBByAA
|
||||
AXgClwF4AvQCeAL0AXgElwF4AUwEJQEWAf8CAAH/ARYEJQFMIAABngKXAfAB9AF4ApcBeAL0AXgDlwGe
|
||||
AUwEJQEWAf8CAAH/ARYEJQFMIAABwgiXAXgC9AF4ApcBwgEHAyUBFgH/AQAC/wEAAf8BFgMlAQcgAAHy
|
||||
CZcBeAH0AfAClwHyARoDJQH0AQAB/wIWAf8BAAH0AyUBGiAAAf8BngyXAZ4C/wFNAiUBFgH0ARYCJQEW
|
||||
AfQBFgIlAU0B/yEAAfIMlwHyAgABmQwlAZkjAAyXBAAMJSUAAQgBwAaXAcABCAYAAfMBTQYlAU0B8ycA
|
||||
Af8B8gEIAngBCAHyAf8IAAH/ARoBBwJNAQcBGgH/JAABQgFNAT4HAAE+AwABKAMAAUADAAEQAwABAQEA
|
||||
AQEFAAGAFwAD/wEAAfABDwHwAQ8EAAHgAQcB4AEHBAABwAEDAcABAwQAAYABAQGAAQEOAAEEASAGAAEC
|
||||
AUAGAAEBAYAGAAEBAYAGAAECAUAGAAEEASAMAAGAAQEBgAEBBAABwAEDAcABAwQAAeABBwHgAQcEAAHw
|
||||
AQ8B8AEPBAAL
|
||||
</value>
|
||||
</data>
|
||||
<metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>32</value>
|
||||
</metadata>
|
||||
</root>
|
||||
@@ -0,0 +1,118 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProjectGuid>{796C9DFE-1D66-4921-B998-C5FCF15C2983}</ProjectGuid>
|
||||
<OutputType>WinExe</OutputType>
|
||||
<RootNamespace>PLCCommunication</RootNamespace>
|
||||
<AssemblyName>PLCCommunication</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
|
||||
<Deterministic>true</Deterministic>
|
||||
<TargetFrameworkProfile />
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>..\..\..\..\JY.Inspection\</OutputPath>
|
||||
<DefineConstants>DEBUG;TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>TRACE</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="HslCommunication">
|
||||
<HintPath>..\JY.Inspection\Lib\HslCommunication.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="Microsoft.CSharp" />
|
||||
<Reference Include="System.Data" />
|
||||
<Reference Include="System.Deployment" />
|
||||
<Reference Include="System.Drawing" />
|
||||
<Reference Include="System.Net.Http" />
|
||||
<Reference Include="System.Windows.Forms" />
|
||||
<Reference Include="System.Xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="Common\DemoUtils.cs" />
|
||||
<Compile Include="Common\IniHelper.cs" />
|
||||
<Compile Include="Entity\DataFormatType.cs" />
|
||||
<Compile Include="Entity\PLCConfig.cs" />
|
||||
<Compile Include="Entity\TriggerParams.cs" />
|
||||
<Compile Include="Entity\VarType.cs" />
|
||||
<Compile Include="FrmOmronPLCCom.cs">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="FrmOmronPLCCom.Designer.cs">
|
||||
<DependentUpon>FrmOmronPLCCom.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="OmronPLCUI.cs">
|
||||
<SubType>UserControl</SubType>
|
||||
</Compile>
|
||||
<Compile Include="OmronPLCUI.Designer.cs">
|
||||
<DependentUpon>OmronPLCUI.cs</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Program.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<Compile Include="TriggerUI.cs">
|
||||
<SubType>UserControl</SubType>
|
||||
</Compile>
|
||||
<Compile Include="TriggerUI.Designer.cs">
|
||||
<DependentUpon>TriggerUI.cs</DependentUpon>
|
||||
</Compile>
|
||||
<EmbeddedResource Include="FrmOmronPLCCom.resx">
|
||||
<DependentUpon>FrmOmronPLCCom.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="OmronPLCUI.resx">
|
||||
<DependentUpon>OmronPLCUI.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Properties\Resources.resx">
|
||||
<Generator>ResXFileCodeGenerator</Generator>
|
||||
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
|
||||
<SubType>Designer</SubType>
|
||||
</EmbeddedResource>
|
||||
<Compile Include="Properties\Resources.Designer.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>Resources.resx</DependentUpon>
|
||||
<DesignTime>True</DesignTime>
|
||||
</Compile>
|
||||
<EmbeddedResource Include="TriggerUI.resx">
|
||||
<DependentUpon>TriggerUI.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<None Include="Properties\Settings.settings">
|
||||
<Generator>SettingsSingleFileGenerator</Generator>
|
||||
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
|
||||
</None>
|
||||
<Compile Include="Properties\Settings.Designer.cs">
|
||||
<AutoGen>True</AutoGen>
|
||||
<DependentUpon>Settings.settings</DependentUpon>
|
||||
<DesignTimeSharedInput>True</DesignTimeSharedInput>
|
||||
</Compile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="App.config" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Resources\green.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Resources\red.png" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
</Project>
|
||||
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<ProjectView>ProjectFiles</ProjectView>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
@@ -0,0 +1,22 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace PLCCommunication
|
||||
{
|
||||
static class Program
|
||||
{
|
||||
/// <summary>
|
||||
/// 应用程序的主入口点。
|
||||
/// </summary>
|
||||
[STAThread]
|
||||
static void Main()
|
||||
{
|
||||
Application.EnableVisualStyles();
|
||||
Application.SetCompatibleTextRenderingDefault(false);
|
||||
Application.Run(new Form());
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// 有关程序集的一般信息由以下
|
||||
// 控制。更改这些特性值可修改
|
||||
// 与程序集关联的信息。
|
||||
[assembly: AssemblyTitle("PLCCommunication")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("PLCCommunication")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2022")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// 将 ComVisible 设置为 false 会使此程序集中的类型
|
||||
//对 COM 组件不可见。如果需要从 COM 访问此程序集中的类型
|
||||
//请将此类型的 ComVisible 特性设置为 true。
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// 如果此项目向 COM 公开,则下列 GUID 用于类型库的 ID
|
||||
[assembly: Guid("796c9dfe-1d66-4921-b998-c5fcf15c2983")]
|
||||
|
||||
// 程序集的版本信息由下列四个值组成:
|
||||
//
|
||||
// 主版本
|
||||
// 次版本
|
||||
// 生成号
|
||||
// 修订号
|
||||
//
|
||||
//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值
|
||||
//通过使用 "*",如下所示:
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
||||
+83
@@ -0,0 +1,83 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码由工具生成。
|
||||
// 运行时版本:4.0.30319.42000
|
||||
//
|
||||
// 对此文件的更改可能会导致不正确的行为,并且如果
|
||||
// 重新生成代码,这些更改将会丢失。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace PLCCommunication.Properties {
|
||||
using System;
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// 一个强类型的资源类,用于查找本地化的字符串等。
|
||||
/// </summary>
|
||||
// 此类是由 StronglyTypedResourceBuilder
|
||||
// 类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。
|
||||
// 若要添加或移除成员,请编辑 .ResX 文件,然后重新运行 ResGen
|
||||
// (以 /str 作为命令选项),或重新生成 VS 项目。
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "17.0.0.0")]
|
||||
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
|
||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
internal class Resources {
|
||||
|
||||
private static global::System.Resources.ResourceManager resourceMan;
|
||||
|
||||
private static global::System.Globalization.CultureInfo resourceCulture;
|
||||
|
||||
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
|
||||
internal Resources() {
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 返回此类使用的缓存的 ResourceManager 实例。
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||
internal static global::System.Resources.ResourceManager ResourceManager {
|
||||
get {
|
||||
if (object.ReferenceEquals(resourceMan, null)) {
|
||||
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("PLCCommunication.Properties.Resources", typeof(Resources).Assembly);
|
||||
resourceMan = temp;
|
||||
}
|
||||
return resourceMan;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 重写当前线程的 CurrentUICulture 属性,对
|
||||
/// 使用此强类型资源类的所有资源查找执行重写。
|
||||
/// </summary>
|
||||
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
|
||||
internal static global::System.Globalization.CultureInfo Culture {
|
||||
get {
|
||||
return resourceCulture;
|
||||
}
|
||||
set {
|
||||
resourceCulture = value;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 查找 System.Drawing.Bitmap 类型的本地化资源。
|
||||
/// </summary>
|
||||
internal static System.Drawing.Bitmap green {
|
||||
get {
|
||||
object obj = ResourceManager.GetObject("green", resourceCulture);
|
||||
return ((System.Drawing.Bitmap)(obj));
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 查找 System.Drawing.Bitmap 类型的本地化资源。
|
||||
/// </summary>
|
||||
internal static System.Drawing.Bitmap red {
|
||||
get {
|
||||
object obj = ResourceManager.GetObject("red", resourceCulture);
|
||||
return ((System.Drawing.Bitmap)(obj));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,127 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
|
||||
<data name="green" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>..\Resources\green.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
<data name="red" type="System.Resources.ResXFileRef, System.Windows.Forms">
|
||||
<value>..\Resources\red.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a</value>
|
||||
</data>
|
||||
</root>
|
||||
+26
@@ -0,0 +1,26 @@
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// 此代码由工具生成。
|
||||
// 运行时版本:4.0.30319.42000
|
||||
//
|
||||
// 对此文件的更改可能会导致不正确的行为,并且如果
|
||||
// 重新生成代码,这些更改将会丢失。
|
||||
// </auto-generated>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace PLCCommunication.Properties {
|
||||
|
||||
|
||||
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
|
||||
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "17.11.0.0")]
|
||||
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
|
||||
|
||||
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
|
||||
|
||||
public static Settings Default {
|
||||
get {
|
||||
return defaultInstance;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
<?xml version='1.0' encoding='utf-8'?>
|
||||
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)">
|
||||
<Profiles>
|
||||
<Profile Name="(Default)" />
|
||||
</Profiles>
|
||||
<Settings />
|
||||
</SettingsFile>
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 1.5 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 2.3 KiB |
Generated
+297
@@ -0,0 +1,297 @@
|
||||
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace PLCCommunication
|
||||
{
|
||||
partial class TriggerUI
|
||||
{
|
||||
/// <summary>
|
||||
/// 必需的设计器变量。
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// 清理所有正在使用的资源。
|
||||
/// </summary>
|
||||
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
if (disposing && (components != null))
|
||||
{
|
||||
components.Dispose();
|
||||
}
|
||||
base.Dispose(disposing);
|
||||
}
|
||||
|
||||
#region 组件设计器生成的代码
|
||||
|
||||
/// <summary>
|
||||
/// 设计器支持所需的方法 - 不要修改
|
||||
/// 使用代码编辑器修改此方法的内容。
|
||||
/// </summary>
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.label8 = new System.Windows.Forms.Label();
|
||||
this.cbo_WriteType = new System.Windows.Forms.ComboBox();
|
||||
this.label11 = new System.Windows.Forms.Label();
|
||||
this.label10 = new System.Windows.Forms.Label();
|
||||
this.label5 = new System.Windows.Forms.Label();
|
||||
this.txtResultAddr = new System.Windows.Forms.TextBox();
|
||||
this.label4 = new System.Windows.Forms.Label();
|
||||
this.txtReadLength = new System.Windows.Forms.TextBox();
|
||||
this.label1 = new System.Windows.Forms.Label();
|
||||
this.txtReadAddr = new System.Windows.Forms.TextBox();
|
||||
this.label3 = new System.Windows.Forms.Label();
|
||||
this.label2 = new System.Windows.Forms.Label();
|
||||
this.cbIsRead = new System.Windows.Forms.CheckBox();
|
||||
this.cboReadType = new System.Windows.Forms.ComboBox();
|
||||
this.groupBox1 = new System.Windows.Forms.GroupBox();
|
||||
this.cboTriggerType = new System.Windows.Forms.ComboBox();
|
||||
this.txtTriggerAddr = new System.Windows.Forms.TextBox();
|
||||
this.txtTrrigerCommand = new System.Windows.Forms.TextBox();
|
||||
this.groupBox1.SuspendLayout();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// label8
|
||||
//
|
||||
this.label8.AutoSize = true;
|
||||
this.label8.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.label8.Location = new System.Drawing.Point(6, 53);
|
||||
this.label8.Name = "label8";
|
||||
this.label8.Size = new System.Drawing.Size(98, 17);
|
||||
this.label8.TabIndex = 50;
|
||||
this.label8.Text = "触发指令:";
|
||||
//
|
||||
// cbo_WriteType
|
||||
//
|
||||
this.cbo_WriteType.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.cbo_WriteType.FormattingEnabled = true;
|
||||
this.cbo_WriteType.Location = new System.Drawing.Point(373, 81);
|
||||
this.cbo_WriteType.Name = "cbo_WriteType";
|
||||
this.cbo_WriteType.Size = new System.Drawing.Size(101, 25);
|
||||
this.cbo_WriteType.TabIndex = 49;
|
||||
this.cbo_WriteType.SelectedIndexChanged += new System.EventHandler(this.cbo_WriteType_SelectedIndexChanged);
|
||||
//
|
||||
// label11
|
||||
//
|
||||
this.label11.AutoSize = true;
|
||||
this.label11.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.label11.Location = new System.Drawing.Point(276, 84);
|
||||
this.label11.Name = "label11";
|
||||
this.label11.Size = new System.Drawing.Size(98, 17);
|
||||
this.label11.TabIndex = 48;
|
||||
this.label11.Text = "写入类型:";
|
||||
//
|
||||
// label10
|
||||
//
|
||||
this.label10.AutoSize = true;
|
||||
this.label10.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.label10.Location = new System.Drawing.Point(277, 22);
|
||||
this.label10.Name = "label10";
|
||||
this.label10.Size = new System.Drawing.Size(98, 17);
|
||||
this.label10.TabIndex = 47;
|
||||
this.label10.Text = "接收类型:";
|
||||
//
|
||||
// label5
|
||||
//
|
||||
this.label5.AutoSize = true;
|
||||
this.label5.Font = new System.Drawing.Font("黑体", 12.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
|
||||
this.label5.Location = new System.Drawing.Point(6, 23);
|
||||
this.label5.Name = "label5";
|
||||
this.label5.Size = new System.Drawing.Size(134, 17);
|
||||
this.label5.TabIndex = 44;
|
||||
this.label5.Text = "接收触发地址:";
|
||||
//
|
||||
// txtResultAddr
|
||||
//
|
||||
this.txtResultAddr.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.txtResultAddr.Location = new System.Drawing.Point(170, 81);
|
||||
this.txtResultAddr.Name = "txtResultAddr";
|
||||
this.txtResultAddr.Size = new System.Drawing.Size(97, 27);
|
||||
this.txtResultAddr.TabIndex = 43;
|
||||
this.txtResultAddr.Text = "D4960";
|
||||
this.txtResultAddr.TextChanged += new System.EventHandler(this.txtResultAddr_TextChanged);
|
||||
//
|
||||
// label4
|
||||
//
|
||||
this.label4.AutoSize = true;
|
||||
this.label4.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.label4.Location = new System.Drawing.Point(6, 85);
|
||||
this.label4.Name = "label4";
|
||||
this.label4.Size = new System.Drawing.Size(170, 17);
|
||||
this.label4.TabIndex = 42;
|
||||
this.label4.Text = "结果写入起始地址:";
|
||||
//
|
||||
// txtReadLength
|
||||
//
|
||||
this.txtReadLength.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.txtReadLength.Location = new System.Drawing.Point(177, 49);
|
||||
this.txtReadLength.Name = "txtReadLength";
|
||||
this.txtReadLength.Size = new System.Drawing.Size(45, 27);
|
||||
this.txtReadLength.TabIndex = 56;
|
||||
this.txtReadLength.Text = "1";
|
||||
this.txtReadLength.TextChanged += new System.EventHandler(this.txtReadLength_TextChanged);
|
||||
//
|
||||
// label1
|
||||
//
|
||||
this.label1.AutoSize = true;
|
||||
this.label1.Font = new System.Drawing.Font("黑体", 10F);
|
||||
this.label1.Location = new System.Drawing.Point(162, 29);
|
||||
this.label1.Name = "label1";
|
||||
this.label1.Size = new System.Drawing.Size(63, 14);
|
||||
this.label1.TabIndex = 55;
|
||||
this.label1.Text = "接收长度";
|
||||
//
|
||||
// txtReadAddr
|
||||
//
|
||||
this.txtReadAddr.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.txtReadAddr.Location = new System.Drawing.Point(36, 49);
|
||||
this.txtReadAddr.Name = "txtReadAddr";
|
||||
this.txtReadAddr.Size = new System.Drawing.Size(97, 27);
|
||||
this.txtReadAddr.TabIndex = 53;
|
||||
this.txtReadAddr.Text = "D4610";
|
||||
this.txtReadAddr.TextChanged += new System.EventHandler(this.txtReadAddr_TextChanged);
|
||||
//
|
||||
// label3
|
||||
//
|
||||
this.label3.AutoSize = true;
|
||||
this.label3.Font = new System.Drawing.Font("黑体", 10F);
|
||||
this.label3.Location = new System.Drawing.Point(293, 29);
|
||||
this.label3.Name = "label3";
|
||||
this.label3.Size = new System.Drawing.Size(63, 14);
|
||||
this.label3.TabIndex = 58;
|
||||
this.label3.Text = "接收类型";
|
||||
//
|
||||
// label2
|
||||
//
|
||||
this.label2.AutoSize = true;
|
||||
this.label2.Font = new System.Drawing.Font("黑体", 10F);
|
||||
this.label2.Location = new System.Drawing.Point(11, 29);
|
||||
this.label2.Name = "label2";
|
||||
this.label2.Size = new System.Drawing.Size(119, 14);
|
||||
this.label2.TabIndex = 52;
|
||||
this.label2.Text = "批量读取起始地址";
|
||||
//
|
||||
// cbIsRead
|
||||
//
|
||||
this.cbIsRead.AutoSize = true;
|
||||
this.cbIsRead.Font = new System.Drawing.Font("黑体", 10F);
|
||||
this.cbIsRead.Location = new System.Drawing.Point(406, 49);
|
||||
this.cbIsRead.Name = "cbIsRead";
|
||||
this.cbIsRead.Size = new System.Drawing.Size(54, 18);
|
||||
this.cbIsRead.TabIndex = 59;
|
||||
this.cbIsRead.Text = "启用";
|
||||
this.cbIsRead.UseVisualStyleBackColor = true;
|
||||
this.cbIsRead.CheckedChanged += new System.EventHandler(this.cbIsRead_CheckedChanged);
|
||||
//
|
||||
// cboReadType
|
||||
//
|
||||
this.cboReadType.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.cboReadType.FormattingEnabled = true;
|
||||
this.cboReadType.Location = new System.Drawing.Point(283, 51);
|
||||
this.cboReadType.Name = "cboReadType";
|
||||
this.cboReadType.Size = new System.Drawing.Size(94, 25);
|
||||
this.cboReadType.TabIndex = 57;
|
||||
this.cboReadType.SelectedIndexChanged += new System.EventHandler(this.cboReadType_SelectedIndexChanged);
|
||||
//
|
||||
// groupBox1
|
||||
//
|
||||
this.groupBox1.Controls.Add(this.cboReadType);
|
||||
this.groupBox1.Controls.Add(this.cbIsRead);
|
||||
this.groupBox1.Controls.Add(this.label2);
|
||||
this.groupBox1.Controls.Add(this.label3);
|
||||
this.groupBox1.Controls.Add(this.txtReadAddr);
|
||||
this.groupBox1.Controls.Add(this.label1);
|
||||
this.groupBox1.Controls.Add(this.txtReadLength);
|
||||
this.groupBox1.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.groupBox1.Location = new System.Drawing.Point(14, 148);
|
||||
this.groupBox1.Name = "groupBox1";
|
||||
this.groupBox1.Size = new System.Drawing.Size(477, 86);
|
||||
this.groupBox1.TabIndex = 60;
|
||||
this.groupBox1.TabStop = false;
|
||||
this.groupBox1.Text = "批量读取PLC数据";
|
||||
//
|
||||
// cboTriggerType
|
||||
//
|
||||
this.cboTriggerType.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.cboTriggerType.FormattingEnabled = true;
|
||||
this.cboTriggerType.Location = new System.Drawing.Point(373, 19);
|
||||
this.cboTriggerType.Name = "cboTriggerType";
|
||||
this.cboTriggerType.Size = new System.Drawing.Size(101, 25);
|
||||
this.cboTriggerType.TabIndex = 46;
|
||||
this.cboTriggerType.SelectedIndexChanged += new System.EventHandler(this.cboTriggerType_SelectedIndexChanged);
|
||||
//
|
||||
// txtTriggerAddr
|
||||
//
|
||||
this.txtTriggerAddr.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.txtTriggerAddr.Location = new System.Drawing.Point(170, 19);
|
||||
this.txtTriggerAddr.Name = "txtTriggerAddr";
|
||||
this.txtTriggerAddr.Size = new System.Drawing.Size(97, 27);
|
||||
this.txtTriggerAddr.TabIndex = 45;
|
||||
this.txtTriggerAddr.Text = "D4610";
|
||||
this.txtTriggerAddr.TextChanged += new System.EventHandler(this.txtTriggerAddr_TextChanged);
|
||||
//
|
||||
// txtTrrigerCommand
|
||||
//
|
||||
this.txtTrrigerCommand.Font = new System.Drawing.Font("黑体", 12.75F);
|
||||
this.txtTrrigerCommand.Location = new System.Drawing.Point(170, 50);
|
||||
this.txtTrrigerCommand.Name = "txtTrrigerCommand";
|
||||
this.txtTrrigerCommand.Size = new System.Drawing.Size(97, 27);
|
||||
this.txtTrrigerCommand.TabIndex = 51;
|
||||
this.txtTrrigerCommand.Text = "1";
|
||||
this.txtTrrigerCommand.TextChanged += new System.EventHandler(this.txtTrrigerCommand_TextChanged);
|
||||
//
|
||||
// TriggerUI
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.BackColor = System.Drawing.Color.White;
|
||||
this.Controls.Add(this.cboTriggerType);
|
||||
this.Controls.Add(this.txtTrrigerCommand);
|
||||
this.Controls.Add(this.groupBox1);
|
||||
this.Controls.Add(this.label8);
|
||||
this.Controls.Add(this.cbo_WriteType);
|
||||
this.Controls.Add(this.label11);
|
||||
this.Controls.Add(this.label10);
|
||||
this.Controls.Add(this.txtTriggerAddr);
|
||||
this.Controls.Add(this.label5);
|
||||
this.Controls.Add(this.txtResultAddr);
|
||||
this.Controls.Add(this.label4);
|
||||
this.Name = "TriggerUI";
|
||||
this.Size = new System.Drawing.Size(513, 244);
|
||||
this.Load += new System.EventHandler(this.TriggerUI_Load);
|
||||
this.groupBox1.ResumeLayout(false);
|
||||
this.groupBox1.PerformLayout();
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private Label label8;
|
||||
|
||||
private ComboBox cbo_WriteType;
|
||||
|
||||
private Label label11;
|
||||
|
||||
private Label label10;
|
||||
|
||||
private Label label5;
|
||||
|
||||
private TextBox txtResultAddr;
|
||||
|
||||
private Label label4;
|
||||
private TextBox txtReadLength;
|
||||
private Label label1;
|
||||
private TextBox txtReadAddr;
|
||||
private Label label3;
|
||||
private Label label2;
|
||||
private CheckBox cbIsRead;
|
||||
private ComboBox cboReadType;
|
||||
private GroupBox groupBox1;
|
||||
private ComboBox cboTriggerType;
|
||||
private TextBox txtTriggerAddr;
|
||||
private TextBox txtTrrigerCommand;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,120 @@
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace PLCCommunication
|
||||
{
|
||||
public partial class TriggerUI : UserControl
|
||||
{
|
||||
public delegate void TrgParamChangeHandler(int Index);
|
||||
|
||||
public TriggerParams TrgParams = new TriggerParams();
|
||||
|
||||
public event TrgParamChangeHandler TrgParamChangeEvent;
|
||||
|
||||
public TriggerUI()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
public TriggerUI(TriggerParams _trgParam)
|
||||
{
|
||||
InitializeComponent();
|
||||
cbo_WriteType.DataSource = Enum.GetNames(typeof(VarType));
|
||||
cboTriggerType.DataSource = Enum.GetNames(typeof(VarType));
|
||||
cboReadType.DataSource = Enum.GetNames(typeof(VarType));
|
||||
TrgParams = _trgParam;
|
||||
}
|
||||
|
||||
private void TriggerUI_Load(object sender, EventArgs e)
|
||||
{
|
||||
txtResultAddr.Text = TrgParams.ResultAddr;
|
||||
txtTriggerAddr.Text = TrgParams.TriggerAddr;
|
||||
txtTrrigerCommand.Text = TrgParams.TriggerCmd;
|
||||
txtReadAddr.Text = TrgParams.ReadAddr;
|
||||
txtReadLength.Text =TrgParams.ReadLength.ToString();
|
||||
cboReadType.Text = TrgParams.ReadType.ToString();
|
||||
cbo_WriteType.Text = TrgParams.ResultType.ToString();
|
||||
cboTriggerType.Text = TrgParams.TriggerType.ToString();
|
||||
cbIsRead.Checked = TrgParams.IsRead;
|
||||
}
|
||||
|
||||
private void cbo_WriteType_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
TrgParams.ResultType = (VarType)Enum.Parse(typeof(VarType), cbo_WriteType.SelectedItem.ToString(), false);
|
||||
OnTrgParamChange(TrgParams.Index);
|
||||
}
|
||||
|
||||
private void cboTriggerType_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
TrgParams.TriggerType = (VarType)Enum.Parse(typeof(VarType), cboTriggerType.SelectedItem.ToString(), false);
|
||||
OnTrgParamChange(TrgParams.Index);
|
||||
}
|
||||
|
||||
private void txtResultAddr_TextChanged(object sender, EventArgs e)
|
||||
{
|
||||
TrgParams.ResultAddr = txtResultAddr.Text;
|
||||
OnTrgParamChange(TrgParams.Index);
|
||||
}
|
||||
|
||||
private void txtTriggerAddr_TextChanged(object sender, EventArgs e)
|
||||
{
|
||||
TrgParams.TriggerAddr = txtTriggerAddr.Text;
|
||||
OnTrgParamChange(TrgParams.Index);
|
||||
}
|
||||
|
||||
private void txtTrrigerCommand_TextChanged(object sender, EventArgs e)
|
||||
{
|
||||
TrgParams.TriggerCmd = txtTrrigerCommand.Text;
|
||||
OnTrgParamChange(TrgParams.Index);
|
||||
}
|
||||
|
||||
public void OnTrgParamChange(int Index)
|
||||
{
|
||||
if (this.TrgParamChangeEvent != null)
|
||||
{
|
||||
this.TrgParamChangeEvent(Index);
|
||||
}
|
||||
}
|
||||
|
||||
private void txtReadAddr_TextChanged(object sender, EventArgs e)
|
||||
{
|
||||
TrgParams.ReadAddr = txtReadAddr.Text;
|
||||
OnTrgParamChange(TrgParams.Index);
|
||||
}
|
||||
|
||||
private void txtReadLength_TextChanged(object sender, EventArgs e)
|
||||
{
|
||||
TrgParams.ReadLength =int.Parse( txtReadLength.Text.Trim());
|
||||
OnTrgParamChange(TrgParams.Index);
|
||||
}
|
||||
|
||||
private void cboReadType_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
TrgParams.ReadType = (VarType)Enum.Parse(typeof(VarType), cboReadType.SelectedItem.ToString(), false);
|
||||
OnTrgParamChange(TrgParams.Index);
|
||||
}
|
||||
|
||||
private void cbIsRead_CheckedChanged(object sender, EventArgs e)
|
||||
{
|
||||
if (cbIsRead.Checked)
|
||||
{
|
||||
TrgParams.IsRead = true;
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
TrgParams.IsRead = false;
|
||||
}
|
||||
|
||||
OnTrgParamChange(TrgParams.Index);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,120 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
</root>
|
||||
Reference in New Issue
Block a user