25111901 更换MES库文件

This commit is contained in:
moxiliang
2025-11-19 15:38:36 +08:00
parent 9f04271ae9
commit 25630cfdc1
158 changed files with 79259 additions and 87 deletions

Binary file not shown.

Binary file not shown.

View File

@@ -0,0 +1,78 @@
{
"Version": 1,
"WorkspaceRootPath": "D:\\\u684C\u9762\\\u83AB\u79A7\u4EAE\\\u534E\u8D1D\\\u6B63\u8D1F\u538B28\\\u6B63\u8D1F\u538B LL-28\\LL-28\\MES\u5BF9\u63A5\\\u534E\u64CE\u5BF9\u63A5\u8D44\u6599\\c#_demo\\C#\\",
"Documents": [
{
"AbsoluteMoniker": "D:0:0:{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}|MEStest\\MEStest.csproj|d:\\\u684C\u9762\\\u83AB\u79A7\u4EAE\\\u534E\u8D1D\\\u6B63\u8D1F\u538B28\\\u6B63\u8D1F\u538B ll-28\\ll-28\\mes\u5BF9\u63A5\\\u534E\u64CE\u5BF9\u63A5\u8D44\u6599\\c#_demo\\c#\\mestest\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}|Form",
"RelativeMoniker": "D:0:0:{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}|MEStest\\MEStest.csproj|solutionrelative:mestest\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}|Form"
}
],
"DocumentGroupContainers": [
{
"Orientation": 0,
"VerticalTabListWidth": 256,
"DocumentGroups": [
{
"DockedWidth": 200,
"SelectedChildIndex": 7,
"Children": [
{
"$type": "Bookmark",
"Name": "ST:130:0:{1fc202d4-d401-403c-9834-5b218574bb67}"
},
{
"$type": "Bookmark",
"Name": "ST:0:0:{e506b91c-c606-466a-90a9-123d1d1e12b3}"
},
{
"$type": "Bookmark",
"Name": "ST:0:0:{34e76e81-ee4a-11d0-ae2e-00a0c90fffc3}"
},
{
"$type": "Bookmark",
"Name": "ST:0:0:{6324226f-61b6-4f28-92ee-18d4b5fe1e48}"
},
{
"$type": "Bookmark",
"Name": "ST:1139089979:0:{71f361cc-493f-47c0-923f-f2570b6f8618}"
},
{
"$type": "Bookmark",
"Name": "ST:1330258491:0:{71f361cc-493f-47c0-923f-f2570b6f8618}"
},
{
"$type": "Bookmark",
"Name": "ST:254354193:0:{71f361cc-493f-47c0-923f-f2570b6f8618}"
},
{
"$type": "Document",
"DocumentIndex": 0,
"Title": "Form1.cs [\u8BBE\u8BA1]",
"DocumentMoniker": "D:\\\u684C\u9762\\\u83AB\u79A7\u4EAE\\\u534E\u8D1D\\\u6B63\u8D1F\u538B28\\\u6B63\u8D1F\u538B LL-28\\LL-28\\MES\u5BF9\u63A5\\\u534E\u64CE\u5BF9\u63A5\u8D44\u6599\\c#_demo\\C#\\MEStest\\Form1.cs",
"RelativeDocumentMoniker": "MEStest\\Form1.cs",
"ToolTip": "D:\\\u684C\u9762\\\u83AB\u79A7\u4EAE\\\u534E\u8D1D\\\u6B63\u8D1F\u538B28\\\u6B63\u8D1F\u538B LL-28\\LL-28\\MES\u5BF9\u63A5\\\u534E\u64CE\u5BF9\u63A5\u8D44\u6599\\c#_demo\\C#\\MEStest\\Form1.cs [\u8BBE\u8BA1]",
"RelativeToolTip": "MEStest\\Form1.cs [\u8BBE\u8BA1]",
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
"WhenOpened": "2025-11-19T06:44:52.887Z",
"EditorCaption": " [\u8BBE\u8BA1]"
},
{
"$type": "Bookmark",
"Name": "ST:0:0:{5a4e9529-b6a0-46b5-be4f-0f0b239bc0eb}"
}
]
},
{
"DockedWidth": 58,
"SelectedChildIndex": -1,
"Children": [
{
"$type": "Bookmark",
"Name": "ST:323948898:0:{81164725-9a96-4ece-a4cb-440d8fd285e5}"
}
]
}
]
}
]
}

View File

@@ -0,0 +1,95 @@
{
"Version": 1,
"WorkspaceRootPath": "D:\\\u684C\u9762\\\u83AB\u79A7\u4EAE\\\u534E\u8D1D\\\u6B63\u8D1F\u538B28\\\u6B63\u8D1F\u538B LL-28\\LL-28\\MES\u5BF9\u63A5\\\u534E\u64CE\u5BF9\u63A5\u8D44\u6599\\c#_demo\\C#\\",
"Documents": [
{
"AbsoluteMoniker": "D:0:0:{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}|MEStest\\MEStest.csproj|d:\\\u684C\u9762\\\u83AB\u79A7\u4EAE\\\u534E\u8D1D\\\u6B63\u8D1F\u538B28\\\u6B63\u8D1F\u538B ll-28\\ll-28\\mes\u5BF9\u63A5\\\u534E\u64CE\u5BF9\u63A5\u8D44\u6599\\c#_demo\\c#\\mestest\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
"RelativeMoniker": "D:0:0:{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}|MEStest\\MEStest.csproj|solutionrelative:mestest\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
},
{
"AbsoluteMoniker": "D:0:0:{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}|MEStest\\MEStest.csproj|d:\\\u684C\u9762\\\u83AB\u79A7\u4EAE\\\u534E\u8D1D\\\u6B63\u8D1F\u538B28\\\u6B63\u8D1F\u538B ll-28\\ll-28\\mes\u5BF9\u63A5\\\u534E\u64CE\u5BF9\u63A5\u8D44\u6599\\c#_demo\\c#\\mestest\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}|Form",
"RelativeMoniker": "D:0:0:{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}|MEStest\\MEStest.csproj|solutionrelative:mestest\\form1.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}|Form"
}
],
"DocumentGroupContainers": [
{
"Orientation": 0,
"VerticalTabListWidth": 256,
"DocumentGroups": [
{
"DockedWidth": 200,
"SelectedChildIndex": 7,
"Children": [
{
"$type": "Bookmark",
"Name": "ST:130:0:{1fc202d4-d401-403c-9834-5b218574bb67}"
},
{
"$type": "Bookmark",
"Name": "ST:0:0:{e506b91c-c606-466a-90a9-123d1d1e12b3}"
},
{
"$type": "Bookmark",
"Name": "ST:0:0:{34e76e81-ee4a-11d0-ae2e-00a0c90fffc3}"
},
{
"$type": "Bookmark",
"Name": "ST:0:0:{6324226f-61b6-4f28-92ee-18d4b5fe1e48}"
},
{
"$type": "Bookmark",
"Name": "ST:1139089979:0:{71f361cc-493f-47c0-923f-f2570b6f8618}"
},
{
"$type": "Bookmark",
"Name": "ST:1330258491:0:{71f361cc-493f-47c0-923f-f2570b6f8618}"
},
{
"$type": "Bookmark",
"Name": "ST:254354193:0:{71f361cc-493f-47c0-923f-f2570b6f8618}"
},
{
"$type": "Document",
"DocumentIndex": 0,
"Title": "Form1.cs",
"DocumentMoniker": "D:\\\u684C\u9762\\\u83AB\u79A7\u4EAE\\\u534E\u8D1D\\\u6B63\u8D1F\u538B28\\\u6B63\u8D1F\u538B LL-28\\LL-28\\MES\u5BF9\u63A5\\\u534E\u64CE\u5BF9\u63A5\u8D44\u6599\\c#_demo\\C#\\MEStest\\Form1.cs",
"RelativeDocumentMoniker": "MEStest\\Form1.cs",
"ToolTip": "D:\\\u684C\u9762\\\u83AB\u79A7\u4EAE\\\u534E\u8D1D\\\u6B63\u8D1F\u538B28\\\u6B63\u8D1F\u538B LL-28\\LL-28\\MES\u5BF9\u63A5\\\u534E\u64CE\u5BF9\u63A5\u8D44\u6599\\c#_demo\\C#\\MEStest\\Form1.cs",
"RelativeToolTip": "MEStest\\Form1.cs",
"ViewState": "AQIAAP8AAAAAAAAAAAA1wA0BAAAmAAAA",
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
"WhenOpened": "2025-11-19T06:51:52.039Z",
"EditorCaption": ""
},
{
"$type": "Document",
"DocumentIndex": 1,
"Title": "Form1.cs [\u8BBE\u8BA1]",
"DocumentMoniker": "D:\\\u684C\u9762\\\u83AB\u79A7\u4EAE\\\u534E\u8D1D\\\u6B63\u8D1F\u538B28\\\u6B63\u8D1F\u538B LL-28\\LL-28\\MES\u5BF9\u63A5\\\u534E\u64CE\u5BF9\u63A5\u8D44\u6599\\c#_demo\\C#\\MEStest\\Form1.cs",
"RelativeDocumentMoniker": "MEStest\\Form1.cs",
"ToolTip": "D:\\\u684C\u9762\\\u83AB\u79A7\u4EAE\\\u534E\u8D1D\\\u6B63\u8D1F\u538B28\\\u6B63\u8D1F\u538B LL-28\\LL-28\\MES\u5BF9\u63A5\\\u534E\u64CE\u5BF9\u63A5\u8D44\u6599\\c#_demo\\C#\\MEStest\\Form1.cs [\u8BBE\u8BA1]",
"RelativeToolTip": "MEStest\\Form1.cs [\u8BBE\u8BA1]",
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
"WhenOpened": "2025-11-19T06:51:46.3Z",
"EditorCaption": " [\u8BBE\u8BA1]"
},
{
"$type": "Bookmark",
"Name": "ST:0:0:{5a4e9529-b6a0-46b5-be4f-0f0b239bc0eb}"
}
]
},
{
"DockedWidth": 58,
"SelectedChildIndex": -1,
"Children": [
{
"$type": "Bookmark",
"Name": "ST:323948898:0:{81164725-9a96-4ece-a4cb-440d8fd285e5}"
}
]
}
]
}
]
}

View File

@@ -0,0 +1,20 @@

Microsoft Visual Studio Solution File, Format Version 11.00
# Visual Studio 2010
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MEStest", "MEStest\MEStest.csproj", "{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|x86 = Debug|x86
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}.Debug|x86.ActiveCfg = Debug|x86
{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}.Debug|x86.Build.0 = Debug|x86
{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}.Release|x86.ActiveCfg = Release|x86
{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}.Release|x86.Build.0 = Release|x86
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
EndGlobal

Binary file not shown.

View File

@@ -0,0 +1,310 @@
namespace MEStest
{
partial class Form1
{
/// <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.label20 = new System.Windows.Forms.Label();
this.tBTool = new System.Windows.Forms.TextBox();
this.label13 = new System.Windows.Forms.Label();
this.tBStationHand = new System.Windows.Forms.TextBox();
this.label9 = new System.Windows.Forms.Label();
this.tBSN = new System.Windows.Forms.TextBox();
this.label1 = new System.Windows.Forms.Label();
this.btMesSet = new System.Windows.Forms.Button();
this.btMesGet = new System.Windows.Forms.Button();
this.btMesUnInit = new System.Windows.Forms.Button();
this.btMesEnd = new System.Windows.Forms.Button();
this.btMesStart = new System.Windows.Forms.Button();
this.btMesInit = new System.Windows.Forms.Button();
this.MultiMesStart = new System.Windows.Forms.Button();
this.button1 = new System.Windows.Forms.Button();
this.button2 = new System.Windows.Forms.Button();
this.label2 = new System.Windows.Forms.Label();
this.textBox1 = new System.Windows.Forms.TextBox();
this.label3 = new System.Windows.Forms.Label();
this.textBox2 = new System.Windows.Forms.TextBox();
this.textBox3 = new System.Windows.Forms.TextBox();
this.SuspendLayout();
//
// label20
//
this.label20.AutoSize = true;
this.label20.ImeMode = System.Windows.Forms.ImeMode.NoControl;
this.label20.Location = new System.Drawing.Point(51, 97);
this.label20.Name = "label20";
this.label20.Size = new System.Drawing.Size(59, 12);
this.label20.TabIndex = 62;
this.label20.Text = "ErrCode";
//
// tBTool
//
this.tBTool.Location = new System.Drawing.Point(104, 63);
this.tBTool.Name = "tBTool";
this.tBTool.Size = new System.Drawing.Size(112, 21);
this.tBTool.TabIndex = 61;
//
// label13
//
this.label13.AutoSize = true;
this.label13.ImeMode = System.Windows.Forms.ImeMode.NoControl;
this.label13.Location = new System.Drawing.Point(51, 70);
this.label13.Name = "label13";
this.label13.Size = new System.Drawing.Size(41, 12);
this.label13.TabIndex = 60;
this.label13.Text = "工具:";
//
// tBStationHand
//
this.tBStationHand.Location = new System.Drawing.Point(104, 36);
this.tBStationHand.Name = "tBStationHand";
this.tBStationHand.Size = new System.Drawing.Size(112, 21);
this.tBStationHand.TabIndex = 59;
//
// label9
//
this.label9.AutoSize = true;
this.label9.ImeMode = System.Windows.Forms.ImeMode.NoControl;
this.label9.Location = new System.Drawing.Point(51, 43);
this.label9.Name = "label9";
this.label9.Size = new System.Drawing.Size(41, 12);
this.label9.TabIndex = 58;
this.label9.Text = "工位:";
//
// tBSN
//
this.tBSN.Location = new System.Drawing.Point(104, 9);
this.tBSN.Name = "tBSN";
this.tBSN.Size = new System.Drawing.Size(112, 21);
this.tBSN.TabIndex = 57;
//
// label1
//
this.label1.AutoSize = true;
this.label1.ImeMode = System.Windows.Forms.ImeMode.NoControl;
this.label1.Location = new System.Drawing.Point(51, 16);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(29, 12);
this.label1.TabIndex = 56;
this.label1.Text = "SN";
//
// btMesSet
//
this.btMesSet.Location = new System.Drawing.Point(151, 247);
this.btMesSet.Name = "btMesSet";
this.btMesSet.Size = new System.Drawing.Size(85, 25);
this.btMesSet.TabIndex = 55;
this.btMesSet.Text = "btMesSet";
this.btMesSet.UseVisualStyleBackColor = true;
this.btMesSet.Click += new System.EventHandler(this.btMesSet_Click);
//
// btMesGet
//
this.btMesGet.Location = new System.Drawing.Point(51, 244);
this.btMesGet.Name = "btMesGet";
this.btMesGet.Size = new System.Drawing.Size(85, 25);
this.btMesGet.TabIndex = 54;
this.btMesGet.Text = "btMesGet";
this.btMesGet.UseVisualStyleBackColor = true;
this.btMesGet.Click += new System.EventHandler(this.btMesGet_Click);
//
// btMesUnInit
//
this.btMesUnInit.BackColor = System.Drawing.SystemColors.Highlight;
this.btMesUnInit.Location = new System.Drawing.Point(151, 275);
this.btMesUnInit.Name = "btMesUnInit";
this.btMesUnInit.Size = new System.Drawing.Size(85, 25);
this.btMesUnInit.TabIndex = 53;
this.btMesUnInit.Text = "btMesUnInit";
this.btMesUnInit.UseVisualStyleBackColor = false;
this.btMesUnInit.Click += new System.EventHandler(this.btMesUnInit_Click);
//
// btMesEnd
//
this.btMesEnd.BackColor = System.Drawing.SystemColors.Highlight;
this.btMesEnd.Location = new System.Drawing.Point(49, 275);
this.btMesEnd.Name = "btMesEnd";
this.btMesEnd.Size = new System.Drawing.Size(85, 25);
this.btMesEnd.TabIndex = 52;
this.btMesEnd.Text = "btMesEnd";
this.btMesEnd.UseVisualStyleBackColor = false;
this.btMesEnd.Click += new System.EventHandler(this.btMesEnd_Click);
//
// btMesStart
//
this.btMesStart.BackColor = System.Drawing.SystemColors.Highlight;
this.btMesStart.Location = new System.Drawing.Point(151, 216);
this.btMesStart.Name = "btMesStart";
this.btMesStart.Size = new System.Drawing.Size(85, 25);
this.btMesStart.TabIndex = 51;
this.btMesStart.Text = "btMesStart";
this.btMesStart.UseVisualStyleBackColor = false;
this.btMesStart.Click += new System.EventHandler(this.btMesStart_Click);
//
// btMesInit
//
this.btMesInit.BackColor = System.Drawing.SystemColors.Highlight;
this.btMesInit.Location = new System.Drawing.Point(51, 216);
this.btMesInit.Name = "btMesInit";
this.btMesInit.Size = new System.Drawing.Size(85, 25);
this.btMesInit.TabIndex = 50;
this.btMesInit.Text = "btMesInit";
this.btMesInit.UseVisualStyleBackColor = false;
this.btMesInit.Click += new System.EventHandler(this.btMesInit_Click);
//
// MultiMesStart
//
this.MultiMesStart.Location = new System.Drawing.Point(151, 306);
this.MultiMesStart.Name = "MultiMesStart";
this.MultiMesStart.Size = new System.Drawing.Size(85, 25);
this.MultiMesStart.TabIndex = 64;
this.MultiMesStart.Text = "MultiMesStart";
this.MultiMesStart.UseVisualStyleBackColor = true;
this.MultiMesStart.Click += new System.EventHandler(this.button1_Click);
//
// button1
//
this.button1.BackColor = System.Drawing.SystemColors.Highlight;
this.button1.Location = new System.Drawing.Point(51, 337);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(75, 23);
this.button1.TabIndex = 65;
this.button1.Text = "btMesEnd2";
this.button1.UseVisualStyleBackColor = false;
this.button1.Click += new System.EventHandler(this.button1_Click_1);
//
// button2
//
this.button2.BackColor = System.Drawing.SystemColors.Highlight;
this.button2.Location = new System.Drawing.Point(53, 308);
this.button2.Name = "button2";
this.button2.Size = new System.Drawing.Size(83, 23);
this.button2.TabIndex = 66;
this.button2.Text = "btMesStart2";
this.button2.UseVisualStyleBackColor = false;
this.button2.Click += new System.EventHandler(this.button2_Click);
//
// label2
//
this.label2.AutoSize = true;
this.label2.Location = new System.Drawing.Point(12, 126);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(95, 12);
this.label2.TabIndex = 67;
this.label2.Text = "ErrDescription:";
this.label2.Click += new System.EventHandler(this.label2_Click);
//
// textBox1
//
this.textBox1.Location = new System.Drawing.Point(104, 123);
this.textBox1.Name = "textBox1";
this.textBox1.Size = new System.Drawing.Size(203, 21);
this.textBox1.TabIndex = 68;
//
// label3
//
this.label3.AutoSize = true;
this.label3.Location = new System.Drawing.Point(12, 155);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(53, 12);
this.label3.TabIndex = 69;
this.label3.Text = "Alldata:";
//
// textBox2
//
this.textBox2.Location = new System.Drawing.Point(62, 150);
this.textBox2.Name = "textBox2";
this.textBox2.Size = new System.Drawing.Size(245, 21);
this.textBox2.TabIndex = 70;
//
// textBox3
//
this.textBox3.Location = new System.Drawing.Point(104, 94);
this.textBox3.Name = "textBox3";
this.textBox3.Size = new System.Drawing.Size(100, 21);
this.textBox3.TabIndex = 71;
//
// Form1
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(319, 394);
this.Controls.Add(this.textBox3);
this.Controls.Add(this.textBox2);
this.Controls.Add(this.label3);
this.Controls.Add(this.textBox1);
this.Controls.Add(this.label2);
this.Controls.Add(this.button2);
this.Controls.Add(this.button1);
this.Controls.Add(this.MultiMesStart);
this.Controls.Add(this.label20);
this.Controls.Add(this.tBTool);
this.Controls.Add(this.label13);
this.Controls.Add(this.tBStationHand);
this.Controls.Add(this.label9);
this.Controls.Add(this.tBSN);
this.Controls.Add(this.label1);
this.Controls.Add(this.btMesSet);
this.Controls.Add(this.btMesGet);
this.Controls.Add(this.btMesUnInit);
this.Controls.Add(this.btMesEnd);
this.Controls.Add(this.btMesStart);
this.Controls.Add(this.btMesInit);
this.Name = "Form1";
this.Text = "Form1";
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.Label label20;
private System.Windows.Forms.TextBox tBTool;
private System.Windows.Forms.Label label13;
private System.Windows.Forms.TextBox tBStationHand;
private System.Windows.Forms.Label label9;
private System.Windows.Forms.TextBox tBSN;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Button btMesSet;
private System.Windows.Forms.Button btMesGet;
private System.Windows.Forms.Button btMesUnInit;
private System.Windows.Forms.Button btMesEnd;
private System.Windows.Forms.Button btMesStart;
private System.Windows.Forms.Button btMesInit;
private System.Windows.Forms.Button MultiMesStart;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.Button button2;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.TextBox textBox1;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.TextBox textBox2;
private System.Windows.Forms.TextBox textBox3;
}
}

View File

@@ -0,0 +1,310 @@
namespace MEStest
{
partial class Form1
{
/// <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.label20 = new System.Windows.Forms.Label();
this.tBTool = new System.Windows.Forms.TextBox();
this.label13 = new System.Windows.Forms.Label();
this.tBStationHand = new System.Windows.Forms.TextBox();
this.label9 = new System.Windows.Forms.Label();
this.tBSN = new System.Windows.Forms.TextBox();
this.label1 = new System.Windows.Forms.Label();
this.btMesSet = new System.Windows.Forms.Button();
this.btMesGet = new System.Windows.Forms.Button();
this.btMesUnInit = new System.Windows.Forms.Button();
this.btMesEnd = new System.Windows.Forms.Button();
this.btMesStart = new System.Windows.Forms.Button();
this.btMesInit = new System.Windows.Forms.Button();
this.MultiMesStart = new System.Windows.Forms.Button();
this.button1 = new System.Windows.Forms.Button();
this.button2 = new System.Windows.Forms.Button();
this.label2 = new System.Windows.Forms.Label();
this.textBox1 = new System.Windows.Forms.TextBox();
this.label3 = new System.Windows.Forms.Label();
this.textBox2 = new System.Windows.Forms.TextBox();
this.textBox3 = new System.Windows.Forms.TextBox();
this.SuspendLayout();
//
// label20
//
this.label20.AutoSize = true;
this.label20.ImeMode = System.Windows.Forms.ImeMode.NoControl;
this.label20.Location = new System.Drawing.Point(51, 97);
this.label20.Name = "label20";
this.label20.Size = new System.Drawing.Size(59, 12);
this.label20.TabIndex = 62;
this.label20.Text = "ErrCode";
//
// tBTool
//
this.tBTool.Location = new System.Drawing.Point(104, 63);
this.tBTool.Name = "tBTool";
this.tBTool.Size = new System.Drawing.Size(112, 21);
this.tBTool.TabIndex = 61;
//
// label13
//
this.label13.AutoSize = true;
this.label13.ImeMode = System.Windows.Forms.ImeMode.NoControl;
this.label13.Location = new System.Drawing.Point(51, 70);
this.label13.Name = "label13";
this.label13.Size = new System.Drawing.Size(41, 12);
this.label13.TabIndex = 60;
this.label13.Text = "工具:";
//
// tBStationHand
//
this.tBStationHand.Location = new System.Drawing.Point(104, 36);
this.tBStationHand.Name = "tBStationHand";
this.tBStationHand.Size = new System.Drawing.Size(112, 21);
this.tBStationHand.TabIndex = 59;
//
// label9
//
this.label9.AutoSize = true;
this.label9.ImeMode = System.Windows.Forms.ImeMode.NoControl;
this.label9.Location = new System.Drawing.Point(51, 43);
this.label9.Name = "label9";
this.label9.Size = new System.Drawing.Size(41, 12);
this.label9.TabIndex = 58;
this.label9.Text = "工位:";
//
// tBSN
//
this.tBSN.Location = new System.Drawing.Point(104, 9);
this.tBSN.Name = "tBSN";
this.tBSN.Size = new System.Drawing.Size(112, 21);
this.tBSN.TabIndex = 57;
//
// label1
//
this.label1.AutoSize = true;
this.label1.ImeMode = System.Windows.Forms.ImeMode.NoControl;
this.label1.Location = new System.Drawing.Point(51, 16);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(29, 12);
this.label1.TabIndex = 56;
this.label1.Text = "SN";
//
// btMesSet
//
this.btMesSet.Location = new System.Drawing.Point(151, 247);
this.btMesSet.Name = "btMesSet";
this.btMesSet.Size = new System.Drawing.Size(85, 25);
this.btMesSet.TabIndex = 55;
this.btMesSet.Text = "btMesSet";
this.btMesSet.UseVisualStyleBackColor = true;
this.btMesSet.Click += new System.EventHandler(this.btMesSet_Click);
//
// btMesGet
//
this.btMesGet.Location = new System.Drawing.Point(51, 244);
this.btMesGet.Name = "btMesGet";
this.btMesGet.Size = new System.Drawing.Size(85, 25);
this.btMesGet.TabIndex = 54;
this.btMesGet.Text = "btMesGet";
this.btMesGet.UseVisualStyleBackColor = true;
this.btMesGet.Click += new System.EventHandler(this.btMesGet_Click);
//
// btMesUnInit
//
this.btMesUnInit.BackColor = System.Drawing.SystemColors.Highlight;
this.btMesUnInit.Location = new System.Drawing.Point(151, 275);
this.btMesUnInit.Name = "btMesUnInit";
this.btMesUnInit.Size = new System.Drawing.Size(85, 25);
this.btMesUnInit.TabIndex = 53;
this.btMesUnInit.Text = "btMesUnInit";
this.btMesUnInit.UseVisualStyleBackColor = false;
this.btMesUnInit.Click += new System.EventHandler(this.btMesUnInit_Click);
//
// btMesEnd
//
this.btMesEnd.BackColor = System.Drawing.SystemColors.Highlight;
this.btMesEnd.Location = new System.Drawing.Point(49, 275);
this.btMesEnd.Name = "btMesEnd";
this.btMesEnd.Size = new System.Drawing.Size(85, 25);
this.btMesEnd.TabIndex = 52;
this.btMesEnd.Text = "btMesEnd";
this.btMesEnd.UseVisualStyleBackColor = false;
this.btMesEnd.Click += new System.EventHandler(this.btMesEnd_Click);
//
// btMesStart
//
this.btMesStart.BackColor = System.Drawing.SystemColors.Highlight;
this.btMesStart.Location = new System.Drawing.Point(151, 216);
this.btMesStart.Name = "btMesStart";
this.btMesStart.Size = new System.Drawing.Size(85, 25);
this.btMesStart.TabIndex = 51;
this.btMesStart.Text = "btMesStart";
this.btMesStart.UseVisualStyleBackColor = false;
this.btMesStart.Click += new System.EventHandler(this.btMesStart_Click);
//
// btMesInit
//
this.btMesInit.BackColor = System.Drawing.SystemColors.Highlight;
this.btMesInit.Location = new System.Drawing.Point(51, 216);
this.btMesInit.Name = "btMesInit";
this.btMesInit.Size = new System.Drawing.Size(85, 25);
this.btMesInit.TabIndex = 50;
this.btMesInit.Text = "btMesInit";
this.btMesInit.UseVisualStyleBackColor = false;
this.btMesInit.Click += new System.EventHandler(this.btMesInit_Click);
//
// MultiMesStart
//
this.MultiMesStart.Location = new System.Drawing.Point(151, 306);
this.MultiMesStart.Name = "MultiMesStart";
this.MultiMesStart.Size = new System.Drawing.Size(85, 25);
this.MultiMesStart.TabIndex = 64;
this.MultiMesStart.Text = "MultiMesStart";
this.MultiMesStart.UseVisualStyleBackColor = true;
this.MultiMesStart.Click += new System.EventHandler(this.button1_Click);
//
// button1
//
this.button1.BackColor = System.Drawing.SystemColors.Highlight;
this.button1.Location = new System.Drawing.Point(51, 337);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(75, 23);
this.button1.TabIndex = 65;
this.button1.Text = "btMesEnd2";
this.button1.UseVisualStyleBackColor = false;
this.button1.Click += new System.EventHandler(this.button1_Click_1);
//
// button2
//
this.button2.BackColor = System.Drawing.SystemColors.Highlight;
this.button2.Location = new System.Drawing.Point(53, 308);
this.button2.Name = "button2";
this.button2.Size = new System.Drawing.Size(83, 23);
this.button2.TabIndex = 66;
this.button2.Text = "btMesStart2";
this.button2.UseVisualStyleBackColor = false;
this.button2.Click += new System.EventHandler(this.button2_Click);
//
// label2
//
this.label2.AutoSize = true;
this.label2.Location = new System.Drawing.Point(12, 126);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(95, 12);
this.label2.TabIndex = 67;
this.label2.Text = "ErrDescription:";
this.label2.Click += new System.EventHandler(this.label2_Click);
//
// textBox1
//
this.textBox1.Location = new System.Drawing.Point(104, 123);
this.textBox1.Name = "textBox1";
this.textBox1.Size = new System.Drawing.Size(203, 21);
this.textBox1.TabIndex = 68;
//
// label3
//
this.label3.AutoSize = true;
this.label3.Location = new System.Drawing.Point(12, 155);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(53, 12);
this.label3.TabIndex = 69;
this.label3.Text = "Alldata:";
//
// textBox2
//
this.textBox2.Location = new System.Drawing.Point(62, 150);
this.textBox2.Name = "textBox2";
this.textBox2.Size = new System.Drawing.Size(245, 21);
this.textBox2.TabIndex = 70;
//
// textBox3
//
this.textBox3.Location = new System.Drawing.Point(104, 94);
this.textBox3.Name = "textBox3";
this.textBox3.Size = new System.Drawing.Size(100, 21);
this.textBox3.TabIndex = 71;
//
// Form1
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(319, 394);
this.Controls.Add(this.textBox3);
this.Controls.Add(this.textBox2);
this.Controls.Add(this.label3);
this.Controls.Add(this.textBox1);
this.Controls.Add(this.label2);
this.Controls.Add(this.button2);
this.Controls.Add(this.button1);
this.Controls.Add(this.MultiMesStart);
this.Controls.Add(this.label20);
this.Controls.Add(this.tBTool);
this.Controls.Add(this.label13);
this.Controls.Add(this.tBStationHand);
this.Controls.Add(this.label9);
this.Controls.Add(this.tBSN);
this.Controls.Add(this.label1);
this.Controls.Add(this.btMesSet);
this.Controls.Add(this.btMesGet);
this.Controls.Add(this.btMesUnInit);
this.Controls.Add(this.btMesEnd);
this.Controls.Add(this.btMesStart);
this.Controls.Add(this.btMesInit);
this.Name = "Form1";
this.Text = "Form1";
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.Label label20;
private System.Windows.Forms.TextBox tBTool;
private System.Windows.Forms.Label label13;
private System.Windows.Forms.TextBox tBStationHand;
private System.Windows.Forms.Label label9;
private System.Windows.Forms.TextBox tBSN;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Button btMesSet;
private System.Windows.Forms.Button btMesGet;
private System.Windows.Forms.Button btMesUnInit;
private System.Windows.Forms.Button btMesEnd;
private System.Windows.Forms.Button btMesStart;
private System.Windows.Forms.Button btMesInit;
private System.Windows.Forms.Button MultiMesStart;
private System.Windows.Forms.Button button1;
private System.Windows.Forms.Button button2;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.TextBox textBox1;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.TextBox textBox2;
private System.Windows.Forms.TextBox textBox3;
}
}

View File

@@ -0,0 +1,337 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Runtime.InteropServices;
using Newtonsoft;//处理从mes获取的json字符串
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
namespace MEStest
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
public delegate int MESBackFunc(StringBuilder data);
/// <summary>
/// mes函数执行成功
/// </summary>
public const int MesBackOK = 0;
/// <summary>
/// MES的句柄
/// </summary>
public static int hMes = 0;
private const string DLLPATH = "HQMES.dll";
[DllImport(DLLPATH)]
public static extern int MesInit(MESBackFunc func, ref int hMes, StringBuilder sInfo, ref int InfoLen);
[DllImport(DLLPATH)]
public static extern int MesStart(int hMes, string SN, string ActionName, string Tools, StringBuilder sInfo, ref int InfoLen);
[DllImport(DLLPATH)]
public static extern int MesStart2(int hMes, string SN, string SNType, string ActionName, string Tools, StringBuilder sInfo, ref int InfoLen);
[DllImport(DLLPATH)]
public static extern int MesEnd(int hMes, string SN, string ActionName, string Tools, string ErrorCode, StringBuilder sInfo, ref int InfoLen);
[DllImport(DLLPATH)]
public static extern int MesEnd2(int hMes, string SN, string SNType, string ActionName, string Tools, string ErrorCode, string AllData, StringBuilder sInfo, ref int InfoLen);
[DllImport(DLLPATH)]
private static extern int MesSaveAndGetExtraInfo(int hMes, string G_TYPE, string G_POSITION, string G_KEY, string G_VALUE, string G_EXTINFO, StringBuilder sInfo, ref int InfoLen);
[DllImport(DLLPATH)]
public static extern int MesUnInit(int hMes);
/// <summary>
/// 回调函数
/// </summary>
/// <param name="data"></param>
/// <returns></returns>
public static int WriteLogFile(StringBuilder data)
{
//MessageBox.Show(data.ToString());
return 0;
}
static int hmes = 0;
private static MESBackFunc tempFunc;// 必须要加一个变量,这样不会被回收
private void btMesInit_Click(object sender, EventArgs e)
{
int len = 102400;
StringBuilder strdata = new StringBuilder(len);
if (hMes == 0)
{
tempFunc = WriteLogFile; // 必须要加一个变量,这样不会被回收 这个回调函数赋值只能放在这个位置防止当多次点击init之后可能会出现回调函数被回收的现象
if (0 == MesInit(tempFunc, ref hMes, strdata, ref len))
{
JObject jt = (JObject)JsonConvert.DeserializeObject(strdata.ToString());
string version = "";
version = jt.GetValue("H_MSG") == null ? "" : jt.GetValue("H_MSG").ToString();//获取meshelepr的版本
MessageBox.Show("初始化链接MES 成功 MEShelper版本" + version);//strdata会返回一个meshelper的版本号表示初始化成功
}
else
{
hMes = 0;
MessageBox.Show("初始化链接MES 失败 ");
}
;
}
else
{
MessageBox.Show("请勿重复初始化MES链接");
}
}
private void btMesStart_Click(object sender, EventArgs e)//messtart函数用来执行一般过站操作只能使用sn过站如需使用别的类型过站请使用MesStart2函数
{
if (hMes != 0)
{
int len = 102400;
StringBuilder strdata = new StringBuilder(len);
//StringBuilder SN = new StringBuilder("12345678901002");
//StringBuilder ActionName = new StringBuilder("BT");
//StringBuilder toolName = new StringBuilder("PRESSTOOL");
string SN = tBSN.Text;
string ActionName = tBStationHand.Text;
string toolName = tBTool.Text;
string data = "";
string msg = "";
string retdata = "";
string needload = "";
if (0 == MesStart(hMes, SN, ActionName, toolName, strdata, ref len))
{
MessageBox.Show("链接MES 成功 /r/n" + strdata.ToString());
//start参数的解析具体字段定义请参考《华勤MESHelper接口工具使用说明》
JObject jo = (JObject)JsonConvert.DeserializeObject(strdata.ToString());
data = jo.GetValue("DATA") == null ? "" : jo.GetValue("DATA").ToString();
//data是一个json字符串其中包含mes返回的主要字段按照这个参考继续解析出来 例如获取CSN
JObject jb = (JObject)JsonConvert.DeserializeObject(data);
string CSN = jb.GetValue("CSN") ==null?"":jb.GetValue("CSN").ToString();
//
msg = jo.GetValue("H_MSG") == null ? "" : jo.GetValue("H_MSG").ToString();
retdata = jo.GetValue("G_RET_DATA") == null ? "" : jo.GetValue("G_RET_DATA").ToString();//标记工具需要回传给MES的字段是json格式将其解析出来可以得到字段工具必须将该字段赋值并回传给MES在endmes函数回传
needload = jo.GetValue("NeedLoad") == null ? "" : jo.GetValue("NeedLoad").ToString();//标记工具是否需要重启
//解析结束
}
else
{
JObject jo = (JObject)JsonConvert.DeserializeObject(strdata.ToString());
msg = jo.GetValue("H_MSG") == null ? "" : jo.GetValue("H_MSG").ToString();//mes返回的错误信息最好将其在工具界面展示出来给操作人员查看
MessageBox.Show("链接MES 失败 /r/n" + strdata.ToString());
}
}
else
{
MessageBox.Show("请初始化MES链接");
}
}
private void btMesGet_Click(object sender, EventArgs e)
{
if (hMes != 0)
{
int len = 102400;
StringBuilder strdata = new StringBuilder(len);
string SN = tBSN.Text.ToString();
if (0 == MesSaveAndGetExtraInfo(hMes, "2", "BATROLL", SN, null, null, strdata, ref len))
{
MessageBox.Show("链接MES 成功 /r/n" + strdata.ToString());
}
else
{
MessageBox.Show("链接MES 失败 /r/n" + strdata.ToString());
}
}
else
{
MessageBox.Show("请初始化MES链接");
}
}
private void btMesSet_Click(object sender, EventArgs e)
{
if (hMes != 0)
{
int len = 102400;
StringBuilder strdata = new StringBuilder(len);
string SN = tBSN.Text.ToString();
string RollData = "Max:5.100kg;Min:4.800kg;RollNum:3;Time:10s";
if (0 == MesSaveAndGetExtraInfo(hMes, "1", "BATROLL", SN, RollData, null, strdata, ref len))
{
MessageBox.Show("保存数据到MES 成功 /r/n" + strdata.ToString());
}
else
{
MessageBox.Show("保存数据到MES 失败 /r/n" + strdata.ToString());
}
}
else
{
MessageBox.Show("请初始化MES链接");
}
}
private void btMesEnd_Click(object sender, EventArgs e)//mesend函数仅仅向mes回传工具运行情况的错误码和错误描述如需向mes回传特定字段请使用MesEnd2函数
{
if (hMes != 0)
{
int len = 102400;
StringBuilder strdata = new StringBuilder(len);
strdata.Append(textBox3.Text);//错误描述
string SN = tBSN.Text.ToString();
string ActionName = tBStationHand.Text;//工具动作
string toolName = tBTool.Text;//工具版本
string ErrorCode = textBox1.Text;//错误码 0表示测试成功其它表示失败
string nextws = "";//表示下一个工位
string msg = "";//过站的错误信息
if (0 == MesEnd(hMes, SN, ActionName, toolName, ErrorCode, strdata, ref len))
{
JObject jo = (JObject)JsonConvert.DeserializeObject(strdata.ToString());
msg = jo.GetValue("H_MSG") == null ? "" : jo.GetValue("H_MSG").ToString();
nextws = jo.GetValue("G_NEXTWS") == null ? "" : jo.GetValue("G_NEXTWS").ToString();
MessageBox.Show("保存数据到MES 成功 /r/n" + strdata.ToString());
}
else
{
JObject jo = (JObject)JsonConvert.DeserializeObject(strdata.ToString());
msg = jo.GetValue("H_MSG") == null ? "" : jo.GetValue("H_MSG").ToString();//表示过站的错误信息,最好展示在工具的界面方便操作人员查看
MessageBox.Show("保存数据到MES 失败 /r/n" + strdata.ToString());
}
}
else
{
MessageBox.Show("请初始化MES链接");
}
}
private void btMesUnInit_Click(object sender, EventArgs e)
{
if (hMes != 0)
{
if (0 == MesUnInit(hMes))
{
MessageBox.Show("释放MES链接 成功 ");
}
else
{
MessageBox.Show("释放MES链接 失败 ");
}
}
else
{
MessageBox.Show("请初始化MES链接");
}
}
private void button1_Click(object sender, EventArgs e)
{
if (hMes != 0)
{
//StringBuilder SN = new StringBuilder("12345678901002");
//StringBuilder ActionName = new StringBuilder("BT");
//StringBuilder toolName = new StringBuilder("PRESSTOOL");
string SN = tBSN.Text;
string ActionName = tBStationHand.Text;
string toolName = tBTool.Text;
for (int i = 0; i < 16; i++)
{
int len = 102400;
StringBuilder strdata = new StringBuilder(len);
if (0 == MesStart(hMes, SN, ActionName, toolName, strdata, ref len))
{
//MessageBox.Show("链接MES 成功 /r/n" + strdata.ToString());
}
else
{
//MessageBox.Show("链接MES 失败 /r/n" + strdata.ToString());
}
}
}
else
{
MessageBox.Show("请初始化MES链接");
}
}
private void textBox4_TextChanged(object sender, EventArgs e)
{
}
private void button1_Click_1(object sender, EventArgs e)
{
if (hMes != 0)
{
int len = 102400;
StringBuilder strdata = new StringBuilder(len);
strdata.Append(textBox1.Text);
string SN = tBSN.Text;
string ActionName = tBStationHand.Text;
string toolName = tBTool.Text;
string ErrorCode = textBox3.Text;
string AllData = textBox2.Text;//表示需要回传给mes的字段json字符串形式传递
string SNType = "1";//
//start
//假设需要回传的字段为a值为1,将字段a上抛
//JObject data = new JObject();
//data.Add("a", "1");
//AllData = data.ToString();
//当遇到数据较多的时候可以使用Dictionary类型存储数据然后序列化
//end
if (0 == MesEnd2(hMes, SN, "1", ActionName, toolName, ErrorCode, AllData, strdata, ref len))
{
//这个函数返回的值跟MesEnd一样请参考MesEnd的解析参数的操作
MessageBox.Show("保存数据到MES 成功 /r/n" + strdata.ToString());
}
else
{
MessageBox.Show("保存数据到MES 失败 /r/n" + strdata.ToString());
}
}
else
{
MessageBox.Show("请初始化MES链接");
}
}
private void label2_Click(object sender, EventArgs e)
{
}
private void button2_Click(object sender, EventArgs e)
{
if (hMes != 0)
{
int len = 102400;
StringBuilder strdata = new StringBuilder(len);
//StringBuilder SN = new StringBuilder("12345678901002");
//StringBuilder ActionName = new StringBuilder("BT");
//StringBuilder toolName = new StringBuilder("PRESSTOOL");
string SN = tBSN.Text;
string ActionName = tBStationHand.Text;
string toolName = tBTool.Text;
string ErrorCode = textBox1.Text;
string ErrorDes = textBox3.Text;
string AllData = textBox2.Text;
string SNType = "1";//表示流程检查的输入数据类型1 SN 2 IMEI 3 CSN 4 蓝牙 5 WiFi 6 入网证
if (0 == MesStart2(hMes, SN,SNType, ActionName, toolName, strdata, ref len))
{
//这个函数返回的值跟MesStart一样请参考MesStart的解析参数的操作
MessageBox.Show("链接MES 成功 /r/n" + strdata.ToString());
}
else
{
MessageBox.Show("链接MES 失败 /r/n" + strdata.ToString());
}
}
else
{
MessageBox.Show("请初始化MES链接");
}
}
}
}

View File

@@ -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=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -0,0 +1,337 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Runtime.InteropServices;
using Newtonsoft;//处理从mes获取的json字符串
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
namespace MEStest
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
public delegate int MESBackFunc(StringBuilder data);
/// <summary>
/// mes函数执行成功
/// </summary>
public const int MesBackOK = 0;
/// <summary>
/// MES的句柄
/// </summary>
public static int hMes = 0;
private const string DLLPATH = "HQMES.dll";
[DllImport(DLLPATH)]
public static extern int MesInit(MESBackFunc func, ref int hMes, StringBuilder sInfo, ref int InfoLen);
[DllImport(DLLPATH)]
public static extern int MesStart(int hMes, string SN, string ActionName, string Tools, StringBuilder sInfo, ref int InfoLen);
[DllImport(DLLPATH)]
public static extern int MesStart2(int hMes, string SN, string SNType, string ActionName, string Tools, StringBuilder sInfo, ref int InfoLen);
[DllImport(DLLPATH)]
public static extern int MesEnd(int hMes, string SN, string ActionName, string Tools, string ErrorCode, StringBuilder sInfo, ref int InfoLen);
[DllImport(DLLPATH)]
public static extern int MesEnd2(int hMes, string SN, string SNType, string ActionName, string Tools, string ErrorCode, string AllData, StringBuilder sInfo, ref int InfoLen);
[DllImport(DLLPATH)]
private static extern int MesSaveAndGetExtraInfo(int hMes, string G_TYPE, string G_POSITION, string G_KEY, string G_VALUE, string G_EXTINFO, StringBuilder sInfo, ref int InfoLen);
[DllImport(DLLPATH)]
public static extern int MesUnInit(int hMes);
/// <summary>
/// 回调函数
/// </summary>
/// <param name="data"></param>
/// <returns></returns>
public static int WriteLogFile(StringBuilder data)
{
//MessageBox.Show(data.ToString());
return 0;
}
static int hmes = 0;
private static MESBackFunc tempFunc;// 必须要加一个变量,这样不会被回收
private void btMesInit_Click(object sender, EventArgs e)
{
int len = 102400;
StringBuilder strdata = new StringBuilder(len);
if (hMes == 0)
{
tempFunc = WriteLogFile; // 必须要加一个变量,这样不会被回收 这个回调函数赋值只能放在这个位置防止当多次点击init之后可能会出现回调函数被回收的现象
if (0 == MesInit(tempFunc, ref hMes, strdata, ref len))
{
JObject jt = (JObject)JsonConvert.DeserializeObject(strdata.ToString());
string version = "";
version = jt.GetValue("H_MSG") == null ? "" : jt.GetValue("H_MSG").ToString();//获取meshelepr的版本
MessageBox.Show("初始化链接MES 成功 MEShelper版本" + version);//strdata会返回一个meshelper的版本号表示初始化成功
}
else
{
hMes = 0;
MessageBox.Show("初始化链接MES 失败 ");
}
;
}
else
{
MessageBox.Show("请勿重复初始化MES链接");
}
}
private void btMesStart_Click(object sender, EventArgs e)//messtart函数用来执行一般过站操作只能使用sn过站如需使用别的类型过站请使用MesStart2函数
{
if (hMes != 0)
{
int len = 102400;
StringBuilder strdata = new StringBuilder(len);
//StringBuilder SN = new StringBuilder("12345678901002");
//StringBuilder ActionName = new StringBuilder("BT");
//StringBuilder toolName = new StringBuilder("PRESSTOOL");
string SN = tBSN.Text;
string ActionName = tBStationHand.Text;
string toolName = tBTool.Text;
string data = "";
string msg = "";
string retdata = "";
string needload = "";
if (0 == MesStart(hMes, SN, ActionName, toolName, strdata, ref len))
{
MessageBox.Show("链接MES 成功 /r/n" + strdata.ToString());
//start参数的解析具体字段定义请参考《华勤MESHelper接口工具使用说明》
JObject jo = (JObject)JsonConvert.DeserializeObject(strdata.ToString());
data = jo.GetValue("DATA") == null ? "" : jo.GetValue("DATA").ToString();
//data是一个json字符串其中包含mes返回的主要字段按照这个参考继续解析出来 例如获取CSN
JObject jb = (JObject)JsonConvert.DeserializeObject(data);
string CSN = jb.GetValue("CSN") ==null?"":jb.GetValue("CSN").ToString();
//
msg = jo.GetValue("H_MSG") == null ? "" : jo.GetValue("H_MSG").ToString();
retdata = jo.GetValue("G_RET_DATA") == null ? "" : jo.GetValue("G_RET_DATA").ToString();//标记工具需要回传给MES的字段是json格式将其解析出来可以得到字段工具必须将该字段赋值并回传给MES在endmes函数回传
needload = jo.GetValue("NeedLoad") == null ? "" : jo.GetValue("NeedLoad").ToString();//标记工具是否需要重启
//解析结束
}
else
{
JObject jo = (JObject)JsonConvert.DeserializeObject(strdata.ToString());
msg = jo.GetValue("H_MSG") == null ? "" : jo.GetValue("H_MSG").ToString();//mes返回的错误信息最好将其在工具界面展示出来给操作人员查看
MessageBox.Show("链接MES 失败 /r/n" + strdata.ToString());
}
}
else
{
MessageBox.Show("请初始化MES链接");
}
}
private void btMesGet_Click(object sender, EventArgs e)
{
if (hMes != 0)
{
int len = 102400;
StringBuilder strdata = new StringBuilder(len);
string SN = tBSN.Text.ToString();
if (0 == MesSaveAndGetExtraInfo(hMes, "2", "BATROLL", SN, null, null, strdata, ref len))
{
MessageBox.Show("链接MES 成功 /r/n" + strdata.ToString());
}
else
{
MessageBox.Show("链接MES 失败 /r/n" + strdata.ToString());
}
}
else
{
MessageBox.Show("请初始化MES链接");
}
}
private void btMesSet_Click(object sender, EventArgs e)
{
if (hMes != 0)
{
int len = 102400;
StringBuilder strdata = new StringBuilder(len);
string SN = tBSN.Text.ToString();
string RollData = "Max:5.100kg;Min:4.800kg;RollNum:3;Time:10s";
if (0 == MesSaveAndGetExtraInfo(hMes, "1", "BATROLL", SN, RollData, null, strdata, ref len))
{
MessageBox.Show("保存数据到MES 成功 /r/n" + strdata.ToString());
}
else
{
MessageBox.Show("保存数据到MES 失败 /r/n" + strdata.ToString());
}
}
else
{
MessageBox.Show("请初始化MES链接");
}
}
private void btMesEnd_Click(object sender, EventArgs e)//mesend函数仅仅向mes回传工具运行情况的错误码和错误描述如需向mes回传特定字段请使用MesEnd2函数
{
if (hMes != 0)
{
int len = 102400;
StringBuilder strdata = new StringBuilder(len);
strdata.Append(textBox3.Text);//错误描述
string SN = tBSN.Text.ToString();
string ActionName = tBStationHand.Text;//工具动作
string toolName = tBTool.Text;//工具版本
string ErrorCode = textBox1.Text;//错误码 0表示测试成功其它表示失败
string nextws = "";//表示下一个工位
string msg = "";//过站的错误信息
if (0 == MesEnd(hMes, SN, ActionName, toolName, ErrorCode, strdata, ref len))
{
JObject jo = (JObject)JsonConvert.DeserializeObject(strdata.ToString());
msg = jo.GetValue("H_MSG") == null ? "" : jo.GetValue("H_MSG").ToString();
nextws = jo.GetValue("G_NEXTWS") == null ? "" : jo.GetValue("G_NEXTWS").ToString();
MessageBox.Show("保存数据到MES 成功 /r/n" + strdata.ToString());
}
else
{
JObject jo = (JObject)JsonConvert.DeserializeObject(strdata.ToString());
msg = jo.GetValue("H_MSG") == null ? "" : jo.GetValue("H_MSG").ToString();//表示过站的错误信息,最好展示在工具的界面方便操作人员查看
MessageBox.Show("保存数据到MES 失败 /r/n" + strdata.ToString());
}
}
else
{
MessageBox.Show("请初始化MES链接");
}
}
private void btMesUnInit_Click(object sender, EventArgs e)
{
if (hMes != 0)
{
if (0 == MesUnInit(hMes))
{
MessageBox.Show("释放MES链接 成功 ");
}
else
{
MessageBox.Show("释放MES链接 失败 ");
}
}
else
{
MessageBox.Show("请初始化MES链接");
}
}
private void button1_Click(object sender, EventArgs e)
{
if (hMes != 0)
{
//StringBuilder SN = new StringBuilder("12345678901002");
//StringBuilder ActionName = new StringBuilder("BT");
//StringBuilder toolName = new StringBuilder("PRESSTOOL");
string SN = tBSN.Text;
string ActionName = tBStationHand.Text;
string toolName = tBTool.Text;
for (int i = 0; i < 16; i++)
{
int len = 102400;
StringBuilder strdata = new StringBuilder(len);
if (0 == MesStart(hMes, SN, ActionName, toolName, strdata, ref len))
{
//MessageBox.Show("链接MES 成功 /r/n" + strdata.ToString());
}
else
{
//MessageBox.Show("链接MES 失败 /r/n" + strdata.ToString());
}
}
}
else
{
MessageBox.Show("请初始化MES链接");
}
}
private void textBox4_TextChanged(object sender, EventArgs e)
{
}
private void button1_Click_1(object sender, EventArgs e)
{
if (hMes != 0)
{
int len = 102400;
StringBuilder strdata = new StringBuilder(len);
strdata.Append(textBox1.Text);
string SN = tBSN.Text;
string ActionName = tBStationHand.Text;
string toolName = tBTool.Text;
string ErrorCode = textBox3.Text;
string AllData = textBox2.Text;//表示需要回传给mes的字段json字符串形式传递
string SNType = "1";//
//start
//假设需要回传的字段为a值为1,将字段a上抛
//JObject data = new JObject();
//data.Add("a", "1");
//AllData = data.ToString();
//当遇到数据较多的时候可以使用Dictionary类型存储数据然后序列化
//end
if (0 == MesEnd2(hMes, SN, "1", ActionName, toolName, ErrorCode, AllData, strdata, ref len))
{
//这个函数返回的值跟MesEnd一样请参考MesEnd的解析参数的操作
MessageBox.Show("保存数据到MES 成功 /r/n" + strdata.ToString());
}
else
{
MessageBox.Show("保存数据到MES 失败 /r/n" + strdata.ToString());
}
}
else
{
MessageBox.Show("请初始化MES链接");
}
}
private void label2_Click(object sender, EventArgs e)
{
}
private void button2_Click(object sender, EventArgs e)
{
if (hMes != 0)
{
int len = 102400;
StringBuilder strdata = new StringBuilder(len);
//StringBuilder SN = new StringBuilder("12345678901002");
//StringBuilder ActionName = new StringBuilder("BT");
//StringBuilder toolName = new StringBuilder("PRESSTOOL");
string SN = tBSN.Text;
string ActionName = tBStationHand.Text;
string toolName = tBTool.Text;
string ErrorCode = textBox1.Text;
string ErrorDes = textBox3.Text;
string AllData = textBox2.Text;
string SNType = "1";//表示流程检查的输入数据类型1 SN 2 IMEI 3 CSN 4 蓝牙 5 WiFi 6 入网证
if (0 == MesStart2(hMes, SN,SNType, ActionName, toolName, strdata, ref len))
{
//这个函数返回的值跟MesStart一样请参考MesStart的解析参数的操作
MessageBox.Show("链接MES 成功 /r/n" + strdata.ToString());
}
else
{
MessageBox.Show("链接MES 失败 /r/n" + strdata.ToString());
}
}
else
{
MessageBox.Show("请初始化MES链接");
}
}
}
}

View File

@@ -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=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -0,0 +1,94 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<ProductVersion>8.0.30703</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}</ProjectGuid>
<OutputType>WinExe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>MEStest</RootNamespace>
<AssemblyName>MEStest</AssemblyName>
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
<PlatformTarget>x86</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
<PlatformTarget>x86</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="Newtonsoft.Json, Version=4.5.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>lib\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="System.Data" />
<Reference Include="System.Deployment" />
<Reference Include="System.Drawing" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="Form1.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="Form1.Designer.cs">
<DependentUpon>Form1.cs</DependentUpon>
</Compile>
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<EmbeddedResource Include="Form1.resx">
<DependentUpon>Form1.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>
</Compile>
<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>
<Content Include="HQMES.dll">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>

View File

@@ -0,0 +1,94 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">x86</Platform>
<ProductVersion>8.0.30703</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}</ProjectGuid>
<OutputType>WinExe</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>MEStest</RootNamespace>
<AssemblyName>MEStest</AssemblyName>
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|x86' ">
<PlatformTarget>x86</PlatformTarget>
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|x86' ">
<PlatformTarget>x86</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="Newtonsoft.Json, Version=4.5.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>lib\Newtonsoft.Json.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="System.Data" />
<Reference Include="System.Deployment" />
<Reference Include="System.Drawing" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="Form1.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="Form1.Designer.cs">
<DependentUpon>Form1.cs</DependentUpon>
</Compile>
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<EmbeddedResource Include="Form1.resx">
<DependentUpon>Form1.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>
</Compile>
<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>
<Content Include="HQMES.dll">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>

View File

@@ -0,0 +1,21 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Windows.Forms;
namespace MEStest
{
static class Program
{
/// <summary>
/// 应用程序的主入口点。
/// </summary>
[STAThread]
static void Main()
{
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
Application.Run(new Form1());
}
}
}

View File

@@ -0,0 +1,21 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Windows.Forms;
namespace MEStest
{
static class Program
{
/// <summary>
/// 应用程序的主入口点。
/// </summary>
[STAThread]
static void Main()
{
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
Application.Run(new Form1());
}
}
}

View File

@@ -0,0 +1,36 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// 有关程序集的常规信息通过以下
// 特性集控制。更改这些特性值可修改
// 与程序集关联的信息。
[assembly: AssemblyTitle("MEStest")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("MEStest")]
[assembly: AssemblyCopyright("Copyright © Microsoft 2017")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// 将 ComVisible 设置为 false 使此程序集中的类型
// 对 COM 组件不可见。如果需要从 COM 访问此程序集中的类型,
// 则将该类型上的 ComVisible 特性设置为 true。
[assembly: ComVisible(false)]
// 如果此项目向 COM 公开,则下列 GUID 用于类型库的 ID
[assembly: Guid("8f6bb2e1-c9ae-47e5-8730-deb4cdf7076a")]
// 程序集的版本信息由下面四个值组成:
//
// 主版本
// 次版本
// 内部版本号
// 修订号
//
// 可以指定所有这些值,也可以使用“内部版本号”和“修订号”的默认值,
// 方法是按如下所示使用“*”:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]

View File

@@ -0,0 +1,36 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// 有关程序集的常规信息通过以下
// 特性集控制。更改这些特性值可修改
// 与程序集关联的信息。
[assembly: AssemblyTitle("MEStest")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("MEStest")]
[assembly: AssemblyCopyright("Copyright © Microsoft 2017")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// 将 ComVisible 设置为 false 使此程序集中的类型
// 对 COM 组件不可见。如果需要从 COM 访问此程序集中的类型,
// 则将该类型上的 ComVisible 特性设置为 true。
[assembly: ComVisible(false)]
// 如果此项目向 COM 公开,则下列 GUID 用于类型库的 ID
[assembly: Guid("8f6bb2e1-c9ae-47e5-8730-deb4cdf7076a")]
// 程序集的版本信息由下面四个值组成:
//
// 主版本
// 次版本
// 内部版本号
// 修订号
//
// 可以指定所有这些值,也可以使用“内部版本号”和“修订号”的默认值,
// 方法是按如下所示使用“*”:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]

View File

@@ -0,0 +1,71 @@
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
// 运行时版本: 4.0.30319.42000
//
// 对此文件的更改可能会导致不正确的行为,并且如果
// 重新生成代码,这些更改将丢失。
// </auto-generated>
//------------------------------------------------------------------------------
namespace MEStest.Properties
{
/// <summary>
/// 一个强类型的资源类,用于查找本地化的字符串等。
/// </summary>
// 此类是由 StronglyTypedResourceBuilder
// 类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。
// 若要添加或移除成员,请编辑 .ResX 文件,然后重新运行 ResGen
// (以 /str 作为命令选项),或重新生成 VS 项目。
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.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 ((resourceMan == null))
{
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("MEStest.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;
}
}
}
}

View File

@@ -0,0 +1,71 @@
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
// 运行时版本: 4.0.30319.42000
//
// 对此文件的更改可能会导致不正确的行为,并且如果
// 重新生成代码,这些更改将丢失。
// </auto-generated>
//------------------------------------------------------------------------------
namespace MEStest.Properties
{
/// <summary>
/// 一个强类型的资源类,用于查找本地化的字符串等。
/// </summary>
// 此类是由 StronglyTypedResourceBuilder
// 类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。
// 若要添加或移除成员,请编辑 .ResX 文件,然后重新运行 ResGen
// (以 /str 作为命令选项),或重新生成 VS 项目。
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.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 ((resourceMan == null))
{
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("MEStest.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;
}
}
}
}

View File

@@ -0,0 +1,117 @@
<?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.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: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" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
</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" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
</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=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -0,0 +1,117 @@
<?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.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: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" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
</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" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
</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=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -0,0 +1,30 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace MEStest.Properties
{
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "10.0.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;
}
}
}
}

View File

@@ -0,0 +1,30 @@
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//------------------------------------------------------------------------------
namespace MEStest.Properties
{
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "10.0.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;
}
}
}
}

View File

@@ -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>

View File

@@ -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>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,2 @@
这个demo默认使用.net3.5框架,如果工具要采用较高等级的.net框架文件夹里面是可以使用的Newtonsoft.Json资源

View File

@@ -0,0 +1,2 @@
这个demo默认使用.net3.5框架,如果工具要采用较高等级的.net框架文件夹里面是可以使用的Newtonsoft.Json资源

View File

@@ -0,0 +1 @@
39e7d1a8291eb372d36f148a655e856a1f47b77ed4b45357deead92b0f88686d

View File

@@ -0,0 +1,10 @@
D:\桌面\莫禧亮\华贝\正负压28\正负压 LL-28\LL-28\MES对接\华擎对接资料\c#_demo\C#\MEStest\bin\Debug\HQMES.dll
D:\桌面\莫禧亮\华贝\正负压28\正负压 LL-28\LL-28\MES对接\华擎对接资料\c#_demo\C#\MEStest\bin\Debug\Newtonsoft.Json.dll
D:\桌面\莫禧亮\华贝\正负压28\正负压 LL-28\LL-28\MES对接\华擎对接资料\c#_demo\C#\MEStest\obj\x86\Debug\MEStest.csproj.AssemblyReference.cache
D:\桌面\莫禧亮\华贝\正负压28\正负压 LL-28\LL-28\MES对接\华擎对接资料\c#_demo\C#\MEStest\obj\x86\Debug\MEStest.Form1.resources
D:\桌面\莫禧亮\华贝\正负压28\正负压 LL-28\LL-28\MES对接\华擎对接资料\c#_demo\C#\MEStest\obj\x86\Debug\MEStest.Properties.Resources.resources
D:\桌面\莫禧亮\华贝\正负压28\正负压 LL-28\LL-28\MES对接\华擎对接资料\c#_demo\C#\MEStest\obj\x86\Debug\MEStest.csproj.GenerateResource.cache
D:\桌面\莫禧亮\华贝\正负压28\正负压 LL-28\LL-28\MES对接\华擎对接资料\c#_demo\C#\MEStest\obj\x86\Debug\MEStest.csproj.CoreCompileInputs.cache
D:\桌面\莫禧亮\华贝\正负压28\正负压 LL-28\LL-28\MES对接\华擎对接资料\c#_demo\C#\MEStest\obj\x86\Debug\MEStest.csproj.Up2Date
D:\桌面\莫禧亮\华贝\正负压28\正负压 LL-28\LL-28\MES对接\华擎对接资料\c#_demo\C#\MEStest\obj\x86\Debug\MEStest.exe
D:\桌面\莫禧亮\华贝\正负压28\正负压 LL-28\LL-28\MES对接\华擎对接资料\c#_demo\C#\MEStest\obj\x86\Debug\MEStest.pdb

View File

@@ -0,0 +1,20 @@

Microsoft Visual Studio Solution File, Format Version 11.00
# Visual Studio 2010
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MEStest", "MEStest\MEStest.csproj", "{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|x86 = Debug|x86
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}.Debug|x86.ActiveCfg = Debug|x86
{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}.Debug|x86.Build.0 = Debug|x86
{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}.Release|x86.ActiveCfg = Release|x86
{DAF3673D-6DBB-4D6D-85AD-B98499A9C277}.Release|x86.Build.0 = Release|x86
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
EndGlobal

View File

@@ -0,0 +1 @@
F:\software\Microsoft Visual Studio\2019\Community\MSBuild\Microsoft\VC\v160\Microsoft.CppBuild.targets(479,5): error MSB8041: 此项目需要 MFC 库。从 Visual Studio 安装程序(单个组件选项卡)为正在使用的任何工具集和体系结构安装它们。

View File

@@ -0,0 +1,78 @@
// HQSFC_Tester.cpp : <20><><EFBFBD><EFBFBD>Ӧ<EFBFBD>ó<EFBFBD><C3B3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϊ<EFBFBD><CEAA>
//
#include "stdafx.h"
#include "HQSFC_Tester.h"
#include "HQSFC_TesterDlg.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#endif
// CHQSFC_TesterApp
BEGIN_MESSAGE_MAP(CHQSFC_TesterApp, CWinApp)
ON_COMMAND(ID_HELP, &CWinApp::OnHelp)
END_MESSAGE_MAP()
// CHQSFC_TesterApp <20><><EFBFBD><EFBFBD>
CHQSFC_TesterApp::CHQSFC_TesterApp()
{
// TODO: <20>ڴ˴<DAB4><CBB4><EFBFBD><EFBFBD>ӹ<EFBFBD><D3B9><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ҫ<EFBFBD>ij<EFBFBD>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> InitInstance <20><>
}
// Ψһ<CEA8><D2BB>һ<EFBFBD><D2BB> CHQSFC_TesterApp <20><><EFBFBD><EFBFBD>
CHQSFC_TesterApp theApp;
// CHQSFC_TesterApp <20><>ʼ<EFBFBD><CABC>
BOOL CHQSFC_TesterApp::InitInstance()
{
// <20><><EFBFBD><EFBFBD>һ<EFBFBD><D2BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> Windows XP <20>ϵ<EFBFBD>Ӧ<EFBFBD>ó<EFBFBD><C3B3><EFBFBD><EFBFBD>嵥ָ<E5B5A5><D6B8>Ҫ
// ʹ<><CAB9> ComCtl32.dll <20>汾 6 <20><><EFBFBD><EFBFBD><EFBFBD>߰汾<DFB0><E6B1BE><EFBFBD><EFBFBD><EFBFBD>ÿ<EFBFBD><C3BF>ӻ<EFBFBD><D3BB><EFBFBD>ʽ<EFBFBD><CABD>
//<2F><><EFBFBD><EFBFBD>Ҫ InitCommonControlsEx()<29><><EFBFBD><EFBFBD><EFBFBD>򣬽<EFBFBD><F2A3ACBD>޷<EFBFBD><DEB7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ڡ<EFBFBD>
INITCOMMONCONTROLSEX InitCtrls;
InitCtrls.dwSize = sizeof(InitCtrls);
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϊ<EFBFBD><CEAA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ҫ<EFBFBD><D2AA>Ӧ<EFBFBD>ó<EFBFBD><C3B3><EFBFBD><EFBFBD><EFBFBD>ʹ<EFBFBD>õ<EFBFBD>
// <20><><EFBFBD><EFBFBD><EFBFBD>ؼ<EFBFBD><D8BC>
InitCtrls.dwICC = ICC_WIN95_CLASSES;
InitCommonControlsEx(&InitCtrls);
CWinApp::InitInstance();
AfxEnableControlContainer();
// <20><>׼<EFBFBD><D7BC>ʼ<EFBFBD><CABC>
// <20><><EFBFBD><EFBFBD>δʹ<CEB4><CAB9><EFBFBD><EFBFBD>Щ<EFBFBD><D0A9><EFBFBD>ܲ<EFBFBD>ϣ<EFBFBD><CFA3><EFBFBD><EFBFBD>С
// <20><><EFBFBD>տ<EFBFBD>ִ<EFBFBD><D6B4><EFBFBD>ļ<EFBFBD><C4BC>Ĵ<EFBFBD>С<EFBFBD><D0A1><EFBFBD><EFBFBD>Ӧ<EFBFBD>Ƴ<EFBFBD><C6B3><EFBFBD><EFBFBD><EFBFBD>
// <20><><EFBFBD><EFBFBD>Ҫ<EFBFBD><D2AA><EFBFBD>ض<EFBFBD><D8B6><EFBFBD>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ڴ洢<DAB4><E6B4A2><EFBFBD>õ<EFBFBD>ע<EFBFBD><D7A2><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
// TODO: Ӧ<>ʵ<EFBFBD><CAB5>޸ĸ<DEB8><C4B8>ַ<EFBFBD><D6B7><EFBFBD><EFBFBD><EFBFBD>
// <20><><EFBFBD><EFBFBD><EFBFBD>޸<EFBFBD>Ϊ<EFBFBD><CEAA>˾<EFBFBD><CBBE><EFBFBD><EFBFBD>֯<EFBFBD><D6AF>
SetRegistryKey(_T("Ӧ<EFBFBD>ó<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɵı<EFBFBD><EFBFBD><EFBFBD>Ӧ<EFBFBD>ó<EFBFBD><EFBFBD><EFBFBD>"));
CHQSFC_TesterDlg dlg;
m_pMainWnd = &dlg;
INT_PTR nResponse = dlg.DoModal();
if (nResponse == IDOK)
{
// TODO: <20>ڴ˴<DAB4><CBB4><EFBFBD><EFBFBD>ô<EFBFBD><C3B4><EFBFBD><EFBFBD><EFBFBD>ʱ<EFBFBD>á<EFBFBD>ȷ<EFBFBD><C8B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ر<EFBFBD>
// <20>Ի<EFBFBD><D4BB><EFBFBD><EFBFBD>Ĵ<EFBFBD><C4B4><EFBFBD>
}
else if (nResponse == IDCANCEL)
{
// TODO: <20>ڴ˷<DAB4><CBB7>ô<EFBFBD><C3B4><EFBFBD><EFBFBD><EFBFBD>ʱ<EFBFBD>á<EFBFBD>ȡ<EFBFBD><C8A1><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ر<EFBFBD>
// <20>Ի<EFBFBD><D4BB><EFBFBD><EFBFBD>Ĵ<EFBFBD><C4B4><EFBFBD>
}
// <20><><EFBFBD>ڶԻ<DAB6><D4BB><EFBFBD><EFBFBD>ѹرգ<D8B1><D5A3><EFBFBD><EFBFBD>Խ<EFBFBD><D4BD><EFBFBD><EFBFBD><EFBFBD> FALSE <20>Ա<EFBFBD><D4B1>˳<EFBFBD>Ӧ<EFBFBD>ó<EFBFBD><C3B3><EFBFBD><EFBFBD><EFBFBD>
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ӧ<EFBFBD>ó<EFBFBD><C3B3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϣ<EFBFBD>á<EFBFBD>
return FALSE;
}

View File

@@ -0,0 +1,31 @@
// HQSFC_Tester.h : PROJECT_NAME Ӧ<>ó<EFBFBD><C3B3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ͷ<EFBFBD>ļ<EFBFBD>
//
#pragma once
#ifndef __AFXWIN_H__
#error "<22>ڰ<EFBFBD><DAB0><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ļ<EFBFBD>֮ǰ<D6AE><C7B0><EFBFBD><EFBFBD><EFBFBD><EFBFBD>stdafx.h<><68><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> PCH <20>ļ<EFBFBD>"
#endif
#include "resource.h" // <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
// CHQSFC_TesterApp:
// <20>йش<D0B9><D8B4><EFBFBD><EFBFBD><EFBFBD>ʵ<EFBFBD>֣<EFBFBD><D6A3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> HQSFC_Tester.cpp
//
class CHQSFC_TesterApp : public CWinApp
{
public:
CHQSFC_TesterApp();
// <20><>д
public:
virtual BOOL InitInstance();
// ʵ<><CAB5>
DECLARE_MESSAGE_MAP()
};
extern CHQSFC_TesterApp theApp;

View File

@@ -0,0 +1,214 @@
// Microsoft Visual C++ generated resource script.
//
#include "resource.h"
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "afxres.h"
/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
// <20><><EFBFBD><EFBFBD>(<28><><EFBFBD><EFBFBD>й<EFBFBD>) resources
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_CHS)
LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED
#pragma code_page(936)
#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//
1 TEXTINCLUDE
BEGIN
"resource.h\0"
END
2 TEXTINCLUDE
BEGIN
"#include ""afxres.h""\r\n"
"\0"
END
3 TEXTINCLUDE
BEGIN
"#define _AFX_NO_SPLITTER_RESOURCES\r\n"
"#define _AFX_NO_OLE_RESOURCES\r\n"
"#define _AFX_NO_TRACKER_RESOURCES\r\n"
"#define _AFX_NO_PROPERTY_RESOURCES\r\n"
"\r\n"
"#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_CHS)\r\n"
"LANGUAGE 4, 2\r\n"
"#pragma code_page(936)\r\n"
"#include ""res\\HQSFC_Tester.rc2"" // <20><> Microsoft Visual C++ <20><EFBFBD><E0BCAD><EFBFBD><EFBFBD>Դ\r\n"
"#include ""afxres.rc"" // <20><>׼<EFBFBD><D7BC><EFBFBD><EFBFBD>\r\n"
"#endif\r\n"
"\0"
END
#endif // APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Icon
//
// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
IDR_MAINFRAME ICON "res\\HQSFC_Tester.ico"
/////////////////////////////////////////////////////////////////////////////
//
// Dialog
//
IDD_ABOUTBOX DIALOGEX 0, 0, 235, 55
STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "<22><><EFBFBD><EFBFBD> HQSFC_Tester"
FONT 9, "<22><><EFBFBD><EFBFBD>", 0, 0, 0x1
BEGIN
ICON IDR_MAINFRAME,IDC_STATIC,11,17,20,20
LTEXT "HQSFC_Tester 1.0 <20><>",IDC_STATIC,40,10,119,8,SS_NOPREFIX
LTEXT "Copyright (C) 2015",IDC_STATIC,40,25,119,8
DEFPUSHBUTTON "ȷ<><C8B7>",IDOK,178,7,50,16,WS_GROUP
END
IDD_HQSFC_TESTER_DIALOG DIALOGEX 0, 0, 414, 283
STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
EXSTYLE WS_EX_APPWINDOW
CAPTION "HQSFC_Tester"
FONT 9, "<22><><EFBFBD><EFBFBD>", 0, 0, 0x1
BEGIN
EDITTEXT IDC_EDIT1,57,15,134,14,ES_AUTOHSCROLL
EDITTEXT IDC_EDIT2,57,33,134,14,ES_AUTOHSCROLL
DEFPUSHBUTTON "MesInit",IDC_BUTTON3,25,237,71,39
PUSHBUTTON "MesStart",IDC_BUTTON1,28,145,71,23
PUSHBUTTON "MesEnd",IDC_BUTTON2,119,145,71,22
PUSHBUTTON "ClearLog",IDC_BUTTON4,121,123,67,19
EDITTEXT IDC_EDIT3,58,51,134,14,ES_AUTOHSCROLL
EDITTEXT IDC_EDIT4,57,68,134,14,ES_AUTOHSCROLL
LTEXT "SN",IDC_STATIC,11,17,9,8
LTEXT "STATION",IDC_STATIC,7,35,29,8
LTEXT "TOOL",IDC_STATIC,10,55,17,8
LTEXT "ErrorCode",IDC_STATIC,10,73,37,8
EDITTEXT IDC_EDIT5,203,7,204,269,ES_MULTILINE | ES_AUTOHSCROLL | ES_WANTRETURN | WS_VSCROLL | WS_HSCROLL
PUSHBUTTON "MesUnInit",IDC_BUTTON5,119,237,71,39
PUSHBUTTON "Mes-Save",IDC_BUTTON6,27,207,71,22
PUSHBUTTON "Mes-Get",IDC_BUTTON7,119,206,71,22
EDITTEXT IDC_EDIT6,57,85,134,14,ES_AUTOHSCROLL
LTEXT "ErrorDesc",IDC_STATIC,9,91,37,8
PUSHBUTTON "MesEnd2",IDC_BUTTON8,119,172,71,22
PUSHBUTTON "MesStart2",IDC_BUTTON9,28,172,71,23
EDITTEXT IDC_EDIT7,57,104,134,14,ES_AUTOHSCROLL
LTEXT "All Data",IDC_STATIC,9,110,33,8
END
/////////////////////////////////////////////////////////////////////////////
//
// Version
//
VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,0,0,1
PRODUCTVERSION 1,0,0,1
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
FILEFLAGS 0x1L
#else
FILEFLAGS 0x0L
#endif
FILEOS 0x4L
FILETYPE 0x1L
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "080403a8"
BEGIN
VALUE "CompanyName", "TODO: <<3C><>˾<EFBFBD><CBBE>>"
VALUE "FileDescription", "TODO: <<3C>ļ<EFBFBD>˵<EFBFBD><CBB5>>"
VALUE "FileVersion", "1.0.0.1"
VALUE "InternalName", "HQSFC_Tester.exe"
VALUE "LegalCopyright", "TODO: (C) <<3C><>˾<EFBFBD><CBBE>><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȩ<EFBFBD><C8A8><EFBFBD><EFBFBD>"
VALUE "OriginalFilename", "HQSFC_Tester.exe"
VALUE "ProductName", "TODO: <<3C><>Ʒ<EFBFBD><C6B7>>"
VALUE "ProductVersion", "1.0.0.1"
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", 0x804, 936
END
END
/////////////////////////////////////////////////////////////////////////////
//
// DESIGNINFO
//
#ifdef APSTUDIO_INVOKED
GUIDELINES DESIGNINFO
BEGIN
IDD_ABOUTBOX, DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 228
TOPMARGIN, 7
BOTTOMMARGIN, 48
END
IDD_HQSFC_TESTER_DIALOG, DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 407
TOPMARGIN, 7
BOTTOMMARGIN, 276
END
END
#endif // APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// String Table
//
STRINGTABLE
BEGIN
IDS_ABOUTBOX "<22><><EFBFBD><EFBFBD> HQSFC_Tester(&A)..."
END
#endif // <20><><EFBFBD><EFBFBD>(<28><><EFBFBD><EFBFBD>й<EFBFBD>) resources
/////////////////////////////////////////////////////////////////////////////
#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//
#define _AFX_NO_SPLITTER_RESOURCES
#define _AFX_NO_OLE_RESOURCES
#define _AFX_NO_TRACKER_RESOURCES
#define _AFX_NO_PROPERTY_RESOURCES
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_CHS)
LANGUAGE 4, 2
#pragma code_page(936)
#include "res\HQSFC_Tester.rc2" // <20><> Microsoft Visual C++ <20><EFBFBD><E0BCAD><EFBFBD><EFBFBD>Դ
#include "afxres.rc" // <20><>׼<EFBFBD><D7BC><EFBFBD><EFBFBD>
#endif
/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED

View File

@@ -0,0 +1,23 @@

Microsoft Visual Studio Solution File, Format Version 11.00
# Visual Studio 2010
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "HQSFC_Tester", "HQSFC_Tester.vcxproj", "{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Win32 = Debug|Win32
Release|Win32 = Release|Win32
Template|Win32 = Template|Win32
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}.Debug|Win32.ActiveCfg = Debug|Win32
{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}.Debug|Win32.Build.0 = Debug|Win32
{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}.Release|Win32.ActiveCfg = Release|Win32
{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}.Release|Win32.Build.0 = Release|Win32
{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}.Template|Win32.ActiveCfg = Template|Win32
{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}.Template|Win32.Build.0 = Template|Win32
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
EndGlobal

View File

@@ -0,0 +1,272 @@
<?xml version="1.0" encoding="gb2312"?>
<VisualStudioProject
ProjectType="Visual C++"
Version="8.00"
Name="HQSFC_Tester"
ProjectGUID="{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}"
RootNamespace="HQSFC_Tester"
Keyword="MFCProj"
>
<Platforms>
<Platform
Name="Win32"
/>
</Platforms>
<ToolFiles>
</ToolFiles>
<Configurations>
<Configuration
Name="Debug|Win32"
OutputDirectory="$(SolutionDir)$(ConfigurationName)"
IntermediateDirectory="$(ConfigurationName)"
ConfigurationType="1"
UseOfMFC="1"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
PreprocessorDefinitions="_DEBUG"
MkTypLibCompatible="false"
ValidateParameters="false"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
PreprocessorDefinitions="WIN32;_WINDOWS;_DEBUG"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="1"
UsePrecompiledHeader="2"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="4"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
PreprocessorDefinitions="_DEBUG"
Culture="2052"
AdditionalIncludeDirectories="$(IntDir)"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
LinkIncremental="2"
GenerateDebugInformation="true"
SubSystem="2"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Release|Win32"
OutputDirectory="$(SolutionDir)$(ConfigurationName)"
IntermediateDirectory="$(ConfigurationName)"
ConfigurationType="1"
UseOfMFC="1"
CharacterSet="2"
WholeProgramOptimization="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
PreprocessorDefinitions="NDEBUG"
MkTypLibCompatible="false"
ValidateParameters="false"
/>
<Tool
Name="VCCLCompilerTool"
PreprocessorDefinitions="WIN32;_WINDOWS;NDEBUG"
MinimalRebuild="false"
RuntimeLibrary="0"
UsePrecompiledHeader="2"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
PreprocessorDefinitions="NDEBUG"
Culture="2052"
AdditionalIncludeDirectories="$(IntDir)"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
LinkIncremental="1"
GenerateDebugInformation="true"
SubSystem="2"
OptimizeReferences="2"
EnableCOMDATFolding="2"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations>
<References>
</References>
<Files>
<Filter
Name="Դ<>ļ<EFBFBD>"
Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
>
<File
RelativePath=".\HQSFC_Tester.cpp"
>
</File>
<File
RelativePath=".\HQSFC_TesterDlg.cpp"
>
</File>
<File
RelativePath=".\stdafx.cpp"
>
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="1"
/>
</FileConfiguration>
<FileConfiguration
Name="Release|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="1"
/>
</FileConfiguration>
</File>
</Filter>
<Filter
Name="ͷ<>ļ<EFBFBD>"
Filter="h;hpp;hxx;hm;inl;inc;xsd"
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
>
<File
RelativePath=".\HQSFC_Tester.h"
>
</File>
<File
RelativePath=".\HQSFC_TesterDlg.h"
>
</File>
<File
RelativePath=".\Resource.h"
>
</File>
<File
RelativePath=".\stdafx.h"
>
</File>
</Filter>
<Filter
Name="<22><>Դ<EFBFBD>ļ<EFBFBD>"
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
>
<File
RelativePath=".\res\HQSFC_Tester.ico"
>
</File>
<File
RelativePath=".\HQSFC_Tester.rc"
>
</File>
<File
RelativePath=".\res\HQSFC_Tester.rc2"
>
</File>
</Filter>
<File
RelativePath=".\ReadMe.txt"
>
</File>
</Files>
<Globals>
<Global
Name="RESOURCE_FILE"
Value="HQSFC_Tester.rc"
/>
</Globals>
</VisualStudioProject>

View File

@@ -0,0 +1,154 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Template|Win32">
<Configuration>Template</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup Label="Globals">
<ProjectGuid>{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}</ProjectGuid>
<RootNamespace>HQSFC_Tester</RootNamespace>
<Keyword>MFCProj</Keyword>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseOfMfc>Static</UseOfMfc>
<CharacterSet>MultiByte</CharacterSet>
<WholeProgramOptimization>true</WholeProgramOptimization>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseOfMfc>Static</UseOfMfc>
<CharacterSet>MultiByte</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Template|Win32'">
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup>
<_ProjectFileVersion>10.0.40219.1</_ProjectFileVersion>
<OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(SolutionDir)$(Configuration)\</OutDir>
<IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(Configuration)\</IntDir>
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</LinkIncremental>
<OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(SolutionDir)$(Configuration)\</OutDir>
<IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(Configuration)\</IntDir>
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">false</LinkIncremental>
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">AllRules.ruleset</CodeAnalysisRuleSet>
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" />
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" />
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">AllRules.ruleset</CodeAnalysisRuleSet>
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" />
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" />
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Template|Win32'">AllRules.ruleset</CodeAnalysisRuleSet>
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Template|Win32'" />
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Template|Win32'" />
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Midl>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MkTypLibCompatible>false</MkTypLibCompatible>
<ValidateAllParameters>false</ValidateAllParameters>
</Midl>
<ClCompile>
<Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;_WINDOWS;_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MinimalRebuild>true</MinimalRebuild>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
<PrecompiledHeader>Use</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
<AdditionalIncludeDirectories>$(SolutionDir)\json;</AdditionalIncludeDirectories>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<Culture>0x0804</Culture>
<AdditionalIncludeDirectories>$(IntDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ResourceCompile>
<Link>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
<TargetMachine>MachineX86</TargetMachine>
<AdditionalLibraryDirectories>$(SolutionDir)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<AdditionalDependencies>json_vc71_libmt.lib</AdditionalDependencies>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Midl>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MkTypLibCompatible>false</MkTypLibCompatible>
<ValidateAllParameters>false</ValidateAllParameters>
</Midl>
<ClCompile>
<PreprocessorDefinitions>WIN32;_WINDOWS;NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MinimalRebuild>false</MinimalRebuild>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<PrecompiledHeader>Use</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<Culture>0x0804</Culture>
<AdditionalIncludeDirectories>$(IntDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ResourceCompile>
<Link>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
<OptimizeReferences>true</OptimizeReferences>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<TargetMachine>MachineX86</TargetMachine>
</Link>
</ItemDefinitionGroup>
<ItemGroup>
<ClCompile Include="HQSFC_Tester.cpp" />
<ClCompile Include="HQSFC_TesterDlg.cpp" />
<ClCompile Include="stdafx.cpp">
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="HQSFC_Tester.h" />
<ClInclude Include="HQSFC_TesterDlg.h" />
<ClInclude Include="Resource.h" />
<ClInclude Include="stdafx.h" />
</ItemGroup>
<ItemGroup>
<None Include="res\HQSFC_Tester.ico" />
<None Include="res\HQSFC_Tester.rc2" />
<None Include="ReadMe.txt" />
</ItemGroup>
<ItemGroup>
<ResourceCompile Include="HQSFC_Tester.rc" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
<ProjectExtensions>
<VisualStudio>
<UserProperties RESOURCE_FILE="HQSFC_Tester.rc" />
</VisualStudio>
</ProjectExtensions>
</Project>

View File

@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup />
</Project>

View File

@@ -0,0 +1,410 @@
// HQSFC_TesterDlg.cpp : ʵ<><CAB5><EFBFBD>ļ<EFBFBD>
//
#include "stdafx.h"
#include "HQSFC_Tester.h"
#include "HQSFC_TesterDlg.h"
#include"json.h"
#include <iostream>
#ifdef _DEBUG
#define new DEBUG_NEW
#endif
using namespace std;
// <20><><EFBFBD><EFBFBD>Ӧ<EFBFBD>ó<EFBFBD><C3B3>򡰹<EFBFBD><F2A1B0B9>ڡ<EFBFBD><DAA1>˵<EFBFBD><CBB5><EFBFBD><EFBFBD><EFBFBD> CAboutDlg <20>Ի<EFBFBD><D4BB><EFBFBD>
class CAboutDlg : public CDialog
{
public:
CAboutDlg();
// <20>Ի<EFBFBD><D4BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
enum { IDD = IDD_ABOUTBOX };
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV ֧<><D6A7>
// ʵ<><CAB5>
protected:
DECLARE_MESSAGE_MAP()
};
CAboutDlg::CAboutDlg() : CDialog(CAboutDlg::IDD)
{
}
void CAboutDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
}
BEGIN_MESSAGE_MAP(CAboutDlg, CDialog)
END_MESSAGE_MAP()
// CHQSFC_TesterDlg <20>Ի<EFBFBD><D4BB><EFBFBD>
CHQSFC_TesterDlg::CHQSFC_TesterDlg(CWnd* pParent /*=NULL*/)
: CDialog(CHQSFC_TesterDlg::IDD, pParent)
{
m_hIcon = AfxGetApp()->LoadIcon(IDR_MAINFRAME);
h_Mes = NULL;
}
void CHQSFC_TesterDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
DDX_Control(pDX, IDC_EDIT1, m_EdtDSN);
DDX_Control(pDX, IDC_EDIT2, m_Station);
DDX_Control(pDX, IDC_EDIT3, m_Tool);
DDX_Control(pDX, IDC_EDIT4, m_Error);
DDX_Control(pDX, IDC_EDIT5, m_log);
DDX_Control(pDX, IDC_EDIT6, m_ErrorDesc);
DDX_Control(pDX, IDC_EDIT7, m_AllData);
}
BEGIN_MESSAGE_MAP(CHQSFC_TesterDlg, CDialog)
ON_WM_SYSCOMMAND()
ON_WM_PAINT()
ON_WM_QUERYDRAGICON()
//}}AFX_MSG_MAP
ON_BN_CLICKED(IDC_BUTTON1, &CHQSFC_TesterDlg::OnBnClickedButton1)
ON_BN_CLICKED(IDC_BUTTON2, &CHQSFC_TesterDlg::OnBnClickedButton2)
ON_BN_CLICKED(IDC_BUTTON3, &CHQSFC_TesterDlg::OnBnClickedButton3)
ON_BN_CLICKED(IDC_BUTTON4, &CHQSFC_TesterDlg::OnBnClickedButton4)
ON_BN_CLICKED(IDC_BUTTON5, &CHQSFC_TesterDlg::OnBnClickedButton5)
ON_BN_CLICKED(IDC_BUTTON6, &CHQSFC_TesterDlg::OnBnClickedButton6)
ON_BN_CLICKED(IDC_BUTTON7, &CHQSFC_TesterDlg::OnBnClickedButton7)
ON_BN_CLICKED(IDC_BUTTON9, &CHQSFC_TesterDlg::OnBnClickedButton9)
ON_BN_CLICKED(IDC_BUTTON8, &CHQSFC_TesterDlg::OnBnClickedButton8)
END_MESSAGE_MAP()
// CHQSFC_TesterDlg <20><>Ϣ<EFBFBD><CFA2><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
BOOL CHQSFC_TesterDlg::OnInitDialog()
{
CDialog::OnInitDialog();
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>...<2E><><EFBFBD>˵<EFBFBD><CBB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ӵ<EFBFBD>ϵͳ<CFB5>˵<EFBFBD><CBB5>С<EFBFBD>
// IDM_ABOUTBOX <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϵͳ<CFB5><CDB3><EFBFBD>Χ<EEB7B6>ڡ<EFBFBD>
ASSERT((IDM_ABOUTBOX & 0xFFF0) == IDM_ABOUTBOX);
ASSERT(IDM_ABOUTBOX < 0xF000);
CMenu* pSysMenu = GetSystemMenu(FALSE);
if (pSysMenu != NULL)
{
CString strAboutMenu;
strAboutMenu.LoadString(IDS_ABOUTBOX);
if (!strAboutMenu.IsEmpty())
{
pSysMenu->AppendMenu(MF_SEPARATOR);
pSysMenu->AppendMenu(MF_STRING, IDM_ABOUTBOX, strAboutMenu);
}
}
// <20><><EFBFBD>ô˶Ի<CBB6><D4BB><EFBFBD><EFBFBD><EFBFBD>ͼ<EFBFBD><EFBFBD><EAA1A3>Ӧ<EFBFBD>ó<EFBFBD><C3B3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ڲ<EFBFBD><DAB2>ǶԻ<C7B6><D4BB><EFBFBD>ʱ<EFBFBD><CAB1><EFBFBD><EFBFBD><EFBFBD>ܽ<EFBFBD><DCBD>Զ<EFBFBD>
// ִ<>д˲<D0B4><CBB2><EFBFBD>
SetIcon(m_hIcon, TRUE); // <20><><EFBFBD>ô<EFBFBD>ͼ<EFBFBD><CDBC>
SetIcon(m_hIcon, FALSE); // <20><><EFBFBD><EFBFBD>Сͼ<D0A1><CDBC>
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>Ӷ<EFBFBD><D3B6><EFBFBD><EFBFBD>ij<EFBFBD>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
return TRUE; // <20><><EFBFBD>ǽ<EFBFBD><C7BD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>õ<EFBFBD><C3B5>ؼ<EFBFBD><D8BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>򷵻<EFBFBD> TRUE
}
long CHQSFC_TesterDlg::LoadDll()
{
//char sPath[MAX_PATH];
//memset(sPath, 0, MAX_PATH);
//GetModuleFileName(NULL,sPath,MAX_PATH-1);
//CString sDir;
//sDir.Format("%s", sPath);
//sDir = sDir.Left(sDir.ReverseFind('\\'));
//CString sDllPath = sDir+"\\HQMES.dll";
CString sDllPath = _T("HQMES.dll");
m_hHandle = LoadLibrary(sDllPath);
if (NULL == m_hHandle)
{
AfxMessageBox(_T("Load DLL fail!"));
return 1;
}
m_funcCheckFlow = (FUNC_CHECKFLOW)GetProcAddress(m_hHandle, _T("MesStart"));
m_funcCheckFlow2 = (FUNC_CHECKFLOW2)GetProcAddress(m_hHandle, _T("MesStart2"));
m_funcUpdateFlow = (FUNC_UPDATEFLOW)GetProcAddress(m_hHandle, _T("MesEnd"));
m_funcUpdateFlow2 = (FUNC_UPDATEFLOW2)GetProcAddress(m_hHandle, _T("MesEnd2"));
m_funcInit = (FUNC_INIT)GetProcAddress(m_hHandle, _T("MesInit"));
m_funcUnInit = (FUNC_UNINIT)GetProcAddress(m_hHandle, _T("MesUnInit"));
m_funcSaveAndGetExtraInfo = (FUNC_SAVEANDGETEXTRAINFO)GetProcAddress(m_hHandle, _T("MesSaveAndGetExtraInfo"));
if (NULL == m_funcCheckFlow ||
NULL == m_funcUpdateFlow ||
NULL == m_funcInit ||
NULL == m_funcUnInit ||
NULL == m_funcSaveAndGetExtraInfo
)
{
AfxMessageBox(_T("Load Func fail!"));
FreeLibrary(m_hHandle);
return 2;
}
return 0;
}
void CHQSFC_TesterDlg::OnSysCommand(UINT nID, LPARAM lParam)
{
if ((nID & 0xFFF0) == IDM_ABOUTBOX)
{
CAboutDlg dlgAbout;
dlgAbout.DoModal();
}
else
{
CDialog::OnSysCommand(nID, lParam);
}
}
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ի<EFBFBD><D4BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>С<EFBFBD><D0A1><EFBFBD><EFBFBD>ť<EFBFBD><C5A5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ҫ<EFBFBD><D2AA><EFBFBD><EFBFBD><EFBFBD>Ĵ<EFBFBD><C4B4><EFBFBD>
// <20><><EFBFBD><EFBFBD><EFBFBD>Ƹ<EFBFBD>ͼ<EFBFBD><EFBFBD><EAA1A3><EFBFBD><EFBFBD>ʹ<EFBFBD><CAB9><EFBFBD>ĵ<EFBFBD>/<2F><>ͼģ<CDBC>͵<EFBFBD> MFC Ӧ<>ó<EFBFBD><C3B3><EFBFBD><EFBFBD><EFBFBD>
// <20><EFBFBD>ɿ<EFBFBD><C9BF><EFBFBD><EFBFBD>Զ<EFBFBD><D4B6><EFBFBD><EFBFBD>ɡ<EFBFBD>
void CHQSFC_TesterDlg::OnPaint()
{
if (IsIconic())
{
CPaintDC dc(this); // <20><><EFBFBD>ڻ<EFBFBD><DABB>Ƶ<EFBFBD><C6B5><EFBFBD><E8B1B8><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
SendMessage(WM_ICONERASEBKGND, reinterpret_cast<WPARAM>(dc.GetSafeHdc()), 0);
// ʹͼ<CAB9><CDBC><EFBFBD>ڹ<EFBFBD><DAB9><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>о<EFBFBD><D0BE><EFBFBD>
int cxIcon = GetSystemMetrics(SM_CXICON);
int cyIcon = GetSystemMetrics(SM_CYICON);
CRect rect;
GetClientRect(&rect);
int x = (rect.Width() - cxIcon + 1) / 2;
int y = (rect.Height() - cyIcon + 1) / 2;
// <20><><EFBFBD><EFBFBD>ͼ<EFBFBD><CDBC>
dc.DrawIcon(x, y, m_hIcon);
}
else
{
CDialog::OnPaint();
}
}
//<2F><><EFBFBD>û<EFBFBD><C3BB>϶<EFBFBD><CFB6><EFBFBD>С<EFBFBD><D0A1><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱϵͳ<CFB5><CDB3><EFBFBD>ô˺<C3B4><CBBA><EFBFBD>ȡ<EFBFBD>ù<EFBFBD><C3B9><EFBFBD><EFBFBD><EFBFBD>ʾ<EFBFBD><CABE>
//
HCURSOR CHQSFC_TesterDlg::OnQueryDragIcon()
{
return static_cast<HCURSOR>(m_hIcon);
}
void CHQSFC_TesterDlg::OnBnClickedButton1()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
//CheckFlow
if( 0!=LoadDll()) return ;
CString sDSN;//<2F><><EFBFBD>̼<EFBFBD><CCBC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>SN
m_EdtDSN.GetWindowText(sDSN);
CString sStation;//<2F><><EFBFBD>̼<EFBFBD><CCBC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>վλ
m_Station.GetWindowText(sStation);
CString sTools;//<2F><><EFBFBD>ߵİ汾
m_Tool.GetWindowText(sTools);
CString sError;//MES<45><53><EFBFBD>ص<EFBFBD><D8B5><EFBFBD>Ϣ
m_Error.GetWindowText(sError);
CString sTmp;
// LPCSTR StationJob, LPCSTR Tools ,char* sErrorInfo
CString oErrInfo;
int len = 102400;
int iRet = m_funcCheckFlow(h_Mes,sDSN,sStation,sTools,oErrInfo.GetBuffer(len), &len );
//iRet<65><74>ʾ<EFBFBD><CABE>վ<EFBFBD>Ľ<EFBFBD><C4BD><EFBFBD><EFBFBD><EFBFBD>0<EFBFBD><30>ʾ<EFBFBD>ɹ<EFBFBD><C9B9><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʾʧ<CABE><CAA7>
oErrInfo.ReleaseBuffer(len);
//<2F><><EFBFBD><EFBFBD>ȡ<EFBFBD><C8A1><EFBFBD>ֶν<D6B6><CEBD><EFBFBD>,<2C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>CSN<53>Ľ<EFBFBD><C4BD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
string CSN = "";
Json::Reader reader;
Json::Value root;
if (reader.parse(oErrInfo.GetBuffer(0), root))
{
string H_MSG = root["H_MSG"].asString();//<2F><>ʾMES<45><53><EFBFBD>صĴ<D8B5><C4B4><EFBFBD><EFBFBD><EFBFBD>Ϣ<EFBFBD><CFA2><EFBFBD><EFBFBD>m_funcCheckFlowʧ<77>ܵ<EFBFBD>ʱ<EFBFBD><CAB1><EFBFBD><EFBFBD><EFBFBD>ý<EFBFBD><C3BD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϣչʾ<D5B9><CABE><EFBFBD><EFBFBD>
CSN = root["DATA"]["CSN"].asString();//CSN<53><4E>DATA<54>ڵ<EFBFBD><DAB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>MES<45>·<EFBFBD><C2B7><EFBFBD><EFBFBD>ֶΣ<D6B6><CEA3><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ֶ<EFBFBD><D6B6><EFBFBD><EFBFBD>ο<EFBFBD><CEBF><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>MESHelper<65>ӿڹ<D3BF><DAB9><EFBFBD>ʹ<EFBFBD><CAB9>˵<EFBFBD><CBB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ַ<EFBFBD>ʽ<EFBFBD><CABD>ȡ
}
sTmp.Format(_T("CheckFlow=0x%04x,Info=%s"),iRet, oErrInfo);
AfxMessageBox(sTmp);
}
void CHQSFC_TesterDlg::OnBnClickedButton2()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
if( 0!=LoadDll()) return ;
//UpdateFlow
CString sDSN;
m_EdtDSN.GetWindowText(sDSN);
CString sStation;
m_Station.GetWindowText(sStation);
CString sTools;//վλ
m_Tool.GetWindowText(sTools);
CString sError;//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> 0<><30>ʾ<EFBFBD><CABE><EFBFBD>߶<EFBFBD><DFB6><EFBFBD><EFBFBD>ɹ<EFBFBD><C9B9><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ҫ<EFBFBD><D2AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ִ<EFBFBD><D6B4><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>MESЭ<53>̻<EFBFBD>ȡ
m_Error.GetWindowText(sError);
CString sErrorDesc;//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
m_ErrorDesc.GetWindowText(sErrorDesc);
CString sTmp;
// LPCSTR StationJob, LPCSTR Tools ,char* sErrorInfo
int len = 102400;
int iRet = m_funcUpdateFlow(h_Mes,sDSN,sStation,sTools,sError,sErrorDesc.GetBuffer(len), &len);
sErrorDesc.ReleaseBuffer(len);
//iRet<65><74>ʾ<EFBFBD><CABE>վ<EFBFBD><D5BE>״̬<D7B4><CCAC>0<EFBFBD><30>ʾ<EFBFBD>ɹ<EFBFBD><C9B9><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʾʧ<CABE><CAA7>
//<2F><><EFBFBD><EFBFBD><EFBFBD>Ľ<EFBFBD><C4BD><EFBFBD>
string CSN = "";
Json::Reader reader;
Json::Value root;
if (reader.parse(sErrorDesc.GetBuffer(0), root))
{
string H_MSG = root["H_MSG"].asString();//<2F><>ʾMES<45><53><EFBFBD>صĴ<D8B5><C4B4><EFBFBD><EFBFBD><EFBFBD>Ϣ<EFBFBD><CFA2><EFBFBD><EFBFBD>m_funcUpdateFlowʧ<77>ܵ<EFBFBD>ʱ<EFBFBD><CAB1><EFBFBD><EFBFBD><EFBFBD>ý<EFBFBD><C3BD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϣչʾ<D5B9><CABE><EFBFBD><EFBFBD>
string G_NEXTWS = root["G_NEXTWS"].asString();//<2F><>ʾ<EFBFBD><CABE>һ<EFBFBD><D2BB><EFBFBD><EFBFBD>λ
}
//
sTmp.Format(_T("UpdateFlow=0x%04x,Info=%s"),iRet,sErrorDesc);
AfxMessageBox(sTmp);
}
CHQSFC_TesterDlg *pHQSFC;
int ShowLog2(char* msg)
{
if(pHQSFC!=NULL)
return pHQSFC->ShowLog(msg);
return 1;
}
void CHQSFC_TesterDlg::OnBnClickedButton3()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
if( 0!=LoadDll()) return ;
CString sTmp;
// LPCSTR StationJob, LPCSTR Tools ,char* sErrorInfo
pHQSFC = this;
CString oErrInfo;
int len = 102400;
int iRet = m_funcInit( ShowLog2 ,&h_Mes, oErrInfo.GetBuffer(len) , &len);
oErrInfo.ReleaseBuffer(len);
sTmp.Format(_T("Init=0x%04x,Info=%s"),iRet,oErrInfo);
AfxMessageBox(sTmp);
}
void CHQSFC_TesterDlg::OnBnClickedButton4()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
m_log.SetWindowText(_T(""));
}
int CHQSFC_TesterDlg::ShowLog(char* msg)
{
CString str ;
m_log.GetWindowText(str);
str.AppendFormat( _T("%s"), msg);
m_log.SetWindowText(str);
return 0;
}
void CHQSFC_TesterDlg::OnBnClickedButton5()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
int iRet = m_funcUnInit( h_Mes );
}
void CHQSFC_TesterDlg::OnBnClickedButton6()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
CString oErrInfo;
int len = 102400; // CString G_TYPE, CString G_POSITION, CString G_KEY, CString G_VALUE, CString G_EXTINFO
int iRet = m_funcSaveAndGetExtraInfo( h_Mes ,_T("1"),_T("TestNodeJs"),_T("CPP_G_KEY"),_T("CPP_G_VALUE"),_T("CPP_G_EXTINFO"),oErrInfo.GetBuffer(len), &len );
oErrInfo.ReleaseBuffer(len);
CString sTmp;
sTmp.Format(_T("SaveAndGetExtraInfo=0x%04x,Info=%s"),iRet,oErrInfo);
AfxMessageBox(sTmp);
}
void CHQSFC_TesterDlg::OnBnClickedButton7()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
CString oErrInfo;
int len = 102400; // CString G_TYPE, CString G_POSITION, CString G_KEY, CString G_VALUE, CString G_EXTINFO
int iRet = m_funcSaveAndGetExtraInfo( h_Mes ,_T("2"),_T("TestNodeJs"),_T("CPP_G_KEY"),_T(""),_T(""),oErrInfo.GetBuffer(len), &len );
oErrInfo.ReleaseBuffer(len);
CString sTmp;
sTmp.Format(_T("SaveAndGetExtraInfo=0x%04x,Info=%s"),iRet,oErrInfo);
AfxMessageBox(sTmp);
}
void CHQSFC_TesterDlg::OnBnClickedButton9()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
if( 0!=LoadDll()) return ;
CString sDSN;
m_EdtDSN.GetWindowText(sDSN);
CString sStation;
m_Station.GetWindowText(sStation);
CString sTools;
m_Tool.GetWindowText(sTools);
CString sError;
m_Error.GetWindowText(sError);
CString sTmp;
// LPCSTR StationJob, LPCSTR Tools ,char* sErrorInfo
CString oErrInfo;
int len = 102400;
CString SNType = _T("1");//<2F><>ʾ<EFBFBD><CABE>վ<EFBFBD><D5BE><EFBFBD><EFBFBD><EFBFBD>ݵ<EFBFBD><DDB5><EFBFBD><EFBFBD>ͣ<EFBFBD><CDA3><EFBFBD><EFBFBD>Ǹ<EFBFBD>m_funcCheckFlow<6F><77><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>1 SN 2 IMEI 3 CSN 4 <20><><EFBFBD><EFBFBD> 5 WiFi 6 <20><><EFBFBD><EFBFBD>֤
int iRet = m_funcCheckFlow2(h_Mes,sDSN, SNType ,sStation,sTools,oErrInfo.GetBuffer(len), &len );//ʹ<>úͽ<C3BA><CDBD><EFBFBD><EFBFBD>ķ<EFBFBD><C4B7><EFBFBD><EFBFBD><EFBFBD>m_funcCheckFlowһ<77><D2BB>
oErrInfo.ReleaseBuffer(len);
sTmp.Format(_T("CheckFlow=0x%04x,Info=%s"),iRet,oErrInfo);
AfxMessageBox(sTmp);
}
void CHQSFC_TesterDlg::OnBnClickedButton8()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
if( 0!=LoadDll()) return ;
//UpdateFlow
CString sDSN;
m_EdtDSN.GetWindowText(sDSN);
CString sStation;
m_Station.GetWindowText(sStation);
CString sTools;
m_Tool.GetWindowText(sTools);
CString sError;
m_Error.GetWindowText(sError);
CString sErrorDesc;
m_ErrorDesc.GetWindowText(sErrorDesc);
CString sAllData;
m_AllData.GetWindowText(sAllData);
CString sTmp;
// LPCSTR StationJob, LPCSTR Tools ,char* sErrorInfo
int len = 102400;
//m_funcUpdateFlow2<77>IJ<EFBFBD><C4B2><EFBFBD><EFBFBD><EFBFBD>m_funcUpdateFlow<6F><77>һ<EFBFBD><D2BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݵ<EFBFBD><DDB5><EFBFBD><EFBFBD>ͺ<EFBFBD><CDBA>ϴ<EFBFBD><CFB4><EFBFBD><EFBFBD>ֶ<EFBFBD>
//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ҫ<EFBFBD>ϴ<EFBFBD><CFB4>ֶ<EFBFBD>a ֵΪ1
//string data = "";
//Json::Value root;
//root["a"] = Json::Value("1");
//Json::FastWriter fw;
//data = fw.write(root);
//sAllData = data.GetBuffer(0);
//<2F><>data<74><61>SAlldata<74><61>ֵ<EFBFBD><D6B5><EFBFBD><EFBFBD><EFBFBD>ϴ<EFBFBD>
//m_funcUpdateFlow2<77><32><EFBFBD><EFBFBD><EFBFBD>ķ<EFBFBD><C4B7><EFBFBD>ֵ<EFBFBD>Ͳ<EFBFBD><CDB2><EFBFBD><EFBFBD>Ľ<EFBFBD><C4BD><EFBFBD><EFBFBD><EFBFBD>m_funcUpdateFlowһ<77><D2BB>
int iRet = m_funcUpdateFlow2(h_Mes,sDSN,"1",sStation,sTools,sError,sAllData,sErrorDesc.GetBuffer(len), &len);
sErrorDesc.ReleaseBuffer(len);
sTmp.Format("UpdateFlow=0x%04x,Info=%s",iRet,sErrorDesc);
AfxMessageBox(sTmp);
}

View File

@@ -0,0 +1,72 @@
// HQSFC_TesterDlg.h : ͷ<>ļ<EFBFBD>
//
#pragma once
#include "afxwin.h"
typedef int (__stdcall *FUNC_CHECKFLOW)(HANDLE hMes ,LPCSTR sDSN, LPCSTR StationJob, LPCSTR Tools ,char* sErrorInfo/*out*/, int*InfoLen /*in out*/ );
typedef int (__stdcall *FUNC_CHECKFLOW2)(HANDLE hMes ,LPCSTR sDSN,LPCSTR SNType, LPCSTR StationJob, LPCSTR Tools ,char* sErrorInfo/*out*/, int*InfoLen /*in out*/ );
typedef int (__stdcall *FUNC_UPDATEFLOW)(HANDLE hMes , LPCSTR sDSN,LPCSTR StationJob,LPCSTR Tools,LPCSTR ErrorCode, char* sErrorInfo /*out*/, int*InfoLen /*in out*/ );
typedef int (__stdcall *FUNC_UPDATEFLOW2)(HANDLE hMes , LPCSTR sDSN,LPCSTR SNType,LPCSTR StationJob,LPCSTR Tools,LPCSTR ErrorCode, LPCSTR AllData,char* sErrorInfo /*in out*/, int*InfoLen /*in out*/ );
typedef int (*FUNC_LOG)(char* msg);
typedef int (__stdcall *FUNC_INIT)(FUNC_LOG func,HANDLE *hMes , char* sErrorInfo/*out*/, int*InfoLen /*in out*/ );
typedef int (__stdcall *FUNC_UNINIT)(HANDLE hMes );
typedef int (__stdcall *FUNC_SAVEANDGETEXTRAINFO)(HANDLE hMes ,LPCSTR G_TYPE, LPCSTR G_POSITION, LPCSTR G_KEY, LPCSTR G_VALUE, LPCSTR G_EXTINFO, TCHAR* sErrorInfo/*out*/, int*InfoLen /*in out*/ );
// CHQSFC_TesterDlg <20>Ի<EFBFBD><D4BB><EFBFBD>
class CHQSFC_TesterDlg : public CDialog
{
// <20><><EFBFBD><EFBFBD>
public:
CHQSFC_TesterDlg(CWnd* pParent = NULL); // <20><>׼<EFBFBD><D7BC><EFBFBD><EFBFBD><ECBAAF>
// <20>Ի<EFBFBD><D4BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
enum { IDD = IDD_HQSFC_TESTER_DIALOG };
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV ֧<><D6A7>
// ʵ<><CAB5>
protected:
HICON m_hIcon;
// <20><><EFBFBD>ɵ<EFBFBD><C9B5><EFBFBD>Ϣӳ<CFA2><EFBFBD><E4BAAF>
virtual BOOL OnInitDialog();
afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
afx_msg void OnPaint();
afx_msg HCURSOR OnQueryDragIcon();
DECLARE_MESSAGE_MAP()
public:
afx_msg void OnBnClickedButton1();
afx_msg void OnBnClickedButton2();
HMODULE m_hHandle;
FUNC_CHECKFLOW m_funcCheckFlow;
FUNC_CHECKFLOW2 m_funcCheckFlow2;
FUNC_UPDATEFLOW m_funcUpdateFlow;
FUNC_UPDATEFLOW2 m_funcUpdateFlow2;
FUNC_INIT m_funcInit;
FUNC_UNINIT m_funcUnInit;
FUNC_SAVEANDGETEXTRAINFO m_funcSaveAndGetExtraInfo;
long LoadDll();
CEdit m_EdtDSN;
public:
afx_msg void OnBnClickedButton3();
public:
afx_msg void OnBnClickedButton4();
CEdit m_Station;
CEdit m_Tool;
CEdit m_Error;
CEdit m_log;
CEdit m_ErrorDesc;
CEdit m_AllData;
int ShowLog(char*);
afx_msg void OnBnClickedButton5();
HANDLE h_Mes; // MES <20><><EFBFBD><EFBFBD>
afx_msg void OnBnClickedButton6();
afx_msg void OnBnClickedButton7();
afx_msg void OnBnClickedButton9();
afx_msg void OnBnClickedButton8();
};

View File

@@ -0,0 +1,410 @@
// HQSFC_TesterDlg.cpp : ʵ<><CAB5><EFBFBD>ļ<EFBFBD>
//
#include "stdafx.h"
#include "HQSFC_Tester.h"
#include "HQSFC_TesterDlg.h"
#include"json.h"
#include <iostream>
#ifdef _DEBUG
#define new DEBUG_NEW
#endif
using namespace std;
// <20><><EFBFBD><EFBFBD>Ӧ<EFBFBD>ó<EFBFBD><C3B3>򡰹<EFBFBD><F2A1B0B9>ڡ<EFBFBD><DAA1>˵<EFBFBD><CBB5><EFBFBD><EFBFBD><EFBFBD> CAboutDlg <20>Ի<EFBFBD><D4BB><EFBFBD>
class CAboutDlg : public CDialog
{
public:
CAboutDlg();
// <20>Ի<EFBFBD><D4BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
enum { IDD = IDD_ABOUTBOX };
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV ֧<><D6A7>
// ʵ<><CAB5>
protected:
DECLARE_MESSAGE_MAP()
};
CAboutDlg::CAboutDlg() : CDialog(CAboutDlg::IDD)
{
}
void CAboutDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
}
BEGIN_MESSAGE_MAP(CAboutDlg, CDialog)
END_MESSAGE_MAP()
// CHQSFC_TesterDlg <20>Ի<EFBFBD><D4BB><EFBFBD>
CHQSFC_TesterDlg::CHQSFC_TesterDlg(CWnd* pParent /*=NULL*/)
: CDialog(CHQSFC_TesterDlg::IDD, pParent)
{
m_hIcon = AfxGetApp()->LoadIcon(IDR_MAINFRAME);
h_Mes = NULL;
}
void CHQSFC_TesterDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
DDX_Control(pDX, IDC_EDIT1, m_EdtDSN);
DDX_Control(pDX, IDC_EDIT2, m_Station);
DDX_Control(pDX, IDC_EDIT3, m_Tool);
DDX_Control(pDX, IDC_EDIT4, m_Error);
DDX_Control(pDX, IDC_EDIT5, m_log);
DDX_Control(pDX, IDC_EDIT6, m_ErrorDesc);
DDX_Control(pDX, IDC_EDIT7, m_AllData);
}
BEGIN_MESSAGE_MAP(CHQSFC_TesterDlg, CDialog)
ON_WM_SYSCOMMAND()
ON_WM_PAINT()
ON_WM_QUERYDRAGICON()
//}}AFX_MSG_MAP
ON_BN_CLICKED(IDC_BUTTON1, &CHQSFC_TesterDlg::OnBnClickedButton1)
ON_BN_CLICKED(IDC_BUTTON2, &CHQSFC_TesterDlg::OnBnClickedButton2)
ON_BN_CLICKED(IDC_BUTTON3, &CHQSFC_TesterDlg::OnBnClickedButton3)
ON_BN_CLICKED(IDC_BUTTON4, &CHQSFC_TesterDlg::OnBnClickedButton4)
ON_BN_CLICKED(IDC_BUTTON5, &CHQSFC_TesterDlg::OnBnClickedButton5)
ON_BN_CLICKED(IDC_BUTTON6, &CHQSFC_TesterDlg::OnBnClickedButton6)
ON_BN_CLICKED(IDC_BUTTON7, &CHQSFC_TesterDlg::OnBnClickedButton7)
ON_BN_CLICKED(IDC_BUTTON9, &CHQSFC_TesterDlg::OnBnClickedButton9)
ON_BN_CLICKED(IDC_BUTTON8, &CHQSFC_TesterDlg::OnBnClickedButton8)
END_MESSAGE_MAP()
// CHQSFC_TesterDlg <20><>Ϣ<EFBFBD><CFA2><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
BOOL CHQSFC_TesterDlg::OnInitDialog()
{
CDialog::OnInitDialog();
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>...<2E><><EFBFBD>˵<EFBFBD><CBB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ӵ<EFBFBD>ϵͳ<CFB5>˵<EFBFBD><CBB5>С<EFBFBD>
// IDM_ABOUTBOX <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϵͳ<CFB5><CDB3><EFBFBD>Χ<EEB7B6>ڡ<EFBFBD>
ASSERT((IDM_ABOUTBOX & 0xFFF0) == IDM_ABOUTBOX);
ASSERT(IDM_ABOUTBOX < 0xF000);
CMenu* pSysMenu = GetSystemMenu(FALSE);
if (pSysMenu != NULL)
{
CString strAboutMenu;
strAboutMenu.LoadString(IDS_ABOUTBOX);
if (!strAboutMenu.IsEmpty())
{
pSysMenu->AppendMenu(MF_SEPARATOR);
pSysMenu->AppendMenu(MF_STRING, IDM_ABOUTBOX, strAboutMenu);
}
}
// <20><><EFBFBD>ô˶Ի<CBB6><D4BB><EFBFBD><EFBFBD><EFBFBD>ͼ<EFBFBD><EFBFBD><EAA1A3>Ӧ<EFBFBD>ó<EFBFBD><C3B3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ڲ<EFBFBD><DAB2>ǶԻ<C7B6><D4BB><EFBFBD>ʱ<EFBFBD><CAB1><EFBFBD><EFBFBD><EFBFBD>ܽ<EFBFBD><DCBD>Զ<EFBFBD>
// ִ<>д˲<D0B4><CBB2><EFBFBD>
SetIcon(m_hIcon, TRUE); // <20><><EFBFBD>ô<EFBFBD>ͼ<EFBFBD><CDBC>
SetIcon(m_hIcon, FALSE); // <20><><EFBFBD><EFBFBD>Сͼ<D0A1><CDBC>
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>Ӷ<EFBFBD><D3B6><EFBFBD><EFBFBD>ij<EFBFBD>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
return TRUE; // <20><><EFBFBD>ǽ<EFBFBD><C7BD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>õ<EFBFBD><C3B5>ؼ<EFBFBD><D8BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>򷵻<EFBFBD> TRUE
}
long CHQSFC_TesterDlg::LoadDll()
{
//char sPath[MAX_PATH];
//memset(sPath, 0, MAX_PATH);
//GetModuleFileName(NULL,sPath,MAX_PATH-1);
//CString sDir;
//sDir.Format("%s", sPath);
//sDir = sDir.Left(sDir.ReverseFind('\\'));
//CString sDllPath = sDir+"\\HQMES.dll";
CString sDllPath = _T("HQMES.dll");
m_hHandle = LoadLibrary(sDllPath);
if (NULL == m_hHandle)
{
AfxMessageBox(_T("Load DLL fail!"));
return 1;
}
m_funcCheckFlow = (FUNC_CHECKFLOW)GetProcAddress(m_hHandle, _T("MesStart"));
m_funcCheckFlow2 = (FUNC_CHECKFLOW2)GetProcAddress(m_hHandle, _T("MesStart2"));
m_funcUpdateFlow = (FUNC_UPDATEFLOW)GetProcAddress(m_hHandle, _T("MesEnd"));
m_funcUpdateFlow2 = (FUNC_UPDATEFLOW2)GetProcAddress(m_hHandle, _T("MesEnd2"));
m_funcInit = (FUNC_INIT)GetProcAddress(m_hHandle, _T("MesInit"));
m_funcUnInit = (FUNC_UNINIT)GetProcAddress(m_hHandle, _T("MesUnInit"));
m_funcSaveAndGetExtraInfo = (FUNC_SAVEANDGETEXTRAINFO)GetProcAddress(m_hHandle, _T("MesSaveAndGetExtraInfo"));
if (NULL == m_funcCheckFlow ||
NULL == m_funcUpdateFlow ||
NULL == m_funcInit ||
NULL == m_funcUnInit ||
NULL == m_funcSaveAndGetExtraInfo
)
{
AfxMessageBox(_T("Load Func fail!"));
FreeLibrary(m_hHandle);
return 2;
}
return 0;
}
void CHQSFC_TesterDlg::OnSysCommand(UINT nID, LPARAM lParam)
{
if ((nID & 0xFFF0) == IDM_ABOUTBOX)
{
CAboutDlg dlgAbout;
dlgAbout.DoModal();
}
else
{
CDialog::OnSysCommand(nID, lParam);
}
}
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ի<EFBFBD><D4BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>С<EFBFBD><D0A1><EFBFBD><EFBFBD>ť<EFBFBD><C5A5><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ҫ<EFBFBD><D2AA><EFBFBD><EFBFBD><EFBFBD>Ĵ<EFBFBD><C4B4><EFBFBD>
// <20><><EFBFBD><EFBFBD><EFBFBD>Ƹ<EFBFBD>ͼ<EFBFBD><EFBFBD><EAA1A3><EFBFBD><EFBFBD>ʹ<EFBFBD><CAB9><EFBFBD>ĵ<EFBFBD>/<2F><>ͼģ<CDBC>͵<EFBFBD> MFC Ӧ<>ó<EFBFBD><C3B3><EFBFBD><EFBFBD><EFBFBD>
// <20><EFBFBD>ɿ<EFBFBD><C9BF><EFBFBD><EFBFBD>Զ<EFBFBD><D4B6><EFBFBD><EFBFBD>ɡ<EFBFBD>
void CHQSFC_TesterDlg::OnPaint()
{
if (IsIconic())
{
CPaintDC dc(this); // <20><><EFBFBD>ڻ<EFBFBD><DABB>Ƶ<EFBFBD><C6B5><EFBFBD><E8B1B8><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
SendMessage(WM_ICONERASEBKGND, reinterpret_cast<WPARAM>(dc.GetSafeHdc()), 0);
// ʹͼ<CAB9><CDBC><EFBFBD>ڹ<EFBFBD><DAB9><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>о<EFBFBD><D0BE><EFBFBD>
int cxIcon = GetSystemMetrics(SM_CXICON);
int cyIcon = GetSystemMetrics(SM_CYICON);
CRect rect;
GetClientRect(&rect);
int x = (rect.Width() - cxIcon + 1) / 2;
int y = (rect.Height() - cyIcon + 1) / 2;
// <20><><EFBFBD><EFBFBD>ͼ<EFBFBD><CDBC>
dc.DrawIcon(x, y, m_hIcon);
}
else
{
CDialog::OnPaint();
}
}
//<2F><><EFBFBD>û<EFBFBD><C3BB>϶<EFBFBD><CFB6><EFBFBD>С<EFBFBD><D0A1><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱϵͳ<CFB5><CDB3><EFBFBD>ô˺<C3B4><CBBA><EFBFBD>ȡ<EFBFBD>ù<EFBFBD><C3B9><EFBFBD><EFBFBD><EFBFBD>ʾ<EFBFBD><CABE>
//
HCURSOR CHQSFC_TesterDlg::OnQueryDragIcon()
{
return static_cast<HCURSOR>(m_hIcon);
}
void CHQSFC_TesterDlg::OnBnClickedButton1()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
//CheckFlow
if( 0!=LoadDll()) return ;
CString sDSN;//<2F><><EFBFBD>̼<EFBFBD><CCBC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>SN
m_EdtDSN.GetWindowText(sDSN);
CString sStation;//<2F><><EFBFBD>̼<EFBFBD><CCBC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>վλ
m_Station.GetWindowText(sStation);
CString sTools;//<2F><><EFBFBD>ߵİ汾
m_Tool.GetWindowText(sTools);
CString sError;//MES<45><53><EFBFBD>ص<EFBFBD><D8B5><EFBFBD>Ϣ
m_Error.GetWindowText(sError);
CString sTmp;
// LPCSTR StationJob, LPCSTR Tools ,char* sErrorInfo
CString oErrInfo;
int len = 102400;
int iRet = m_funcCheckFlow(h_Mes,sDSN,sStation,sTools,oErrInfo.GetBuffer(len), &len );
//iRet<65><74>ʾ<EFBFBD><CABE>վ<EFBFBD>Ľ<EFBFBD><C4BD><EFBFBD><EFBFBD><EFBFBD>0<EFBFBD><30>ʾ<EFBFBD>ɹ<EFBFBD><C9B9><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʾʧ<CABE><CAA7>
oErrInfo.ReleaseBuffer(len);
//<2F><><EFBFBD><EFBFBD>ȡ<EFBFBD><C8A1><EFBFBD>ֶν<D6B6><CEBD><EFBFBD>,<2C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>CSN<53>Ľ<EFBFBD><C4BD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
string CSN = "";
Json::Reader reader;
Json::Value root;
if (reader.parse(oErrInfo.GetBuffer(0), root))
{
string H_MSG = root["H_MSG"].asString();//<2F><>ʾMES<45><53><EFBFBD>صĴ<D8B5><C4B4><EFBFBD><EFBFBD><EFBFBD>Ϣ<EFBFBD><CFA2><EFBFBD><EFBFBD>m_funcCheckFlowʧ<77>ܵ<EFBFBD>ʱ<EFBFBD><CAB1><EFBFBD><EFBFBD><EFBFBD>ý<EFBFBD><C3BD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϣչʾ<D5B9><CABE><EFBFBD><EFBFBD>
CSN = root["DATA"]["CSN"].asString();//CSN<53><4E>DATA<54>ڵ<EFBFBD><DAB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>MES<45>·<EFBFBD><C2B7><EFBFBD><EFBFBD>ֶΣ<D6B6><CEA3><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ֶ<EFBFBD><D6B6><EFBFBD><EFBFBD>ο<EFBFBD><CEBF><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>MESHelper<65>ӿڹ<D3BF><DAB9><EFBFBD>ʹ<EFBFBD><CAB9>˵<EFBFBD><CBB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ַ<EFBFBD>ʽ<EFBFBD><CABD>ȡ
}
sTmp.Format(_T("CheckFlow=0x%04x,Info=%s"),iRet, oErrInfo);
AfxMessageBox(sTmp);
}
void CHQSFC_TesterDlg::OnBnClickedButton2()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
if( 0!=LoadDll()) return ;
//UpdateFlow
CString sDSN;
m_EdtDSN.GetWindowText(sDSN);
CString sStation;
m_Station.GetWindowText(sStation);
CString sTools;//վλ
m_Tool.GetWindowText(sTools);
CString sError;//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> 0<><30>ʾ<EFBFBD><CABE><EFBFBD>߶<EFBFBD><DFB6><EFBFBD><EFBFBD>ɹ<EFBFBD><C9B9><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ҫ<EFBFBD><D2AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ִ<EFBFBD><D6B4><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>MESЭ<53>̻<EFBFBD>ȡ
m_Error.GetWindowText(sError);
CString sErrorDesc;//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
m_ErrorDesc.GetWindowText(sErrorDesc);
CString sTmp;
// LPCSTR StationJob, LPCSTR Tools ,char* sErrorInfo
int len = 102400;
int iRet = m_funcUpdateFlow(h_Mes,sDSN,sStation,sTools,sError,sErrorDesc.GetBuffer(len), &len);
sErrorDesc.ReleaseBuffer(len);
//iRet<65><74>ʾ<EFBFBD><CABE>վ<EFBFBD><D5BE>״̬<D7B4><CCAC>0<EFBFBD><30>ʾ<EFBFBD>ɹ<EFBFBD><C9B9><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʾʧ<CABE><CAA7>
//<2F><><EFBFBD><EFBFBD><EFBFBD>Ľ<EFBFBD><C4BD><EFBFBD>
string CSN = "";
Json::Reader reader;
Json::Value root;
if (reader.parse(sErrorDesc.GetBuffer(0), root))
{
string H_MSG = root["H_MSG"].asString();//<2F><>ʾMES<45><53><EFBFBD>صĴ<D8B5><C4B4><EFBFBD><EFBFBD><EFBFBD>Ϣ<EFBFBD><CFA2><EFBFBD><EFBFBD>m_funcUpdateFlowʧ<77>ܵ<EFBFBD>ʱ<EFBFBD><CAB1><EFBFBD><EFBFBD><EFBFBD>ý<EFBFBD><C3BD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϣչʾ<D5B9><CABE><EFBFBD><EFBFBD>
string G_NEXTWS = root["G_NEXTWS"].asString();//<2F><>ʾ<EFBFBD><CABE>һ<EFBFBD><D2BB><EFBFBD><EFBFBD>λ
}
//
sTmp.Format(_T("UpdateFlow=0x%04x,Info=%s"),iRet,sErrorDesc);
AfxMessageBox(sTmp);
}
CHQSFC_TesterDlg *pHQSFC;
int ShowLog2(char* msg)
{
if(pHQSFC!=NULL)
return pHQSFC->ShowLog(msg);
return 1;
}
void CHQSFC_TesterDlg::OnBnClickedButton3()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
if( 0!=LoadDll()) return ;
CString sTmp;
// LPCSTR StationJob, LPCSTR Tools ,char* sErrorInfo
pHQSFC = this;
CString oErrInfo;
int len = 102400;
int iRet = m_funcInit( ShowLog2 ,&h_Mes, oErrInfo.GetBuffer(len) , &len);
oErrInfo.ReleaseBuffer(len);
sTmp.Format(_T("Init=0x%04x,Info=%s"),iRet,oErrInfo);
AfxMessageBox(sTmp);
}
void CHQSFC_TesterDlg::OnBnClickedButton4()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
m_log.SetWindowText(_T(""));
}
int CHQSFC_TesterDlg::ShowLog(char* msg)
{
CString str ;
m_log.GetWindowText(str);
str.AppendFormat( _T("%s"), msg);
m_log.SetWindowText(str);
return 0;
}
void CHQSFC_TesterDlg::OnBnClickedButton5()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
int iRet = m_funcUnInit( h_Mes );
}
void CHQSFC_TesterDlg::OnBnClickedButton6()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
CString oErrInfo;
int len = 102400; // CString G_TYPE, CString G_POSITION, CString G_KEY, CString G_VALUE, CString G_EXTINFO
int iRet = m_funcSaveAndGetExtraInfo( h_Mes ,_T("1"),_T("TestNodeJs"),_T("CPP_G_KEY"),_T("CPP_G_VALUE"),_T("CPP_G_EXTINFO"),oErrInfo.GetBuffer(len), &len );
oErrInfo.ReleaseBuffer(len);
CString sTmp;
sTmp.Format(_T("SaveAndGetExtraInfo=0x%04x,Info=%s"),iRet,oErrInfo);
AfxMessageBox(sTmp);
}
void CHQSFC_TesterDlg::OnBnClickedButton7()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
CString oErrInfo;
int len = 102400; // CString G_TYPE, CString G_POSITION, CString G_KEY, CString G_VALUE, CString G_EXTINFO
int iRet = m_funcSaveAndGetExtraInfo( h_Mes ,_T("2"),_T("TestNodeJs"),_T("CPP_G_KEY"),_T(""),_T(""),oErrInfo.GetBuffer(len), &len );
oErrInfo.ReleaseBuffer(len);
CString sTmp;
sTmp.Format(_T("SaveAndGetExtraInfo=0x%04x,Info=%s"),iRet,oErrInfo);
AfxMessageBox(sTmp);
}
void CHQSFC_TesterDlg::OnBnClickedButton9()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
if( 0!=LoadDll()) return ;
CString sDSN;
m_EdtDSN.GetWindowText(sDSN);
CString sStation;
m_Station.GetWindowText(sStation);
CString sTools;
m_Tool.GetWindowText(sTools);
CString sError;
m_Error.GetWindowText(sError);
CString sTmp;
// LPCSTR StationJob, LPCSTR Tools ,char* sErrorInfo
CString oErrInfo;
int len = 102400;
CString SNType = _T("1");//<2F><>ʾ<EFBFBD><CABE>վ<EFBFBD><D5BE><EFBFBD><EFBFBD><EFBFBD>ݵ<EFBFBD><DDB5><EFBFBD><EFBFBD>ͣ<EFBFBD><CDA3><EFBFBD><EFBFBD>Ǹ<EFBFBD>m_funcCheckFlow<6F><77><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>1 SN 2 IMEI 3 CSN 4 <20><><EFBFBD><EFBFBD> 5 WiFi 6 <20><><EFBFBD><EFBFBD>֤
int iRet = m_funcCheckFlow2(h_Mes,sDSN, SNType ,sStation,sTools,oErrInfo.GetBuffer(len), &len );//ʹ<>úͽ<C3BA><CDBD><EFBFBD><EFBFBD>ķ<EFBFBD><C4B7><EFBFBD><EFBFBD><EFBFBD>m_funcCheckFlowһ<77><D2BB>
oErrInfo.ReleaseBuffer(len);
sTmp.Format(_T("CheckFlow=0x%04x,Info=%s"),iRet,oErrInfo);
AfxMessageBox(sTmp);
}
void CHQSFC_TesterDlg::OnBnClickedButton8()
{
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
// TODO: <20>ڴ<EFBFBD><DAB4><EFBFBD><EFBFBD>ӿؼ<D3BF>֪ͨ<CDA8><D6AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
if( 0!=LoadDll()) return ;
//UpdateFlow
CString sDSN;
m_EdtDSN.GetWindowText(sDSN);
CString sStation;
m_Station.GetWindowText(sStation);
CString sTools;
m_Tool.GetWindowText(sTools);
CString sError;
m_Error.GetWindowText(sError);
CString sErrorDesc;
m_ErrorDesc.GetWindowText(sErrorDesc);
CString sAllData;
m_AllData.GetWindowText(sAllData);
CString sTmp;
// LPCSTR StationJob, LPCSTR Tools ,char* sErrorInfo
int len = 102400;
//m_funcUpdateFlow2<77>IJ<EFBFBD><C4B2><EFBFBD><EFBFBD><EFBFBD>m_funcUpdateFlow<6F><77>һ<EFBFBD><D2BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݵ<EFBFBD><DDB5><EFBFBD><EFBFBD>ͺ<EFBFBD><CDBA>ϴ<EFBFBD><CFB4><EFBFBD><EFBFBD>ֶ<EFBFBD>
//<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ҫ<EFBFBD>ϴ<EFBFBD><CFB4>ֶ<EFBFBD>a ֵΪ1
//string data = "";
//Json::Value root;
//root["a"] = Json::Value("1");
//Json::FastWriter fw;
//data = fw.write(root);
//sAllData = data.GetBuffer(0);
//<2F><>data<74><61>SAlldata<74><61>ֵ<EFBFBD><D6B5><EFBFBD><EFBFBD><EFBFBD>ϴ<EFBFBD>
//m_funcUpdateFlow2<77><32><EFBFBD><EFBFBD><EFBFBD>ķ<EFBFBD><C4B7><EFBFBD>ֵ<EFBFBD>Ͳ<EFBFBD><CDB2><EFBFBD><EFBFBD>Ľ<EFBFBD><C4BD><EFBFBD><EFBFBD><EFBFBD>m_funcUpdateFlowһ<77><D2BB>
int iRet = m_funcUpdateFlow2(h_Mes,sDSN,"1",sStation,sTools,sError,sAllData,sErrorDesc.GetBuffer(len), &len);
sErrorDesc.ReleaseBuffer(len);
sTmp.Format("UpdateFlow=0x%04x,Info=%s",iRet,sErrorDesc);
AfxMessageBox(sTmp);
}

View File

@@ -0,0 +1,72 @@
// HQSFC_TesterDlg.h : ͷ<>ļ<EFBFBD>
//
#pragma once
#include "afxwin.h"
typedef int (__stdcall *FUNC_CHECKFLOW)(HANDLE hMes ,LPCSTR sDSN, LPCSTR StationJob, LPCSTR Tools ,char* sErrorInfo/*out*/, int*InfoLen /*in out*/ );
typedef int (__stdcall *FUNC_CHECKFLOW2)(HANDLE hMes ,LPCSTR sDSN,LPCSTR SNType, LPCSTR StationJob, LPCSTR Tools ,char* sErrorInfo/*out*/, int*InfoLen /*in out*/ );
typedef int (__stdcall *FUNC_UPDATEFLOW)(HANDLE hMes , LPCSTR sDSN,LPCSTR StationJob,LPCSTR Tools,LPCSTR ErrorCode, char* sErrorInfo /*out*/, int*InfoLen /*in out*/ );
typedef int (__stdcall *FUNC_UPDATEFLOW2)(HANDLE hMes , LPCSTR sDSN,LPCSTR SNType,LPCSTR StationJob,LPCSTR Tools,LPCSTR ErrorCode, LPCSTR AllData,char* sErrorInfo /*in out*/, int*InfoLen /*in out*/ );
typedef int (*FUNC_LOG)(char* msg);
typedef int (__stdcall *FUNC_INIT)(FUNC_LOG func,HANDLE *hMes , char* sErrorInfo/*out*/, int*InfoLen /*in out*/ );
typedef int (__stdcall *FUNC_UNINIT)(HANDLE hMes );
typedef int (__stdcall *FUNC_SAVEANDGETEXTRAINFO)(HANDLE hMes ,LPCSTR G_TYPE, LPCSTR G_POSITION, LPCSTR G_KEY, LPCSTR G_VALUE, LPCSTR G_EXTINFO, TCHAR* sErrorInfo/*out*/, int*InfoLen /*in out*/ );
// CHQSFC_TesterDlg <20>Ի<EFBFBD><D4BB><EFBFBD>
class CHQSFC_TesterDlg : public CDialog
{
// <20><><EFBFBD><EFBFBD>
public:
CHQSFC_TesterDlg(CWnd* pParent = NULL); // <20><>׼<EFBFBD><D7BC><EFBFBD><EFBFBD><ECBAAF>
// <20>Ի<EFBFBD><D4BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
enum { IDD = IDD_HQSFC_TESTER_DIALOG };
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV ֧<><D6A7>
// ʵ<><CAB5>
protected:
HICON m_hIcon;
// <20><><EFBFBD>ɵ<EFBFBD><C9B5><EFBFBD>Ϣӳ<CFA2><EFBFBD><E4BAAF>
virtual BOOL OnInitDialog();
afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
afx_msg void OnPaint();
afx_msg HCURSOR OnQueryDragIcon();
DECLARE_MESSAGE_MAP()
public:
afx_msg void OnBnClickedButton1();
afx_msg void OnBnClickedButton2();
HMODULE m_hHandle;
FUNC_CHECKFLOW m_funcCheckFlow;
FUNC_CHECKFLOW2 m_funcCheckFlow2;
FUNC_UPDATEFLOW m_funcUpdateFlow;
FUNC_UPDATEFLOW2 m_funcUpdateFlow2;
FUNC_INIT m_funcInit;
FUNC_UNINIT m_funcUnInit;
FUNC_SAVEANDGETEXTRAINFO m_funcSaveAndGetExtraInfo;
long LoadDll();
CEdit m_EdtDSN;
public:
afx_msg void OnBnClickedButton3();
public:
afx_msg void OnBnClickedButton4();
CEdit m_Station;
CEdit m_Tool;
CEdit m_Error;
CEdit m_log;
CEdit m_ErrorDesc;
CEdit m_AllData;
int ShowLog(char*);
afx_msg void OnBnClickedButton5();
HANDLE h_Mes; // MES <20><><EFBFBD><EFBFBD>
afx_msg void OnBnClickedButton6();
afx_msg void OnBnClickedButton7();
afx_msg void OnBnClickedButton9();
afx_msg void OnBnClickedButton8();
};

View File

@@ -0,0 +1,78 @@
// HQSFC_Tester.cpp : <20><><EFBFBD><EFBFBD>Ӧ<EFBFBD>ó<EFBFBD><C3B3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϊ<EFBFBD><CEAA>
//
#include "stdafx.h"
#include "HQSFC_Tester.h"
#include "HQSFC_TesterDlg.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#endif
// CHQSFC_TesterApp
BEGIN_MESSAGE_MAP(CHQSFC_TesterApp, CWinApp)
ON_COMMAND(ID_HELP, &CWinApp::OnHelp)
END_MESSAGE_MAP()
// CHQSFC_TesterApp <20><><EFBFBD><EFBFBD>
CHQSFC_TesterApp::CHQSFC_TesterApp()
{
// TODO: <20>ڴ˴<DAB4><CBB4><EFBFBD><EFBFBD>ӹ<EFBFBD><D3B9><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ҫ<EFBFBD>ij<EFBFBD>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> InitInstance <20><>
}
// Ψһ<CEA8><D2BB>һ<EFBFBD><D2BB> CHQSFC_TesterApp <20><><EFBFBD><EFBFBD>
CHQSFC_TesterApp theApp;
// CHQSFC_TesterApp <20><>ʼ<EFBFBD><CABC>
BOOL CHQSFC_TesterApp::InitInstance()
{
// <20><><EFBFBD><EFBFBD>һ<EFBFBD><D2BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> Windows XP <20>ϵ<EFBFBD>Ӧ<EFBFBD>ó<EFBFBD><C3B3><EFBFBD><EFBFBD>嵥ָ<E5B5A5><D6B8>Ҫ
// ʹ<><CAB9> ComCtl32.dll <20>汾 6 <20><><EFBFBD><EFBFBD><EFBFBD>߰汾<DFB0><E6B1BE><EFBFBD><EFBFBD><EFBFBD>ÿ<EFBFBD><C3BF>ӻ<EFBFBD><D3BB><EFBFBD>ʽ<EFBFBD><CABD>
//<2F><><EFBFBD><EFBFBD>Ҫ InitCommonControlsEx()<29><><EFBFBD><EFBFBD><EFBFBD>򣬽<EFBFBD><F2A3ACBD>޷<EFBFBD><DEB7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ڡ<EFBFBD>
INITCOMMONCONTROLSEX InitCtrls;
InitCtrls.dwSize = sizeof(InitCtrls);
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϊ<EFBFBD><CEAA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ҫ<EFBFBD><D2AA>Ӧ<EFBFBD>ó<EFBFBD><C3B3><EFBFBD><EFBFBD><EFBFBD>ʹ<EFBFBD>õ<EFBFBD>
// <20><><EFBFBD><EFBFBD><EFBFBD>ؼ<EFBFBD><D8BC>
InitCtrls.dwICC = ICC_WIN95_CLASSES;
InitCommonControlsEx(&InitCtrls);
CWinApp::InitInstance();
AfxEnableControlContainer();
// <20><>׼<EFBFBD><D7BC>ʼ<EFBFBD><CABC>
// <20><><EFBFBD><EFBFBD>δʹ<CEB4><CAB9><EFBFBD><EFBFBD>Щ<EFBFBD><D0A9><EFBFBD>ܲ<EFBFBD>ϣ<EFBFBD><CFA3><EFBFBD><EFBFBD>С
// <20><><EFBFBD>տ<EFBFBD>ִ<EFBFBD><D6B4><EFBFBD>ļ<EFBFBD><C4BC>Ĵ<EFBFBD>С<EFBFBD><D0A1><EFBFBD><EFBFBD>Ӧ<EFBFBD>Ƴ<EFBFBD><C6B3><EFBFBD><EFBFBD><EFBFBD>
// <20><><EFBFBD><EFBFBD>Ҫ<EFBFBD><D2AA><EFBFBD>ض<EFBFBD><D8B6><EFBFBD>ʼ<EFBFBD><CABC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ڴ洢<DAB4><E6B4A2><EFBFBD>õ<EFBFBD>ע<EFBFBD><D7A2><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
// TODO: Ӧ<>ʵ<EFBFBD><CAB5>޸ĸ<DEB8><C4B8>ַ<EFBFBD><D6B7><EFBFBD><EFBFBD><EFBFBD>
// <20><><EFBFBD><EFBFBD><EFBFBD>޸<EFBFBD>Ϊ<EFBFBD><CEAA>˾<EFBFBD><CBBE><EFBFBD><EFBFBD>֯<EFBFBD><D6AF>
SetRegistryKey(_T("Ӧ<EFBFBD>ó<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɵı<EFBFBD><EFBFBD><EFBFBD>Ӧ<EFBFBD>ó<EFBFBD><EFBFBD><EFBFBD>"));
CHQSFC_TesterDlg dlg;
m_pMainWnd = &dlg;
INT_PTR nResponse = dlg.DoModal();
if (nResponse == IDOK)
{
// TODO: <20>ڴ˴<DAB4><CBB4><EFBFBD><EFBFBD>ô<EFBFBD><C3B4><EFBFBD><EFBFBD><EFBFBD>ʱ<EFBFBD>á<EFBFBD>ȷ<EFBFBD><C8B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ر<EFBFBD>
// <20>Ի<EFBFBD><D4BB><EFBFBD><EFBFBD>Ĵ<EFBFBD><C4B4><EFBFBD>
}
else if (nResponse == IDCANCEL)
{
// TODO: <20>ڴ˷<DAB4><CBB7>ô<EFBFBD><C3B4><EFBFBD><EFBFBD><EFBFBD>ʱ<EFBFBD>á<EFBFBD>ȡ<EFBFBD><C8A1><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ر<EFBFBD>
// <20>Ի<EFBFBD><D4BB><EFBFBD><EFBFBD>Ĵ<EFBFBD><C4B4><EFBFBD>
}
// <20><><EFBFBD>ڶԻ<DAB6><D4BB><EFBFBD><EFBFBD>ѹرգ<D8B1><D5A3><EFBFBD><EFBFBD>Խ<EFBFBD><D4BD><EFBFBD><EFBFBD><EFBFBD> FALSE <20>Ա<EFBFBD><D4B1>˳<EFBFBD>Ӧ<EFBFBD>ó<EFBFBD><C3B3><EFBFBD><EFBFBD><EFBFBD>
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ӧ<EFBFBD>ó<EFBFBD><C3B3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϣ<EFBFBD>á<EFBFBD>
return FALSE;
}

View File

@@ -0,0 +1,31 @@
// HQSFC_Tester.h : PROJECT_NAME Ӧ<>ó<EFBFBD><C3B3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ͷ<EFBFBD>ļ<EFBFBD>
//
#pragma once
#ifndef __AFXWIN_H__
#error "<22>ڰ<EFBFBD><DAB0><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ļ<EFBFBD>֮ǰ<D6AE><C7B0><EFBFBD><EFBFBD><EFBFBD><EFBFBD>stdafx.h<><68><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> PCH <20>ļ<EFBFBD>"
#endif
#include "resource.h" // <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
// CHQSFC_TesterApp:
// <20>йش<D0B9><D8B4><EFBFBD><EFBFBD><EFBFBD>ʵ<EFBFBD>֣<EFBFBD><D6A3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> HQSFC_Tester.cpp
//
class CHQSFC_TesterApp : public CWinApp
{
public:
CHQSFC_TesterApp();
// <20><>д
public:
virtual BOOL InitInstance();
// ʵ<><CAB5>
DECLARE_MESSAGE_MAP()
};
extern CHQSFC_TesterApp theApp;

View File

@@ -0,0 +1,214 @@
// Microsoft Visual C++ generated resource script.
//
#include "resource.h"
#define APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 2 resource.
//
#include "afxres.h"
/////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS
/////////////////////////////////////////////////////////////////////////////
// <20><><EFBFBD><EFBFBD>(<28><><EFBFBD><EFBFBD>й<EFBFBD>) resources
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_CHS)
LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED
#pragma code_page(936)
#ifdef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// TEXTINCLUDE
//
1 TEXTINCLUDE
BEGIN
"resource.h\0"
END
2 TEXTINCLUDE
BEGIN
"#include ""afxres.h""\r\n"
"\0"
END
3 TEXTINCLUDE
BEGIN
"#define _AFX_NO_SPLITTER_RESOURCES\r\n"
"#define _AFX_NO_OLE_RESOURCES\r\n"
"#define _AFX_NO_TRACKER_RESOURCES\r\n"
"#define _AFX_NO_PROPERTY_RESOURCES\r\n"
"\r\n"
"#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_CHS)\r\n"
"LANGUAGE 4, 2\r\n"
"#pragma code_page(936)\r\n"
"#include ""res\\HQSFC_Tester.rc2"" // <20><> Microsoft Visual C++ <20><EFBFBD><E0BCAD><EFBFBD><EFBFBD>Դ\r\n"
"#include ""afxres.rc"" // <20><>׼<EFBFBD><D7BC><EFBFBD><EFBFBD>\r\n"
"#endif\r\n"
"\0"
END
#endif // APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Icon
//
// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
IDR_MAINFRAME ICON "res\\HQSFC_Tester.ico"
/////////////////////////////////////////////////////////////////////////////
//
// Dialog
//
IDD_ABOUTBOX DIALOGEX 0, 0, 235, 55
STYLE DS_SETFONT | DS_MODALFRAME | DS_FIXEDSYS | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "<22><><EFBFBD><EFBFBD> HQSFC_Tester"
FONT 9, "<22><><EFBFBD><EFBFBD>", 0, 0, 0x1
BEGIN
ICON IDR_MAINFRAME,IDC_STATIC,11,17,20,20
LTEXT "HQSFC_Tester 1.0 <20><>",IDC_STATIC,40,10,119,8,SS_NOPREFIX
LTEXT "Copyright (C) 2015",IDC_STATIC,40,25,119,8
DEFPUSHBUTTON "ȷ<><C8B7>",IDOK,178,7,50,16,WS_GROUP
END
IDD_HQSFC_TESTER_DIALOG DIALOGEX 0, 0, 414, 283
STYLE DS_SETFONT | DS_MODALFRAME | WS_POPUP | WS_VISIBLE | WS_CAPTION | WS_SYSMENU
EXSTYLE WS_EX_APPWINDOW
CAPTION "HQSFC_Tester"
FONT 9, "<22><><EFBFBD><EFBFBD>", 0, 0, 0x1
BEGIN
EDITTEXT IDC_EDIT1,57,15,134,14,ES_AUTOHSCROLL
EDITTEXT IDC_EDIT2,57,33,134,14,ES_AUTOHSCROLL
DEFPUSHBUTTON "MesInit",IDC_BUTTON3,25,237,71,39
PUSHBUTTON "MesStart",IDC_BUTTON1,28,145,71,23
PUSHBUTTON "MesEnd",IDC_BUTTON2,119,145,71,22
PUSHBUTTON "ClearLog",IDC_BUTTON4,121,123,67,19
EDITTEXT IDC_EDIT3,58,51,134,14,ES_AUTOHSCROLL
EDITTEXT IDC_EDIT4,57,68,134,14,ES_AUTOHSCROLL
LTEXT "SN",IDC_STATIC,11,17,9,8
LTEXT "STATION",IDC_STATIC,7,35,29,8
LTEXT "TOOL",IDC_STATIC,10,55,17,8
LTEXT "ErrorCode",IDC_STATIC,10,73,37,8
EDITTEXT IDC_EDIT5,203,7,204,269,ES_MULTILINE | ES_AUTOHSCROLL | ES_WANTRETURN | WS_VSCROLL | WS_HSCROLL
PUSHBUTTON "MesUnInit",IDC_BUTTON5,119,237,71,39
PUSHBUTTON "Mes-Save",IDC_BUTTON6,27,207,71,22
PUSHBUTTON "Mes-Get",IDC_BUTTON7,119,206,71,22
EDITTEXT IDC_EDIT6,57,85,134,14,ES_AUTOHSCROLL
LTEXT "ErrorDesc",IDC_STATIC,9,91,37,8
PUSHBUTTON "MesEnd2",IDC_BUTTON8,119,172,71,22
PUSHBUTTON "MesStart2",IDC_BUTTON9,28,172,71,23
EDITTEXT IDC_EDIT7,57,104,134,14,ES_AUTOHSCROLL
LTEXT "All Data",IDC_STATIC,9,110,33,8
END
/////////////////////////////////////////////////////////////////////////////
//
// Version
//
VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,0,0,1
PRODUCTVERSION 1,0,0,1
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
FILEFLAGS 0x1L
#else
FILEFLAGS 0x0L
#endif
FILEOS 0x4L
FILETYPE 0x1L
FILESUBTYPE 0x0L
BEGIN
BLOCK "StringFileInfo"
BEGIN
BLOCK "080403a8"
BEGIN
VALUE "CompanyName", "TODO: <<3C><>˾<EFBFBD><CBBE>>"
VALUE "FileDescription", "TODO: <<3C>ļ<EFBFBD>˵<EFBFBD><CBB5>>"
VALUE "FileVersion", "1.0.0.1"
VALUE "InternalName", "HQSFC_Tester.exe"
VALUE "LegalCopyright", "TODO: (C) <<3C><>˾<EFBFBD><CBBE>><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȩ<EFBFBD><C8A8><EFBFBD><EFBFBD>"
VALUE "OriginalFilename", "HQSFC_Tester.exe"
VALUE "ProductName", "TODO: <<3C><>Ʒ<EFBFBD><C6B7>>"
VALUE "ProductVersion", "1.0.0.1"
END
END
BLOCK "VarFileInfo"
BEGIN
VALUE "Translation", 0x804, 936
END
END
/////////////////////////////////////////////////////////////////////////////
//
// DESIGNINFO
//
#ifdef APSTUDIO_INVOKED
GUIDELINES DESIGNINFO
BEGIN
IDD_ABOUTBOX, DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 228
TOPMARGIN, 7
BOTTOMMARGIN, 48
END
IDD_HQSFC_TESTER_DIALOG, DIALOG
BEGIN
LEFTMARGIN, 7
RIGHTMARGIN, 407
TOPMARGIN, 7
BOTTOMMARGIN, 276
END
END
#endif // APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// String Table
//
STRINGTABLE
BEGIN
IDS_ABOUTBOX "<22><><EFBFBD><EFBFBD> HQSFC_Tester(&A)..."
END
#endif // <20><><EFBFBD><EFBFBD>(<28><><EFBFBD><EFBFBD>й<EFBFBD>) resources
/////////////////////////////////////////////////////////////////////////////
#ifndef APSTUDIO_INVOKED
/////////////////////////////////////////////////////////////////////////////
//
// Generated from the TEXTINCLUDE 3 resource.
//
#define _AFX_NO_SPLITTER_RESOURCES
#define _AFX_NO_OLE_RESOURCES
#define _AFX_NO_TRACKER_RESOURCES
#define _AFX_NO_PROPERTY_RESOURCES
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_CHS)
LANGUAGE 4, 2
#pragma code_page(936)
#include "res\HQSFC_Tester.rc2" // <20><> Microsoft Visual C++ <20><EFBFBD><E0BCAD><EFBFBD><EFBFBD>Դ
#include "afxres.rc" // <20><>׼<EFBFBD><D7BC><EFBFBD><EFBFBD>
#endif
/////////////////////////////////////////////////////////////////////////////
#endif // not APSTUDIO_INVOKED

View File

@@ -0,0 +1,23 @@

Microsoft Visual Studio Solution File, Format Version 11.00
# Visual Studio 2010
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "HQSFC_Tester", "HQSFC_Tester.vcxproj", "{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Win32 = Debug|Win32
Release|Win32 = Release|Win32
Template|Win32 = Template|Win32
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}.Debug|Win32.ActiveCfg = Debug|Win32
{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}.Debug|Win32.Build.0 = Debug|Win32
{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}.Release|Win32.ActiveCfg = Release|Win32
{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}.Release|Win32.Build.0 = Release|Win32
{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}.Template|Win32.ActiveCfg = Template|Win32
{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}.Template|Win32.Build.0 = Template|Win32
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
EndGlobal

View File

@@ -0,0 +1,272 @@
<?xml version="1.0" encoding="gb2312"?>
<VisualStudioProject
ProjectType="Visual C++"
Version="8.00"
Name="HQSFC_Tester"
ProjectGUID="{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}"
RootNamespace="HQSFC_Tester"
Keyword="MFCProj"
>
<Platforms>
<Platform
Name="Win32"
/>
</Platforms>
<ToolFiles>
</ToolFiles>
<Configurations>
<Configuration
Name="Debug|Win32"
OutputDirectory="$(SolutionDir)$(ConfigurationName)"
IntermediateDirectory="$(ConfigurationName)"
ConfigurationType="1"
UseOfMFC="1"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
PreprocessorDefinitions="_DEBUG"
MkTypLibCompatible="false"
ValidateParameters="false"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
PreprocessorDefinitions="WIN32;_WINDOWS;_DEBUG"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="1"
UsePrecompiledHeader="2"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="4"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
PreprocessorDefinitions="_DEBUG"
Culture="2052"
AdditionalIncludeDirectories="$(IntDir)"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
LinkIncremental="2"
GenerateDebugInformation="true"
SubSystem="2"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
<Configuration
Name="Release|Win32"
OutputDirectory="$(SolutionDir)$(ConfigurationName)"
IntermediateDirectory="$(ConfigurationName)"
ConfigurationType="1"
UseOfMFC="1"
CharacterSet="2"
WholeProgramOptimization="1"
>
<Tool
Name="VCPreBuildEventTool"
/>
<Tool
Name="VCCustomBuildTool"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
PreprocessorDefinitions="NDEBUG"
MkTypLibCompatible="false"
ValidateParameters="false"
/>
<Tool
Name="VCCLCompilerTool"
PreprocessorDefinitions="WIN32;_WINDOWS;NDEBUG"
MinimalRebuild="false"
RuntimeLibrary="0"
UsePrecompiledHeader="2"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
PreprocessorDefinitions="NDEBUG"
Culture="2052"
AdditionalIncludeDirectories="$(IntDir)"
/>
<Tool
Name="VCPreLinkEventTool"
/>
<Tool
Name="VCLinkerTool"
LinkIncremental="1"
GenerateDebugInformation="true"
SubSystem="2"
OptimizeReferences="2"
EnableCOMDATFolding="2"
TargetMachine="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
/>
<Tool
Name="VCXDCMakeTool"
/>
<Tool
Name="VCBscMakeTool"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
/>
</Configuration>
</Configurations>
<References>
</References>
<Files>
<Filter
Name="Դ<>ļ<EFBFBD>"
Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
>
<File
RelativePath=".\HQSFC_Tester.cpp"
>
</File>
<File
RelativePath=".\HQSFC_TesterDlg.cpp"
>
</File>
<File
RelativePath=".\stdafx.cpp"
>
<FileConfiguration
Name="Debug|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="1"
/>
</FileConfiguration>
<FileConfiguration
Name="Release|Win32"
>
<Tool
Name="VCCLCompilerTool"
UsePrecompiledHeader="1"
/>
</FileConfiguration>
</File>
</Filter>
<Filter
Name="ͷ<>ļ<EFBFBD>"
Filter="h;hpp;hxx;hm;inl;inc;xsd"
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
>
<File
RelativePath=".\HQSFC_Tester.h"
>
</File>
<File
RelativePath=".\HQSFC_TesterDlg.h"
>
</File>
<File
RelativePath=".\Resource.h"
>
</File>
<File
RelativePath=".\stdafx.h"
>
</File>
</Filter>
<Filter
Name="<22><>Դ<EFBFBD>ļ<EFBFBD>"
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav"
UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
>
<File
RelativePath=".\res\HQSFC_Tester.ico"
>
</File>
<File
RelativePath=".\HQSFC_Tester.rc"
>
</File>
<File
RelativePath=".\res\HQSFC_Tester.rc2"
>
</File>
</Filter>
<File
RelativePath=".\ReadMe.txt"
>
</File>
</Files>
<Globals>
<Global
Name="RESOURCE_FILE"
Value="HQSFC_Tester.rc"
/>
</Globals>
</VisualStudioProject>

View File

@@ -0,0 +1,149 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Template|Win32">
<Configuration>Template</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup Label="Globals">
<ProjectGuid>{22E0435F-F6A0-4C8E-8361-CB48B6273A2F}</ProjectGuid>
<RootNamespace>HQSFC_Tester</RootNamespace>
<Keyword>MFCProj</Keyword>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseOfMfc>Static</UseOfMfc>
<CharacterSet>MultiByte</CharacterSet>
<WholeProgramOptimization>true</WholeProgramOptimization>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseOfMfc>Static</UseOfMfc>
<CharacterSet>MultiByte</CharacterSet>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup>
<_ProjectFileVersion>10.0.40219.1</_ProjectFileVersion>
<OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(SolutionDir)$(Configuration)\</OutDir>
<IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(Configuration)\</IntDir>
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</LinkIncremental>
<OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(SolutionDir)$(Configuration)\</OutDir>
<IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(Configuration)\</IntDir>
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">false</LinkIncremental>
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">AllRules.ruleset</CodeAnalysisRuleSet>
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" />
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" />
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">AllRules.ruleset</CodeAnalysisRuleSet>
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" />
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" />
<CodeAnalysisRuleSet Condition="'$(Configuration)|$(Platform)'=='Template|Win32'">AllRules.ruleset</CodeAnalysisRuleSet>
<CodeAnalysisRules Condition="'$(Configuration)|$(Platform)'=='Template|Win32'" />
<CodeAnalysisRuleAssemblies Condition="'$(Configuration)|$(Platform)'=='Template|Win32'" />
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Midl>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MkTypLibCompatible>false</MkTypLibCompatible>
<ValidateAllParameters>false</ValidateAllParameters>
</Midl>
<ClCompile>
<Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;_WINDOWS;_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MinimalRebuild>true</MinimalRebuild>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
<PrecompiledHeader>Use</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
<AdditionalIncludeDirectories>$(SolutionDir)\json;</AdditionalIncludeDirectories>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<Culture>0x0804</Culture>
<AdditionalIncludeDirectories>$(IntDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ResourceCompile>
<Link>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
<TargetMachine>MachineX86</TargetMachine>
<AdditionalLibraryDirectories>$(SolutionDir)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<AdditionalDependencies>json_vc71_libmt.lib</AdditionalDependencies>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Midl>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MkTypLibCompatible>false</MkTypLibCompatible>
<ValidateAllParameters>false</ValidateAllParameters>
</Midl>
<ClCompile>
<PreprocessorDefinitions>WIN32;_WINDOWS;NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MinimalRebuild>false</MinimalRebuild>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<PrecompiledHeader>Use</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
</ClCompile>
<ResourceCompile>
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<Culture>0x0804</Culture>
<AdditionalIncludeDirectories>$(IntDir);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ResourceCompile>
<Link>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
<OptimizeReferences>true</OptimizeReferences>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<TargetMachine>MachineX86</TargetMachine>
</Link>
</ItemDefinitionGroup>
<ItemGroup>
<ClCompile Include="HQSFC_Tester.cpp" />
<ClCompile Include="HQSFC_TesterDlg.cpp" />
<ClCompile Include="stdafx.cpp">
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
<PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="HQSFC_Tester.h" />
<ClInclude Include="HQSFC_TesterDlg.h" />
<ClInclude Include="Resource.h" />
<ClInclude Include="stdafx.h" />
</ItemGroup>
<ItemGroup>
<None Include="res\HQSFC_Tester.ico" />
<None Include="res\HQSFC_Tester.rc2" />
<None Include="ReadMe.txt" />
</ItemGroup>
<ItemGroup>
<ResourceCompile Include="HQSFC_Tester.rc" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
<ProjectExtensions>
<VisualStudio>
<UserProperties RESOURCE_FILE="HQSFC_Tester.rc" />
</VisualStudio>
</ProjectExtensions>
</Project>

View File

@@ -0,0 +1,19 @@
#ifndef JSON_AUTOLINK_H_INCLUDED
# define JSON_AUTOLINK_H_INCLUDED
# include "config.h"
# ifdef JSON_IN_CPPTL
# include <cpptl/cpptl_autolink.h>
# endif
# if !defined(JSON_NO_AUTOLINK) && !defined(JSON_DLL_BUILD) && !defined(JSON_IN_CPPTL)
# define CPPTL_AUTOLINK_NAME "json"
# undef CPPTL_AUTOLINK_DLL
# ifdef JSON_DLL
# define CPPTL_AUTOLINK_DLL
# endif
# include "autolink.h"
# endif
#endif // JSON_AUTOLINK_H_INCLUDED

View File

@@ -0,0 +1,19 @@
#ifndef JSON_AUTOLINK_H_INCLUDED
# define JSON_AUTOLINK_H_INCLUDED
# include "config.h"
# ifdef JSON_IN_CPPTL
# include <cpptl/cpptl_autolink.h>
# endif
# if !defined(JSON_NO_AUTOLINK) && !defined(JSON_DLL_BUILD) && !defined(JSON_IN_CPPTL)
# define CPPTL_AUTOLINK_NAME "json"
# undef CPPTL_AUTOLINK_DLL
# ifdef JSON_DLL
# define CPPTL_AUTOLINK_DLL
# endif
# include "autolink.h"
# endif
#endif // JSON_AUTOLINK_H_INCLUDED

View File

@@ -0,0 +1,43 @@
#ifndef JSON_CONFIG_H_INCLUDED
# define JSON_CONFIG_H_INCLUDED
/// If defined, indicates that json library is embedded in CppTL library.
//# define JSON_IN_CPPTL 1
/// If defined, indicates that json may leverage CppTL library
//# define JSON_USE_CPPTL 1
/// If defined, indicates that cpptl vector based map should be used instead of std::map
/// as Value container.
//# define JSON_USE_CPPTL_SMALLMAP 1
/// If defined, indicates that Json specific container should be used
/// (hash table & simple deque container with customizable allocator).
/// THIS FEATURE IS STILL EXPERIMENTAL!
//# define JSON_VALUE_USE_INTERNAL_MAP 1
/// Force usage of standard new/malloc based allocator instead of memory pool based allocator.
/// The memory pools allocator used optimization (initializing Value and ValueInternalLink
/// as if it was a POD) that may cause some validation tool to report errors.
/// Only has effects if JSON_VALUE_USE_INTERNAL_MAP is defined.
//# define JSON_USE_SIMPLE_INTERNAL_ALLOCATOR 1
/// If defined, indicates that Json use exception to report invalid type manipulation
/// instead of C assert macro.
# define JSON_USE_EXCEPTION 1
# ifdef JSON_IN_CPPTL
# include <cpptl/config.h>
# ifndef JSON_USE_CPPTL
# define JSON_USE_CPPTL 1
# endif
# endif
# ifdef JSON_IN_CPPTL
# define JSON_API CPPTL_API
# elif defined(JSON_DLL_BUILD)
# define JSON_API __declspec(dllexport)
# elif defined(JSON_DLL)
# define JSON_API __declspec(dllimport)
# else
# define JSON_API
# endif
#endif // JSON_CONFIG_H_INCLUDED

View File

@@ -0,0 +1,43 @@
#ifndef JSON_CONFIG_H_INCLUDED
# define JSON_CONFIG_H_INCLUDED
/// If defined, indicates that json library is embedded in CppTL library.
//# define JSON_IN_CPPTL 1
/// If defined, indicates that json may leverage CppTL library
//# define JSON_USE_CPPTL 1
/// If defined, indicates that cpptl vector based map should be used instead of std::map
/// as Value container.
//# define JSON_USE_CPPTL_SMALLMAP 1
/// If defined, indicates that Json specific container should be used
/// (hash table & simple deque container with customizable allocator).
/// THIS FEATURE IS STILL EXPERIMENTAL!
//# define JSON_VALUE_USE_INTERNAL_MAP 1
/// Force usage of standard new/malloc based allocator instead of memory pool based allocator.
/// The memory pools allocator used optimization (initializing Value and ValueInternalLink
/// as if it was a POD) that may cause some validation tool to report errors.
/// Only has effects if JSON_VALUE_USE_INTERNAL_MAP is defined.
//# define JSON_USE_SIMPLE_INTERNAL_ALLOCATOR 1
/// If defined, indicates that Json use exception to report invalid type manipulation
/// instead of C assert macro.
# define JSON_USE_EXCEPTION 1
# ifdef JSON_IN_CPPTL
# include <cpptl/config.h>
# ifndef JSON_USE_CPPTL
# define JSON_USE_CPPTL 1
# endif
# endif
# ifdef JSON_IN_CPPTL
# define JSON_API CPPTL_API
# elif defined(JSON_DLL_BUILD)
# define JSON_API __declspec(dllexport)
# elif defined(JSON_DLL)
# define JSON_API __declspec(dllimport)
# else
# define JSON_API
# endif
#endif // JSON_CONFIG_H_INCLUDED

View File

@@ -0,0 +1,42 @@
#ifndef CPPTL_JSON_FEATURES_H_INCLUDED
# define CPPTL_JSON_FEATURES_H_INCLUDED
# include "forwards.h"
namespace Json {
/** \brief Configuration passed to reader and writer.
* This configuration object can be used to force the Reader or Writer
* to behave in a standard conforming way.
*/
class JSON_API Features
{
public:
/** \brief A configuration that allows all features and assumes all strings are UTF-8.
* - C & C++ comments are allowed
* - Root object can be any JSON value
* - Assumes Value strings are encoded in UTF-8
*/
static Features all();
/** \brief A configuration that is strictly compatible with the JSON specification.
* - Comments are forbidden.
* - Root object must be either an array or an object value.
* - Assumes Value strings are encoded in UTF-8
*/
static Features strictMode();
/** \brief Initialize the configuration like JsonConfig::allFeatures;
*/
Features();
/// \c true if comments are allowed. Default: \c true.
bool allowComments_;
/// \c true if root must be either an array or an object value. Default: \c false.
bool strictRoot_;
};
} // namespace Json
#endif // CPPTL_JSON_FEATURES_H_INCLUDED

View File

@@ -0,0 +1,42 @@
#ifndef CPPTL_JSON_FEATURES_H_INCLUDED
# define CPPTL_JSON_FEATURES_H_INCLUDED
# include "forwards.h"
namespace Json {
/** \brief Configuration passed to reader and writer.
* This configuration object can be used to force the Reader or Writer
* to behave in a standard conforming way.
*/
class JSON_API Features
{
public:
/** \brief A configuration that allows all features and assumes all strings are UTF-8.
* - C & C++ comments are allowed
* - Root object can be any JSON value
* - Assumes Value strings are encoded in UTF-8
*/
static Features all();
/** \brief A configuration that is strictly compatible with the JSON specification.
* - Comments are forbidden.
* - Root object must be either an array or an object value.
* - Assumes Value strings are encoded in UTF-8
*/
static Features strictMode();
/** \brief Initialize the configuration like JsonConfig::allFeatures;
*/
Features();
/// \c true if comments are allowed. Default: \c true.
bool allowComments_;
/// \c true if root must be either an array or an object value. Default: \c false.
bool strictRoot_;
};
} // namespace Json
#endif // CPPTL_JSON_FEATURES_H_INCLUDED

View File

@@ -0,0 +1,39 @@
#ifndef JSON_FORWARDS_H_INCLUDED
# define JSON_FORWARDS_H_INCLUDED
# include "config.h"
namespace Json {
// writer.h
class FastWriter;
class StyledWriter;
// reader.h
class Reader;
// features.h
class Features;
// value.h
typedef int Int;
typedef unsigned int UInt;
class StaticString;
class Path;
class PathArgument;
class Value;
class ValueIteratorBase;
class ValueIterator;
class ValueConstIterator;
#ifdef JSON_VALUE_USE_INTERNAL_MAP
class ValueAllocator;
class ValueMapAllocator;
class ValueInternalLink;
class ValueInternalArray;
class ValueInternalMap;
#endif // #ifdef JSON_VALUE_USE_INTERNAL_MAP
} // namespace Json
#endif // JSON_FORWARDS_H_INCLUDED

Some files were not shown because too many files have changed in this diff Show More