Commit 14b26d85 authored by surukun's avatar surukun

konkedemo

parents
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" />
</startup>
</configuration>
\ No newline at end of file
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace KonkeDemo
{
public class AutoTestService
{
private ConcurrentDictionary<int, UserControlmodular> ModularDictionary = new ConcurrentDictionary<int, UserControlmodular>();//双向链表
public AutoTestService() { }
public AutoTestService(ConcurrentDictionary<int, UserControlmodular> keyValues)
{
this.ModularDictionary = keyValues;
ThreadRun = new Thread[keyValues.Count];
}
private bool[] UpdateError;
private Thread[] ThreadRun;
protected bool isAllTestThreadsFinished()
{
for (int i = 0; i < ThreadRun.Length; i++)
{
if (ThreadRun[i] != null
&& (ThreadRun[i].ThreadState != System.Threading.ThreadState.Aborted
&& ThreadRun[i].ThreadState != System.Threading.ThreadState.Stopped
&& ThreadRun[i].ThreadState != System.Threading.ThreadState.Unstarted))
{
}
else
{
if (!UpdateError[i])
{
ModularDictionary[i + 1].fnUpdate();
UpdateError[i] = true;
}
}
}
foreach (Thread thread in ThreadRun)
if (thread != null
&& (thread.ThreadState != System.Threading.ThreadState.Aborted
&& thread.ThreadState != System.Threading.ThreadState.Stopped
&& thread.ThreadState != System.Threading.ThreadState.Unstarted))
return false;
return true;
}
public void Run(DeviceInfo deviceinfo)
{
try
{
UpdateError = new bool[ModularDictionary.Count];
for (int i = 0; i < ModularDictionary.Count; i++)
{
ModularDictionary[i + 1].Init();
object obj = new object();
ThreadRun[i] = new Thread(new ParameterizedThreadStart(ModularDictionary[i + 1].Run));
ThreadRun[i].Start(obj);
}
while (!isAllTestThreadsFinished())
{
System.Threading.Thread.Sleep(100);
Application.DoEvents();
}
for (int i = 0; i < ModularDictionary.Count; i++)
{
if (!UpdateError[i])
ModularDictionary[i + 1].fnUpdate();
ModularDictionary[i + 1].Finished();
}
}
catch (Exception exc) { }
}
public void Stop()
{
UIDemoProcess autoTest = new UIDemoProcess();
autoTest.Stop();
}
public BaseConfig GetConfig()
{
UIDemoProcess autoTest = new UIDemoProcess();
return autoTest.GetConfig();
}
public void SetConfig(BaseConfig baseconfig)
{
UIDemoProcess autoTest = new UIDemoProcess();
autoTest.SetConfig(baseconfig);
}
}
}
namespace KonkeDemo
{
partial class UCNavigationMenuExt
{
/// <summary>
/// 必需的设计器变量。
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// 清理所有正在使用的资源。
/// </summary>
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region 组件设计器生成的代码
/// <summary>
/// 设计器支持所需的方法 - 不要修改
/// 使用代码编辑器修改此方法的内容。
/// </summary>
private void InitializeComponent()
{
this.SuspendLayout();
//
// UCNavigationMenuExt
//
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.Name = "UCNavigationMenuExt";
this.Leave += new System.EventHandler(this.UCNavigationMenuExt_Leave);
this.ResumeLayout(false);
}
#endregion
}
}
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using HZH_Controls.Controls;
using HZH_Controls.Forms;
using HZH_Controls;
namespace KonkeDemo
{
/// <summary>
/// Class UCNavigationMenuExt.
/// Implements the <see cref="System.Windows.Forms.UserControl" />
/// </summary>
/// <seealso cref="System.Windows.Forms.UserControl" />
[DefaultEvent("ClickItemed")]
public partial class UCNavigationMenuExt : UserControl
{
/// <summary>
/// Occurs when [click itemed].
/// </summary>
[Description("点击节点事件"), Category("自定义")]
public event EventHandler ClickItemed;
/// <summary>
/// The select item
/// </summary>
private NavigationMenuItemExt selectItem = null;
/// <summary>
/// Gets the select item.
/// </summary>
/// <value>The select item.</value>
[Description("选中的节点"), Category("自定义")]
public NavigationMenuItemExt SelectItem
{
get { return selectItem; }
private set { selectItem = value; }
}
/// <summary>
/// The items
/// </summary>
NavigationMenuItemExt[] items;
/// <summary>
/// Gets or sets the items.
/// </summary>
/// <value>The items.</value>
[Description("节点列表"), Category("自定义")]
public NavigationMenuItemExt[] Items
{
get { return items; }
set
{
items = value;
ReloadMenu();
}
}
/// <summary>
/// The tip color
/// </summary>
private Color tipColor = Color.FromArgb(255, 87, 34);
/// <summary>
/// Gets or sets the color of the tip.
/// </summary>
/// <value>The color of the tip.</value>
[Description("角标颜色"), Category("自定义")]
public Color TipColor
{
get { return tipColor; }
set { tipColor = value; }
}
/// <summary>
/// 获取或设置控件的前景色。
/// </summary>
/// <value>The color of the fore.</value>
/// <PermissionSet>
/// <IPermission class="System.Security.Permissions.FileIOPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true" />
/// </PermissionSet>
public override System.Drawing.Color ForeColor
{
get
{
return base.ForeColor;
}
set
{
base.ForeColor = value;
foreach (Control c in this.Controls)
{
c.ForeColor = value;
}
}
}
/// <summary>
/// 获取或设置控件显示的文字的字体。
/// </summary>
/// <value>The font.</value>
/// <PermissionSet>
/// <IPermission class="System.Security.Permissions.EnvironmentPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true" />
/// <IPermission class="System.Security.Permissions.FileIOPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true" />
/// <IPermission class="System.Security.Permissions.SecurityPermission, mscorlib, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Flags="UnmanagedCode, ControlEvidence" />
/// <IPermission class="System.Diagnostics.PerformanceCounterPermission, System, Version=2.0.3600.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" version="1" Unrestricted="true" />
/// </PermissionSet>
public override Font Font
{
get
{
return base.Font;
}
set
{
base.Font = value;
foreach (Control c in this.Controls)
{
c.Font = value;
}
}
}
private string[] MenuItem = new string[] { "基本信息", "错误" };
/// <summary>
/// The m LST anchors
/// </summary>
Dictionary<NavigationMenuItemExt, FrmAnchor> m_lstAnchors = new Dictionary<NavigationMenuItemExt, FrmAnchor>();
/// <summary>
/// Initializes a new instance of the <see cref="UCNavigationMenuExt111"/> class.
/// </summary>
public UCNavigationMenuExt()
{
InitializeComponent();
items = new NavigationMenuItemExt[0];
if (ControlHelper.IsDesignMode())
{
items = new NavigationMenuItemExt[2];
for (int i = 0; i < 2; i++)
{
items[i] = new NavigationMenuItemExt()
{
Text = MenuItem[i],
AnchorRight = i >= 2
};
}
}
}
/// <summary>
/// Reloads the menu.
/// </summary>
private void ReloadMenu()
{
try
{
ControlHelper.FreezeControl(this, true);
this.Controls.Clear();
if (items != null && items.Length > 0)
{
foreach (var item in items)
{
var menu = (NavigationMenuItemExt)item;
Label lbl = new Label();
lbl.AutoSize = false;
lbl.TextAlign = ContentAlignment.MiddleCenter;
lbl.Width = menu.ItemWidth;
lbl.Text = menu.Text;
lbl.Font = Font;
lbl.ForeColor = ForeColor;
lbl.Paint += lbl_Paint;
lbl.MouseEnter += lbl_MouseEnter;
lbl.Tag = menu;
lbl.Click += lbl_Click;
if (menu.AnchorRight)
{
lbl.Dock = DockStyle.Right;
}
else
{
lbl.Dock = DockStyle.Left;
}
this.Controls.Add(lbl);
lbl.BringToFront();
}
}
}
finally
{
ControlHelper.FreezeControl(this, false);
}
}
/// <summary>
/// Handles the Click event of the lbl control.
/// </summary>
/// <param name="sender">The source of the event.</param>
/// <param name="e">The <see cref="EventArgs"/> instance containing the event data.</param>
void lbl_Click(object sender, EventArgs e)
{
Label lbl = sender as Label;
if (lbl.Tag != null)
{
var menu = (NavigationMenuItemExt)lbl.Tag;
if (menu.ShowControl == null)
{
selectItem = menu;
while (m_lstAnchors.Count > 0)
{
try
{
foreach (var item in m_lstAnchors)
{
item.Value.Hide();
}
}
catch { }
}
if (ClickItemed != null)
{
ClickItemed(this, e);
}
}
}
}
/// <summary>
/// Handles the MouseEnter event of the lbl control.
/// </summary>
/// <param name="sender">The source of the event.</param>
/// <param name="e">The <see cref="EventArgs" /> instance containing the event data.</param>
void lbl_MouseEnter(object sender, EventArgs e)
{
Label lbl = sender as Label;
var menu = lbl.Tag as NavigationMenuItemExt;
foreach (var item in m_lstAnchors)
{
m_lstAnchors[item.Key].Hide();
}
if (menu.ShowControl != null)
{
if (!m_lstAnchors.ContainsKey(menu))
{
m_lstAnchors[menu] = new FrmAnchor(lbl, menu.ShowControl);
//m_lstAnchors[menu].CreateControl();
////m_lstAnchors[menu].OnCreateControl();
//m_lstAnchors[menu].Update();
//m_lstAnchors[menu].Refresh();
}
if (m_lstAnchors[menu].IsHandleCreated)
{
m_lstAnchors[menu].Invoke(new EventHandler(delegate
{
m_lstAnchors[menu].Show();
m_lstAnchors[menu].Size = menu.ShowControl.Size;
}));
}
else
{
m_lstAnchors[menu].Show();
m_lstAnchors[menu].Size = menu.ShowControl.Size;
}
}
}
/// <summary>
/// Handles the Paint event of the lbl control.
/// </summary>
/// <param name="sender">The source of the event.</param>
/// <param name="e">The <see cref="PaintEventArgs" /> instance containing the event data.</param>
void lbl_Paint(object sender, PaintEventArgs e)
{
try
{
Label lbl = sender as Label;
if (lbl.Tag != null)
{
var menu = (NavigationMenuItemExt)lbl.Tag;
e.Graphics.SetGDIHigh();
if (menu.ShowTip)
{
if (!string.IsNullOrEmpty(menu.TipText))
{
var rect = new Rectangle(lbl.Width - 25, lbl.Height / 2 - 10, 20, 20);
var path = rect.CreateRoundedRectanglePath(5);
e.Graphics.FillPath(new SolidBrush(tipColor), path);
e.Graphics.DrawString(menu.TipText, new Font("微软雅黑", 8f), new SolidBrush(Color.White), rect, new StringFormat() { Alignment = StringAlignment.Center, LineAlignment = StringAlignment.Center });
}
else
{
e.Graphics.FillEllipse(new SolidBrush(tipColor), new Rectangle(lbl.Width - 20, lbl.Height / 2 - 10, 10, 10));
}
}
if (menu.Icon != null)
{
e.Graphics.DrawImage(menu.Icon, new Rectangle(1, (lbl.Height - 25) / 2, 25, 25), 0, 0, menu.Icon.Width, menu.Icon.Height, GraphicsUnit.Pixel);
}
}
}
catch { }
}
private void UCNavigationMenuExt_Leave(object sender, EventArgs e)
{
foreach (var item in m_lstAnchors)
{
m_lstAnchors[item.Key].Hide();
}
}
}
}
namespace KonkeDemo
{
partial class UCPanelTitle
{
/// <summary>
/// 必需的设计器变量。
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// 清理所有正在使用的资源。
/// </summary>
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region 组件设计器生成的代码
/// <summary>
/// 设计器支持所需的方法 - 不要
/// 使用代码编辑器修改此方法的内容。
/// </summary>
private void InitializeComponent()
{
this.lblTitle = new System.Windows.Forms.Label();
this.richTextBox1 = new System.Windows.Forms.RichTextBox();
this.button1 = new System.Windows.Forms.Button();
this.SuspendLayout();
//
// lblTitle
//
this.lblTitle.BackColor = System.Drawing.Color.IndianRed;
this.lblTitle.Dock = System.Windows.Forms.DockStyle.Top;
this.lblTitle.ForeColor = System.Drawing.Color.Black;
this.lblTitle.Location = new System.Drawing.Point(0, 0);
this.lblTitle.Name = "lblTitle";
this.lblTitle.Size = new System.Drawing.Size(432, 34);
this.lblTitle.TabIndex = 0;
this.lblTitle.Text = "错误信息";
this.lblTitle.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// richTextBox1
//
this.richTextBox1.ForeColor = System.Drawing.Color.Red;
this.richTextBox1.Location = new System.Drawing.Point(0, 34);
this.richTextBox1.Name = "richTextBox1";
this.richTextBox1.ReadOnly = true;
this.richTextBox1.Size = new System.Drawing.Size(432, 220);
this.richTextBox1.TabIndex = 1;
this.richTextBox1.Text = "";
//
// button1
//
this.button1.Location = new System.Drawing.Point(169, 260);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(75, 26);
this.button1.TabIndex = 2;
this.button1.Text = "复制";
this.button1.UseVisualStyleBackColor = true;
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// UCPanelTitle
//
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.BackColor = System.Drawing.Color.Transparent;
this.ConerRadius = 10;
this.Controls.Add(this.button1);
this.Controls.Add(this.richTextBox1);
this.Controls.Add(this.lblTitle);
this.FillColor = System.Drawing.Color.White;
this.IsRadius = true;
this.IsShowRect = true;
this.Name = "UCPanelTitle";
this.RectColor = System.Drawing.Color.FromArgb(((int)(((byte)(22)))), ((int)(((byte)(160)))), ((int)(((byte)(133)))));
this.Size = new System.Drawing.Size(432, 298);
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.Label lblTitle;
private System.Windows.Forms.RichTextBox richTextBox1;
private System.Windows.Forms.Button button1;
}
}
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using HZH_Controls.Controls;
namespace KonkeDemo
{
public partial class UCPanelTitle : UCControlBase
{
[Description("边框颜色"), Category("自定义")]
public Color BorderColor
{
get { return this.RectColor; }
set
{
this.RectColor = value;
this.lblTitle.BackColor = value;
}
}
[Description("面板标题"), Category("自定义")]
public string Title
{
get { return lblTitle.Text; }
set { lblTitle.Text = value; }
}
public string Msg
{
get { return richTextBox1.Text.Trim(); }
set { richTextBox1.AppendText(value + "\r\n"); }
}
public UCPanelTitle()
{
InitializeComponent();
}
private void button1_Click(object sender, EventArgs e)
{
Clipboard.SetText(richTextBox1.Text);
}
public void Clear()
{
if (richTextBox1.IsHandleCreated)
{
richTextBox1.Invoke(new EventHandler(delegate
{
richTextBox1.Clear();
richTextBox1.Refresh();
}));
}
else
{
richTextBox1.Clear();
richTextBox1.Refresh();
}
}
}
}
namespace KonkeDemo
{
partial class UCPanelTitleInfo
{
/// <summary>
/// 必需的设计器变量。
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// 清理所有正在使用的资源。
/// </summary>
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region 组件设计器生成的代码
/// <summary>
/// 设计器支持所需的方法 - 不要
/// 使用代码编辑器修改此方法的内容。
/// </summary>
private void InitializeComponent()
{
this.lblTitle = new System.Windows.Forms.Label();
this.richTextBox1 = new System.Windows.Forms.RichTextBox();
this.button1 = new System.Windows.Forms.Button();
this.SuspendLayout();
//
// lblTitle
//
this.lblTitle.BackColor = System.Drawing.Color.SpringGreen;
this.lblTitle.Dock = System.Windows.Forms.DockStyle.Top;
this.lblTitle.ForeColor = System.Drawing.Color.Black;
this.lblTitle.Location = new System.Drawing.Point(0, 0);
this.lblTitle.Name = "lblTitle";
this.lblTitle.Size = new System.Drawing.Size(432, 34);
this.lblTitle.TabIndex = 0;
this.lblTitle.Text = "基本信息";
this.lblTitle.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// richTextBox1
//
this.richTextBox1.Location = new System.Drawing.Point(0, 34);
this.richTextBox1.Name = "richTextBox1";
this.richTextBox1.ReadOnly = true;
this.richTextBox1.Size = new System.Drawing.Size(429, 232);
this.richTextBox1.TabIndex = 1;
this.richTextBox1.Text = "";
//
// button1
//
this.button1.Location = new System.Drawing.Point(171, 272);
this.button1.Name = "button1";
this.button1.Size = new System.Drawing.Size(75, 26);
this.button1.TabIndex = 3;
this.button1.Text = "复制";
this.button1.UseVisualStyleBackColor = true;
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// UCPanelTitleInfo
//
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.BackColor = System.Drawing.Color.Transparent;
this.ConerRadius = 10;
this.Controls.Add(this.button1);
this.Controls.Add(this.richTextBox1);
this.Controls.Add(this.lblTitle);
this.FillColor = System.Drawing.Color.White;
this.IsRadius = true;
this.IsShowRect = true;
this.Name = "UCPanelTitleInfo";
this.RectColor = System.Drawing.Color.FromArgb(((int)(((byte)(22)))), ((int)(((byte)(160)))), ((int)(((byte)(133)))));
this.Size = new System.Drawing.Size(432, 301);
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.Label lblTitle;
private System.Windows.Forms.RichTextBox richTextBox1;
private System.Windows.Forms.Button button1;
}
}
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using HZH_Controls.Controls;
namespace KonkeDemo
{
public partial class UCPanelTitleInfo : UCControlBase
{
[Description("边框颜色"), Category("自定义")]
public Color BorderColor
{
get { return this.RectColor; }
set
{
this.RectColor = value;
this.lblTitle.BackColor = value;
}
}
[Description("面板标题"), Category("自定义")]
public string Title
{
get { return lblTitle.Text; }
set { lblTitle.Text = value; }
}
public string Msg
{
get { return richTextBox1.Text.Trim(); }
set { richTextBox1.AppendText(value + "\r\n"); }
}
public UCPanelTitleInfo()
{
InitializeComponent();
}
private void button1_Click(object sender, EventArgs e)
{
Clipboard.SetText(richTextBox1.Text);
}
}
}
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using HZH_Controls;
using System.Drawing.Drawing2D;
namespace KonkeDemo
{
public class UCProcessLine : Control
{
[Description("值变更事件"), Category("自定义")]
public event EventHandler ValueChanged;
int m_value = 0;
[Description("当前属性"), Category("自定义")]
public int Value
{
set
{
if (value > m_maxValue)
m_value = m_maxValue;
else if (value < 0)
m_value = 0;
else
m_value = value;
if (ValueChanged != null)
ValueChanged(this, null);
Refresh();
}
get
{
return m_value;
}
}
private int m_maxValue = 100;
[Description("最大值"), Category("自定义")]
public int MaxValue
{
get { return m_maxValue; }
set
{
if (value < m_value)
m_maxValue = m_value;
else
m_maxValue = value;
Refresh();
}
}
Color m_valueColor = Color.FromArgb(73, 119, 232);
[Description("值进度条颜色"), Category("自定义")]
public Color ValueColor
{
get { return m_valueColor; }
set
{
m_valueColor = value;
Refresh();
}
}
private Color m_valueBGColor = Color.White;
[Description("值背景色"), Category("自定义")]
public Color ValueBGColor
{
get { return m_valueBGColor; }
set
{
m_valueBGColor = value;
Refresh();
}
}
private Color m_borderColor = Color.FromArgb(192, 192, 192);
[Description("边框颜色"), Category("自定义")]
public Color BorderColor
{
get { return m_borderColor; }
set
{
m_borderColor = value;
Refresh();
}
}
[Description("值字体"), Category("自定义")]
public override Font Font
{
get
{
return base.Font;
}
set
{
base.Font = value;
Refresh();
}
}
[Description("值字体颜色"), Category("自定义")]
public override System.Drawing.Color ForeColor
{
get
{
return base.ForeColor;
}
set
{
base.ForeColor = value;
Refresh();
}
}
private ValueTextType m_valueTextType = ValueTextType.Percent;
[Description("值显示样式"), Category("自定义")]
public ValueTextType ValueTextType
{
get { return m_valueTextType; }
set
{
m_valueTextType = value;
Refresh();
}
}
public UCProcessLine()
{
Size = new Size(200, 15);
ForeColor = Color.FromArgb(255, 77, 59);
Font = new Font("Arial Unicode MS", 10);
this.SetStyle(ControlStyles.AllPaintingInWmPaint, true);
this.SetStyle(ControlStyles.DoubleBuffer, true);
this.SetStyle(ControlStyles.ResizeRedraw, true);
this.SetStyle(ControlStyles.Selectable, true);
this.SetStyle(ControlStyles.SupportsTransparentBackColor, true);
this.SetStyle(ControlStyles.UserPaint, true);
}
protected override void OnPaint(PaintEventArgs e)
{
Console.WriteLine(DateTime.Now);
base.OnPaint(e);
Graphics g = e.Graphics;
g.SetGDIHigh();
Brush sb = new SolidBrush(m_valueBGColor);
g.FillRectangle(sb, new Rectangle(base.ClientRectangle.X, base.ClientRectangle.Y, base.ClientRectangle.Width - 3, base.ClientRectangle.Height - 2));
GraphicsPath path1 = ControlHelper.CreateRoundedRectanglePath(new Rectangle(base.ClientRectangle.X, base.ClientRectangle.Y + 1, base.ClientRectangle.Width - 3, base.ClientRectangle.Height - 4), 3);
g.DrawPath(new Pen(m_borderColor, 1), path1);
LinearGradientBrush lgb = new LinearGradientBrush(new Point(0, 0), new Point(0, base.ClientRectangle.Height - 3), m_valueColor, Color.FromArgb(200, m_valueColor.R, m_valueColor.G, m_valueColor.B));
g.FillPath(lgb, ControlHelper.CreateRoundedRectanglePath(new Rectangle(0, (base.ClientRectangle.Height - (base.ClientRectangle.Height - 3)) / 2, (base.ClientRectangle.Width - 3) * Value / m_maxValue, base.ClientRectangle.Height - 4), 3));
string strValue = string.Empty;
if (m_valueTextType == ValueTextType.Percent)//m_valueTextType == HZH_Controls.Controls.ValueTextType.Percent
strValue = ((float)Value / (float)m_maxValue).ToString("0%");
else if (m_valueTextType == ValueTextType.Absolute)//m_valueTextType == HZH_Controls.Controls.ValueTextType.Absolute
strValue = Value + "/" + m_maxValue;
if (!string.IsNullOrEmpty(strValue))
{
System.Drawing.SizeF sizeF = g.MeasureString(strValue, Font);
g.DrawString(strValue, Font, new SolidBrush(ForeColor), new PointF((this.Width - sizeF.Width) / 2, (this.Height - sizeF.Height) / 2 + 1));
}
}
public static implicit operator UCProcessLine(HZH_Controls.Controls.UCProcessLine v)
{
throw new NotImplementedException();
}
}
public enum ValueTextType
{
None,
/// <summary>
/// 百分比
/// </summary>
Percent,
/// <summary>
/// 数值
/// </summary>
Absolute
}
}
namespace KonkeDemo
{
partial class UserControlmodular
{
/// <summary>
/// 必需的设计器变量。
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// 清理所有正在使用的资源。
/// </summary>
/// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region 组件设计器生成的代码
/// <summary>
/// 设计器支持所需的方法 - 不要修改
/// 使用代码编辑器修改此方法的内容。
/// </summary>
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
HZH_Controls.Controls.NavigationMenuItemExt navigationMenuItemExt1 = new HZH_Controls.Controls.NavigationMenuItemExt();
HZH_Controls.Controls.NavigationMenuItemExt navigationMenuItemExt2 = new HZH_Controls.Controls.NavigationMenuItemExt();
this.labelControl1 = new DevExpress.XtraEditors.LabelControl();
this.textEdit1 = new DevExpress.XtraEditors.TextEdit();
this.label1 = new System.Windows.Forms.Label();
this.panel1 = new System.Windows.Forms.Panel();
this.ucNavigationMenuExt1 = new KonkeDemo.UCNavigationMenuExt();
this.ucProcessLine1 = new KonkeDemo.UCProcessLine();
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
this.panel2 = new System.Windows.Forms.Panel();
this.panel3 = new System.Windows.Forms.Panel();
this.label3 = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label();
this.timer1 = new System.Windows.Forms.Timer(this.components);
((System.ComponentModel.ISupportInitialize)(this.textEdit1.Properties)).BeginInit();
this.panel1.SuspendLayout();
this.tableLayoutPanel1.SuspendLayout();
this.panel2.SuspendLayout();
this.panel3.SuspendLayout();
this.SuspendLayout();
//
// labelControl1
//
this.labelControl1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.labelControl1.Location = new System.Drawing.Point(28, 52);
this.labelControl1.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.labelControl1.Name = "labelControl1";
this.labelControl1.Size = new System.Drawing.Size(18, 18);
this.labelControl1.TabIndex = 3;
this.labelControl1.Text = "SN";
//
// textEdit1
//
this.textEdit1.Location = new System.Drawing.Point(56, 48);
this.textEdit1.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.textEdit1.Name = "textEdit1";
this.textEdit1.Size = new System.Drawing.Size(296, 25);
this.textEdit1.TabIndex = 4;
//
// label1
//
this.label1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(277, 9);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(69, 15);
this.label1.TabIndex = 2;
this.label1.Text = "耗时: 0s";
//
// panel1
//
this.panel1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))));
this.tableLayoutPanel1.SetColumnSpan(this.panel1, 2);
this.panel1.Controls.Add(this.ucNavigationMenuExt1);
this.panel1.Controls.Add(this.ucProcessLine1);
this.panel1.Controls.Add(this.label1);
this.panel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel1.Location = new System.Drawing.Point(3, 371);
this.panel1.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(495, 35);
this.panel1.TabIndex = 8;
//
// ucNavigationMenuExt1
//
this.ucNavigationMenuExt1.BackColor = System.Drawing.Color.PaleVioletRed;
this.ucNavigationMenuExt1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.ucNavigationMenuExt1.ForeColor = System.Drawing.Color.White;
navigationMenuItemExt1.AnchorRight = false;
navigationMenuItemExt1.DataSource = null;
navigationMenuItemExt1.Icon = null;
navigationMenuItemExt1.ItemWidth = 100;
navigationMenuItemExt1.ShowControl = null;
navigationMenuItemExt1.ShowTip = false;
navigationMenuItemExt1.Text = "基本信息";
navigationMenuItemExt1.TipText = null;
navigationMenuItemExt2.AnchorRight = false;
navigationMenuItemExt2.DataSource = null;
navigationMenuItemExt2.Icon = null;
navigationMenuItemExt2.ItemWidth = 100;
navigationMenuItemExt2.ShowControl = null;
navigationMenuItemExt2.ShowTip = false;
navigationMenuItemExt2.Text = "错误";
navigationMenuItemExt2.TipText = null;
this.ucNavigationMenuExt1.Items = new HZH_Controls.Controls.NavigationMenuItemExt[] {
navigationMenuItemExt1,
navigationMenuItemExt2};
this.ucNavigationMenuExt1.Location = new System.Drawing.Point(0, 1);
this.ucNavigationMenuExt1.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.ucNavigationMenuExt1.Name = "ucNavigationMenuExt1";
this.ucNavigationMenuExt1.Size = new System.Drawing.Size(270, 33);
this.ucNavigationMenuExt1.TabIndex = 2;
this.ucNavigationMenuExt1.TipColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(87)))), ((int)(((byte)(34)))));
//
// ucProcessLine1
//
this.ucProcessLine1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.ucProcessLine1.BorderColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(192)))), ((int)(((byte)(192)))));
this.ucProcessLine1.Font = new System.Drawing.Font("Arial Unicode MS", 10F);
this.ucProcessLine1.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(77)))), ((int)(((byte)(59)))));
this.ucProcessLine1.Location = new System.Drawing.Point(353, 4);
this.ucProcessLine1.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.ucProcessLine1.MaxValue = 100;
this.ucProcessLine1.Name = "ucProcessLine1";
this.ucProcessLine1.Size = new System.Drawing.Size(140, 29);
this.ucProcessLine1.TabIndex = 3;
this.ucProcessLine1.Text = "ucProcessLine1";
this.ucProcessLine1.Value = 30;
this.ucProcessLine1.ValueBGColor = System.Drawing.Color.White;
this.ucProcessLine1.ValueColor = System.Drawing.Color.FromArgb(((int)(((byte)(73)))), ((int)(((byte)(119)))), ((int)(((byte)(232)))));
this.ucProcessLine1.ValueTextType = KonkeDemo.ValueTextType.Percent;
//
// tableLayoutPanel1
//
this.tableLayoutPanel1.ColumnCount = 1;
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 86.42715F));
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 13.57285F));
this.tableLayoutPanel1.Controls.Add(this.panel2, 0, 0);
this.tableLayoutPanel1.Controls.Add(this.panel1, 0, 2);
this.tableLayoutPanel1.Controls.Add(this.panel3, 0, 1);
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
this.tableLayoutPanel1.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
this.tableLayoutPanel1.RowCount = 3;
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 39.32584F));
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 60.67416F));
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 38F));
this.tableLayoutPanel1.Size = new System.Drawing.Size(501, 408);
this.tableLayoutPanel1.TabIndex = 9;
//
// panel2
//
this.panel2.Controls.Add(this.labelControl1);
this.panel2.Controls.Add(this.textEdit1);
this.panel2.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel2.Location = new System.Drawing.Point(3, 2);
this.panel2.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.panel2.Name = "panel2";
this.panel2.Size = new System.Drawing.Size(495, 141);
this.panel2.TabIndex = 10;
//
// panel3
//
this.panel3.BackColor = System.Drawing.Color.SpringGreen;
this.tableLayoutPanel1.SetColumnSpan(this.panel3, 2);
this.panel3.Controls.Add(this.label3);
this.panel3.Controls.Add(this.label2);
this.panel3.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel3.Location = new System.Drawing.Point(3, 147);
this.panel3.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.panel3.Name = "panel3";
this.panel3.Size = new System.Drawing.Size(495, 220);
this.panel3.TabIndex = 11;
//
// label3
//
this.label3.Font = new System.Drawing.Font("宋体", 25.8F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label3.Location = new System.Drawing.Point(3, 2);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(65, 48);
this.label3.TabIndex = 1;
this.label3.Text = "1";
this.label3.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// label2
//
this.label2.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
| System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.label2.Font = new System.Drawing.Font("宋体", 22.2F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.label2.Location = new System.Drawing.Point(99, 48);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(358, 101);
this.label2.TabIndex = 0;
this.label2.Text = "测试成功";
this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// timer1
//
this.timer1.Enabled = true;
this.timer1.Interval = 1000;
this.timer1.Tick += new System.EventHandler(this.timer1_Tick);
//
// UserControlmodular
//
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.BackColor = System.Drawing.Color.Aqua;
this.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.Controls.Add(this.tableLayoutPanel1);
this.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.Name = "UserControlmodular";
this.Size = new System.Drawing.Size(501, 408);
((System.ComponentModel.ISupportInitialize)(this.textEdit1.Properties)).EndInit();
this.panel1.ResumeLayout(false);
this.panel1.PerformLayout();
this.tableLayoutPanel1.ResumeLayout(false);
this.panel2.ResumeLayout(false);
this.panel2.PerformLayout();
this.panel3.ResumeLayout(false);
this.ResumeLayout(false);
}
#endregion
private DevExpress.XtraEditors.LabelControl labelControl1;
private DevExpress.XtraEditors.TextEdit textEdit1;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Panel panel1;
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
private System.Windows.Forms.Panel panel2;
private System.Windows.Forms.Panel panel3;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.Label label2;
private UCProcessLine ucProcessLine1;
private UCNavigationMenuExt ucNavigationMenuExt1;
private System.Windows.Forms.Timer timer1;
}
}
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace KonkeDemo
{
public partial class UserControlmodular : UserControl
{
private UCPanelTitleInfo textinfo = new UCPanelTitleInfo();
private UCPanelTitle texttitle = new UCPanelTitle();
public UserControlmodular()
{
InitializeComponent();
textinfo.Msg = "deviceid: 010203";
textinfo.Msg = "RSSI: -90";
textinfo.Msg = "SoftVersion: 1.0";
textinfo.Msg = "HardVersion: 2.0";
textinfo.Msg = "Installcode: 290001";
textinfo.Msg = "MAC: 123456789";
ucNavigationMenuExt1.Items[0].ShowControl = textinfo;
//ucNavigationMenuExt1.Items[1].TipText = "2";
//ucNavigationMenuExt1.Items[1].ShowTip = true;
//texttitle.Msg = DateTime.Now.ToString("yyyy-mm-dd HH:mm:ss") + ": " + "入网失败";
//text.Text = "读取信号强度失败";
ucNavigationMenuExt1.Items[1].ShowControl = texttitle;
}
public string TipText
{
set
{
ucNavigationMenuExt1.Invoke(new EventHandler(delegate
{
ucNavigationMenuExt1.Items[1].ShowTip = true;
ucNavigationMenuExt1.Items[1].TipText = value;
this.Refresh();
}));
}
}
public string Infomsg
{
set
{
textinfo.Msg = value;
}
}
public string Errormsg
{
set
{
texttitle.Msg = DateTime.Now.ToString("yyyy-mm-dd HH:mm:ss") + ": " + value.ToString();
this.Refresh();
}
}
public string SN
{
get
{
return textEdit1.Text.Trim();
}
set
{
textEdit1.Text = value;
}
}
public int Process
{
set
{
ucProcessLine1.Value = value;
}
}
public int iconclusion
{
set
{
if (value == 1)
{
label2.Text = "测试成功";
panel3.BackColor = Color.SpringGreen;
}
else if (value == 0)
{
label2.Text = "测试失败";
panel3.BackColor = Color.Red;
}
else if (value == 2)
{
label2.Text = "准备";
panel3.BackColor = Color.Gold;
}
}
}
public int position
{
set
{
label3.Text = value.ToString();
}
}
public int ControlWidth
{
get
{
return this.Width;
}
}
public string status
{
set
{
label2.Text = value.ToString();
}
}
private int errorcnt;
public int ErrorCnt
{
get { return errorcnt; }
set { errorcnt = value; }
}
private List<string> TErrorlog = new List<string>();
public virtual void ViewLog(Helper.CustomMessage customMessage, string message)
{
try
{
switch (customMessage)
{
case Helper.CustomMessage.ViewLog:
label2.Invoke(new EventHandler(delegate
{
label2.Text = message;
}));
break;
case Helper.CustomMessage.Alarm:
//texttitle = new UCPanelTitle();
ErrorCnt++;
TErrorlog.Add(message);
//TipText = ErrorCnt.ToString();
//Errormsg = message;
break;
case Helper.CustomMessage.QuerySN:
break;
case Helper.CustomMessage.Stop:
break;
case Helper.CustomMessage.Progress:
int process = 0;
if (int.TryParse(message, out process))
{
ucProcessLine1.Invoke(new EventHandler(delegate
{
ucProcessLine1.Value = process;
}));
}
break;
case Helper.CustomMessage.Result:
if (message.Equals("0"))
{
panel3.Invoke(new EventHandler(delegate
{
panel3.BackColor = Color.Red;
panel3.Refresh();
}));
}
else if (message.Equals("1"))
{
panel3.Invoke(new EventHandler(delegate
{
panel3.BackColor = Color.SpringGreen;
panel3.Refresh();
}));
}
break;
}
}
catch(Exception exc) { }
}
public void fnUpdate()
{
if (ErrorCnt > 0)
{
TipText = ErrorCnt.ToString();
for (int i = 0; i < TErrorlog.Count; i++)
{
Errormsg = TErrorlog[i];
}
}
}
public void Finished()
{
textEdit1.Invoke(new EventHandler(delegate
{
textEdit1.Enabled = true;
}));
}
public void Init()
{
ErrorCnt = 0;
TErrorlog = new List<string>();
ucNavigationMenuExt1.Invoke(new EventHandler(delegate
{
ucNavigationMenuExt1.Items[1].ShowTip = false;
this.Refresh();
}));
this.BackColor = System.Drawing.Color.Aqua;
Process = 0;
iconclusion = 2;
texttitle.Clear();
textEdit1.Invoke(new EventHandler(delegate
{
textEdit1.Enabled = false;
}));
}
public void Run(object obj)
{
bTest = true;
topSeconds = 0;
UIDemoProcess autoTest = new UIDemoProcess();
autoTest.SendMessage += ViewLog;
autoTest.Run(null);
autoTest.SendMessage -= ViewLog;
bTest = false;
topSeconds = 0;
}
private bool bTest = false;
private int topSeconds = 0;
private void timer1_Tick(object sender, EventArgs e)
{
try
{
if (bTest)
{
topSeconds++;
label1.Invoke(new EventHandler(delegate
{
label1.Text = string.Format("耗时: {0} S", topSeconds);
}));
}
}
catch { }
}
}
}
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="timer1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
</root>
\ No newline at end of file
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace KonkeDemo
{
public class ControlChangesWithWindows
{
private float TempFormX;//当前窗体的宽度
private float TempFormY;//当前窗体的高度
// 将控件的宽,高,左边距,顶边距和字体大小暂存到tag属性中
// <param name="cons">递归控件中的控件</param>
//传入参数当前窗口
private void setTag(Control cons)
{
foreach (Control con in cons.Controls)
{
con.Tag = con.Width + ":" + con.Height + ":" + con.Left + ":" + con.Top + ":" + con.Font.Size;
if (con.Controls.Count > 0)
{
setTag(con);
}
}
}
//根据窗体大小调整控件大小
//传入参数,窗体宽度缩放比例,窗体高度缩放比例,当前窗口
private void setControls(float newx, float newy, Control cons)
{
//遍历窗体中的控件,重新设置控件的值
foreach (Control con in cons.Controls)
{
if (con != null)
{
string[] mytag = con.Tag?.ToString().Split(new char[] { ':' });//获取控件的Tag属性值,并分割后存储字符串数组
if (mytag != null && mytag.Length >= 5)
{
float a = System.Convert.ToSingle(mytag[0]) * newx;//根据窗体缩放比例确定控件的值,宽度
con.Width = (int)a;//宽度
a = System.Convert.ToSingle(mytag[1]) * newy;//高度
con.Height = (int)(a);
a = System.Convert.ToSingle(mytag[2]) * newx;//左边距离
con.Left = (int)(a);
a = System.Convert.ToSingle(mytag[3]) * newy;//上边缘距离
con.Top = (int)(a);
Single currentSize = System.Convert.ToSingle(mytag[4]) * newy;//字体大小
con.Font = new Font(con.Font.Name, currentSize, con.Font.Style, con.Font.Unit);
if (con.Controls.Count > 0)
{
setControls(newx, newy, con);
}
}
}
}
}
//传入参数:当前窗口
//用于窗口load事件调用
public void MethodForLoad(Control cons)
{
TempFormX = cons.Width;//获取窗体的宽度
TempFormY = cons.Height;//获取窗体的高度
setTag(cons);
}
/// <summary>
/// 窗口load事件调用,设置控件初始大小
/// </summary>
/// <param name="cons">当前窗口</param>
/// <param name="ctlSizeReferent">大小变化的参考控件</param>
public void MethodForLoad(Control cons, Control ctlSizeReferent)
{
TempFormX = ctlSizeReferent.Width;//获取窗体的宽度
TempFormY = ctlSizeReferent.Height;//获取窗体的高度
setTag(cons);
}
//引用SendMessage函数
[DllImport("user32.dll", EntryPoint = "SendMessage")]
private static extern int SendMessage(IntPtr hwnd, int wMsg, int wParam, IntPtr lParam);
//传入参数:当前窗口
//用于窗口Resize事件调用
public void MethodForResize(Control cons)
{
float newx = (cons.Width) / TempFormX; //窗体宽度缩放比例
float newy = (cons.Height) / TempFormY;//窗体高度缩放比例
SendMessage(cons.Handle, 0xB, 0, IntPtr.Zero); //解决控件较多时,改变大小闪一下问题
setControls(newx, newy, cons);
SendMessage(cons.Handle, 0XB, 1, IntPtr.Zero);
cons.Invalidate(true);
}
/// <summary>
/// 窗口Resize事件调用
/// </summary>
/// <param name="cons">当前窗口</param>
/// <param name="ctlSizeReferent">大小变化的参考控件</param>
public void MethodForResize(Control cons, Control ctlSizeReferent)
{
float newx = (ctlSizeReferent.Width) / TempFormX; //窗体宽度缩放比例
float newy = (ctlSizeReferent.Height) / TempFormY;//窗体高度缩放比例
SendMessage(cons.Handle, 0xB, 0, IntPtr.Zero); //解决控件较多时,改变大小闪一下问题
setControls(newx, newy, cons);
SendMessage(cons.Handle, 0XB, 1, IntPtr.Zero);
cons.Invalidate(true);
}
}
}
using System;
using System.Collections.Generic;
using System.IO.Ports;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace KonkeDemo
{
public class BaseConfig
{
private List<DeviceInfo> deviceInfos = new List<DeviceInfo>();
//private static string filepath;
public static string[] FilePath;
//private static double thresholdvalue;
public static double[] ThresholdValue;
private static string cameraFilePath1;
public static string CameraFilePath1
{
get { return cameraFilePath1; }
set { cameraFilePath1 = value; }
}
private static string cameraFilePath2;
public static string CameraFilePath2
{
get { return cameraFilePath2; }
set { cameraFilePath2 = value; }
}
private static double thresholdValue1;
public static double ThresholdValue1
{
get { return thresholdValue1; }
set { thresholdValue1 = value; }
}
private static double thresholdValue2;
public static double ThresholdValue2
{
get { return thresholdValue2; }
set { thresholdValue2 = value; }
}
private static int switchcnt;
public static int SwitchCnt
{
get { return switchcnt; }
set { switchcnt = value; }
}
private static int devicenumber;
public static int DeviceNumber
{
get { return devicenumber; }
set { devicenumber = value; }
}
private static string myDepartment;
public static string MyDepartment
{
get
{
return myDepartment;
}
set
{
myDepartment = value;
}
}
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace KonkeDemo
{
public class DeviceInfo
{
private SNInfo nInfo;
public SNInfo SNInfo
{
get { return nInfo; }
set { nInfo = value; }
}
private string ipaddress;
public string IpAddress
{
get { return ipaddress; }
set { ipaddress = value; }
}
private int iport;
public int Port
{
get { return iport; }
set { iport = value; }
}
private string tempbatchnumber;
public string TempbatchNumber
{
get { return tempbatchnumber; }
set { tempbatchnumber = value; }
}
private string tempMySAPB;
public string TempMySAPB
{
get
{
return tempMySAPB;
}
set
{
tempMySAPB = value;
}
}
private string tempfactoryId;
public string TempfactoryId
{
get { return tempfactoryId; }
set { tempfactoryId = value; }
}
private string tempfactoryLineId;
public string TempfactoryLineId
{
get { return tempfactoryLineId; }
set { tempfactoryLineId = value; }
}
private string tempGetJHH;
public string TempGetJHH
{
get { return tempGetJHH; }
set { tempGetJHH = value; }
}
private string tempproductmodel;
public string TempProductModel
{
get { return tempproductmodel; }
set { tempproductmodel = value; }
}
private string coordinatorPortName;
public string CoordinatorPortName
{
get
{
return coordinatorPortName;
}
set
{
coordinatorPortName = value;
}
}
private string keyboardPortName;
public string KeyBoardPortName
{
get
{
return keyboardPortName;
}
set
{
keyboardPortName = value;
}
}
private string powerPortName;
public string PowerPortName
{
get { return powerPortName; }
set { powerPortName = value; }
}
private string auxiliaryPortName;
public string AuxiliaryPortName
{
get { return auxiliaryPortName; }
set { auxiliaryPortName = value; }
}
private int socketovertime;
public int SocketOverTime
{
get { return socketovertime; }
set { socketovertime = value; }
}
private int portovertime;
public int PortOverTime
{
get { return portovertime; }
set { portovertime = value; }
}
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace KonkeDemo
{
public class SNInfo
{
private string zjsn;
public string ZJSN
{
get
{
return zjsn;
}
set
{
zjsn = value;
}
}
private string keyboardsn;
public string KeyBoardSN
{
get
{
return keyboardsn;
}
set
{
keyboardsn = value;
}
}
private int keyboardid;
public int KeyBoardID
{
get { return keyboardid; }
set { keyboardid = value; }
}
private string powerpanelsn;
public string PowerPanelSN
{
get { return powerpanelsn; }
set { powerpanelsn = value; }
}
private int powerpanelid;
public int PowerPanelID
{
get { return powerpanelid; }
set { powerpanelid = value; }
}
private bool havebind;
public bool HaveBind
{
get { return havebind; }
set { havebind = value; }
}
private bool havetest;
public bool HaveTest
{
get { return havetest; }
set { havetest = value; }
}
private string softwareversion;
public string SoftWareVersion
{
get { return softwareversion; }
set { softwareversion = value; }
}
private string hardwareversion;
private string HardWareVersion
{
get { return hardwareversion; }
set { hardwareversion = value; }
}
private string mac;
public string Mac
{
get { return mac; }
set { mac = value; }
}
private string deviceid;
public string DeviceID
{
get
{
return deviceid;
}
set { deviceid = value; }
}
private int myrssi;
public int MyRssi
{
get
{
return myrssi;
}
set
{
myrssi = value;
}
}
private string devicetype;
public string DEVICEType
{
get { return devicetype; }
set { devicetype = value; }
}
private string installcode;
public string InstallCode
{
get
{
return installcode;
}
set
{
installcode = value;
}
}
private ushort shortaddr;
public ushort ShortAddr
{
get { return shortaddr; }
set { shortaddr = value; }
}
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace KonkeDemo
{
public static class Helper
{
public enum CustomMessage
{
ViewLog,
QuerySN,
Alarm,
Stop,
Result,
Progress,
}
private static bool bstop;
public static bool Stop
{
get { return bstop; }
set { bstop = value; }
}
}
}
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{7A9E2491-A48C-4BD9-A537-E7F5A2B2D1E8}</ProjectGuid>
<OutputType>WinExe</OutputType>
<RootNamespace>KonkeDemo</RootNamespace>
<AssemblyName>KonkeDemo</AssemblyName>
<TargetFrameworkVersion>v4.7.2</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
<Deterministic>true</Deterministic>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<PlatformTarget>AnyCPU</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|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="DevExpress.Data.v10.2">
<HintPath>..\..\..\workplace(管理客户端)\konkemanufactureclient\About\Libs\DevExpress\DevExpress.Data.v10.2.dll</HintPath>
</Reference>
<Reference Include="DevExpress.Design.v10.2, Version=10.2.3.0, Culture=neutral, PublicKeyToken=365ac3cecbd70e0e, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\workplace(管理客户端)\konkemanufactureclient\About\Libs\DevExpress\DevExpress.Design.v10.2.dll</HintPath>
</Reference>
<Reference Include="DevExpress.Utils.v10.2">
<HintPath>..\..\..\workplace(管理客户端)\konkemanufactureclient\About\Libs\DevExpress\DevExpress.Utils.v10.2.dll</HintPath>
</Reference>
<Reference Include="DevExpress.XtraBars.v10.2">
<HintPath>..\..\..\workplace(管理客户端)\konkemanufactureclient\About\Libs\DevExpress\DevExpress.XtraBars.v10.2.dll</HintPath>
</Reference>
<Reference Include="DevExpress.XtraEditors.v10.2">
<HintPath>..\..\..\workplace(管理客户端)\konkemanufactureclient\About\Libs\DevExpress\DevExpress.XtraEditors.v10.2.dll</HintPath>
</Reference>
<Reference Include="DevExpress.XtraEditors.v10.2.Design">
<HintPath>..\..\..\workplace(管理客户端)\konkemanufactureclient\About\Libs\DevExpress\DevExpress.XtraEditors.v10.2.Design.dll</HintPath>
</Reference>
<Reference Include="DevExpress.XtraGrid.v10.2">
<HintPath>..\..\..\workplace(管理客户端)\konkemanufactureclient\About\Libs\DevExpress\DevExpress.XtraGrid.v10.2.dll</HintPath>
</Reference>
<Reference Include="DevExpress.XtraLayout.v10.2">
<HintPath>..\..\..\workplace(管理客户端)\konkemanufactureclient\About\Libs\DevExpress\DevExpress.XtraLayout.v10.2.dll</HintPath>
</Reference>
<Reference Include="DevExpress.XtraLayout.v10.2.Design">
<HintPath>..\..\..\workplace(管理客户端)\konkemanufactureclient\About\Libs\DevExpress10.2All\DevExpress.XtraLayout.v10.2.Design.dll</HintPath>
</Reference>
<Reference Include="DevExpress.XtraNavBar.v10.2">
<HintPath>..\..\..\workplace(管理客户端)\konkemanufactureclient\About\Libs\DevExpress\DevExpress.XtraNavBar.v10.2.dll</HintPath>
</Reference>
<Reference Include="DevExpress.XtraTreeList.v10.2">
<HintPath>..\..\..\workplace(管理客户端)\konkemanufactureclient\About\Libs\DevExpress\DevExpress.XtraTreeList.v10.2.dll</HintPath>
</Reference>
<Reference Include="HZH_Controls, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\HZH_Controls.1.0.14\lib\net40\HZH_Controls.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Data" />
<Reference Include="System.Deployment" />
<Reference Include="System.Drawing" />
<Reference Include="System.Net.Http" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="UIDemoProcess.cs" />
<Compile Include="AutoTestService.cs" />
<Compile Include="Entity\BaseConfig.cs" />
<Compile Include="ControlChangesWithWindows.cs" />
<Compile Include="UI\Configure.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="UI\Configure.Designer.cs">
<DependentUpon>Configure.cs</DependentUpon>
</Compile>
<Compile Include="Entity\DeviceInfo.cs" />
<Compile Include="UI\FormConfigure.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="UI\FormConfigure.Designer.cs">
<DependentUpon>FormConfigure.cs</DependentUpon>
</Compile>
<Compile Include="UI\FormMain.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="UI\FormMain.Designer.cs">
<DependentUpon>FormMain.cs</DependentUpon>
</Compile>
<Compile Include="Helper.cs" />
<Compile Include="UI\Load.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="UI\Load.Designer.cs">
<DependentUpon>Load.cs</DependentUpon>
</Compile>
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Entity\SNInfo.cs" />
<Compile Include="Control\UCNavigationMenuExt.cs">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="Control\UCNavigationMenuExt.Designer.cs">
<DependentUpon>UCNavigationMenuExt.cs</DependentUpon>
</Compile>
<Compile Include="Control\UCPanelTitle.cs">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="Control\UCPanelTitle.Designer.cs">
<DependentUpon>UCPanelTitle.cs</DependentUpon>
</Compile>
<Compile Include="Control\UCPanelTitleInfo.cs">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="Control\UCPanelTitleInfo.Designer.cs">
<DependentUpon>UCPanelTitleInfo.cs</DependentUpon>
</Compile>
<Compile Include="Control\UCProcessLine.cs">
<SubType>Component</SubType>
</Compile>
<Compile Include="UIDemoInterface.cs" />
<Compile Include="Control\UserControlmodular.cs">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="Control\UserControlmodular.Designer.cs">
<DependentUpon>UserControlmodular.cs</DependentUpon>
</Compile>
<EmbeddedResource Include="UI\FormConfigure.resx">
<DependentUpon>FormConfigure.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="UI\FormMain.resx">
<DependentUpon>FormMain.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>
<EmbeddedResource Include="Control\UserControlmodular.resx">
<DependentUpon>UserControlmodular.cs</DependentUpon>
</EmbeddedResource>
<None Include="packages.config" />
<None Include="Properties\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
</None>
<Compile Include="Properties\Settings.Designer.cs">
<AutoGen>True</AutoGen>
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
</ItemGroup>
<ItemGroup>
<None Include="App.config" />
</ItemGroup>
<ItemGroup />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
</Project>
\ No newline at end of file

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 16
VisualStudioVersion = 16.0.30320.27
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "KonkeDemo", "KonkeDemo.csproj", "{7A9E2491-A48C-4BD9-A537-E7F5A2B2D1E8}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{7A9E2491-A48C-4BD9-A537-E7F5A2B2D1E8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{7A9E2491-A48C-4BD9-A537-E7F5A2B2D1E8}.Debug|Any CPU.Build.0 = Debug|Any CPU
{7A9E2491-A48C-4BD9-A537-E7F5A2B2D1E8}.Release|Any CPU.ActiveCfg = Release|Any CPU
{7A9E2491-A48C-4BD9-A537-E7F5A2B2D1E8}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {C0CC0C9A-0878-4D3C-8B6B-5A952C19C0B4}
EndGlobalSection
EndGlobal
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace KonkeDemo
{
static class Program
{
/// <summary>
/// 应用程序的主入口点。
/// </summary>
[STAThread]
static void Main()
{
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
Application.Run(new LoadForm());
}
}
}
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// 有关程序集的一般信息由以下
// 控制。更改这些特性值可修改
// 与程序集关联的信息。
[assembly: AssemblyTitle("KonkeDemo")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("KonkeDemo")]
[assembly: AssemblyCopyright("Copyright © 2020")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// 将 ComVisible 设置为 false 会使此程序集中的类型
//对 COM 组件不可见。如果需要从 COM 访问此程序集中的类型
//请将此类型的 ComVisible 特性设置为 true。
[assembly: ComVisible(false)]
// 如果此项目向 COM 公开,则下列 GUID 用于类型库的 ID
[assembly: Guid("7a9e2491-a48c-4bd9-a537-e7f5a2b2d1e8")]
// 程序集的版本信息由下列四个值组成:
//
// 主版本
// 次版本
// 生成号
// 修订号
//
//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值
//通过使用 "*",如下所示:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
// 运行时版本: 4.0.30319.42000
//
// 对此文件的更改可能导致不正确的行为,如果
// 重新生成代码,则所做更改将丢失。
// </auto-generated>
//------------------------------------------------------------------------------
namespace KonkeDemo.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("KonkeDemo.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;
}
}
}
}
<?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>
\ No newline at end of file
//------------------------------------------------------------------------------
// <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 KonkeDemo.Properties
{
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.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;
}
}
}
}
<?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>
namespace KonkeDemo
{
partial class Configure
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Configure));
this.ConfigureOK = new System.Windows.Forms.Button();
this.label2 = new System.Windows.Forms.Label();
this.label4 = new System.Windows.Forms.Label();
this.label5 = new System.Windows.Forms.Label();
this.DEVName = new System.Windows.Forms.ComboBox();
this.ProductModel = new System.Windows.Forms.TextBox();
this.SVNumber = new System.Windows.Forms.TextBox();
this.SSIDName = new System.Windows.Forms.TextBox();
this.label11 = new System.Windows.Forms.Label();
this.label12 = new System.Windows.Forms.Label();
this.SerialSlogan1 = new System.Windows.Forms.ComboBox();
this.label13 = new System.Windows.Forms.Label();
this.RSSIText = new System.Windows.Forms.TextBox();
this.label14 = new System.Windows.Forms.Label();
this.SerialSlogan2 = new System.Windows.Forms.ComboBox();
this.label16 = new System.Windows.Forms.Label();
this.HighPower = new System.Windows.Forms.TextBox();
this.label17 = new System.Windows.Forms.Label();
this.label18 = new System.Windows.Forms.Label();
this.label19 = new System.Windows.Forms.Label();
this.LowPower = new System.Windows.Forms.TextBox();
this.HighA = new System.Windows.Forms.TextBox();
this.LowA = new System.Windows.Forms.TextBox();
this.BackToLoad = new System.Windows.Forms.Button();
this.ConfigureText = new System.Windows.Forms.Label();
this.label1 = new System.Windows.Forms.Label();
this.DevNameText = new System.Windows.Forms.TextBox();
this.label3 = new System.Windows.Forms.Label();
this.label6 = new System.Windows.Forms.Label();
this.factoryIdText = new System.Windows.Forms.TextBox();
this.factoryLineIdText = new System.Windows.Forms.TextBox();
this.label7 = new System.Windows.Forms.Label();
this.HVNumber = new System.Windows.Forms.TextBox();
this.label8 = new System.Windows.Forms.Label();
this.productID = new System.Windows.Forms.TextBox();
this.label9 = new System.Windows.Forms.Label();
this.FormComboBox = new System.Windows.Forms.ComboBox();
this.label10 = new System.Windows.Forms.Label();
this.SAPName = new System.Windows.Forms.TextBox();
this.label15 = new System.Windows.Forms.Label();
this.SAPBH = new System.Windows.Forms.TextBox();
this.label20 = new System.Windows.Forms.Label();
this.SAPDDH = new System.Windows.Forms.TextBox();
this.XMLComboBox = new System.Windows.Forms.ComboBox();
this.label21 = new System.Windows.Forms.Label();
this.btnLogWindow = new System.Windows.Forms.Button();
this.btnConfigSerialPort = new System.Windows.Forms.Button();
this.comboBox1 = new System.Windows.Forms.ComboBox();
this.label22 = new System.Windows.Forms.Label();
this.SuspendLayout();
//
// ConfigureOK
//
this.ConfigureOK.Location = new System.Drawing.Point(907, 455);
this.ConfigureOK.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.ConfigureOK.Name = "ConfigureOK";
this.ConfigureOK.Size = new System.Drawing.Size(100, 36);
this.ConfigureOK.TabIndex = 0;
this.ConfigureOK.Text = "确定";
this.ConfigureOK.UseVisualStyleBackColor = true;
this.ConfigureOK.Click += new System.EventHandler(this.ConfigureOK_Click);
//
// label2
//
this.label2.AutoSize = true;
this.label2.Location = new System.Drawing.Point(15, 96);
this.label2.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(82, 15);
this.label2.TabIndex = 2;
this.label2.Text = "产品型号:";
//
// label4
//
this.label4.AutoSize = true;
this.label4.Location = new System.Drawing.Point(15, 481);
this.label4.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(97, 15);
this.label4.TabIndex = 4;
this.label4.Text = "软件版本号:";
//
// label5
//
this.label5.AutoSize = true;
this.label5.Location = new System.Drawing.Point(5, 45);
this.label5.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(97, 15);
this.label5.TabIndex = 5;
this.label5.Text = "待测订单号:";
//
// DEVName
//
this.DEVName.FormattingEnabled = true;
this.DEVName.Location = new System.Drawing.Point(132, 41);
this.DEVName.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.DEVName.Name = "DEVName";
this.DEVName.Size = new System.Drawing.Size(193, 23);
this.DEVName.TabIndex = 17;
this.DEVName.SelectedIndexChanged += new System.EventHandler(this.DEVName_SelectedIndexChanged);
this.DEVName.TextChanged += new System.EventHandler(this.DEVName_TextChanged);
//
// ProductModel
//
this.ProductModel.Enabled = false;
this.ProductModel.Location = new System.Drawing.Point(131, 92);
this.ProductModel.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.ProductModel.Name = "ProductModel";
this.ProductModel.Size = new System.Drawing.Size(195, 25);
this.ProductModel.TabIndex = 18;
//
// SVNumber
//
this.SVNumber.Enabled = false;
this.SVNumber.Location = new System.Drawing.Point(147, 474);
this.SVNumber.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.SVNumber.Name = "SVNumber";
this.SVNumber.Size = new System.Drawing.Size(179, 25);
this.SVNumber.TabIndex = 20;
//
// SSIDName
//
this.SSIDName.Location = new System.Drawing.Point(555, 49);
this.SSIDName.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.SSIDName.Name = "SSIDName";
this.SSIDName.Size = new System.Drawing.Size(147, 25);
this.SSIDName.TabIndex = 21;
this.SSIDName.Text = "WIFI_TEST";
//
// label11
//
this.label11.AutoSize = true;
this.label11.Location = new System.Drawing.Point(431, 52);
this.label11.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label11.Name = "label11";
this.label11.Size = new System.Drawing.Size(82, 15);
this.label11.TabIndex = 22;
this.label11.Text = "热点名称:";
//
// label12
//
this.label12.AutoSize = true;
this.label12.Location = new System.Drawing.Point(415, 159);
this.label12.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label12.Name = "label12";
this.label12.Size = new System.Drawing.Size(105, 15);
this.label12.TabIndex = 23;
this.label12.Text = "辅助串口号1:";
//
// SerialSlogan1
//
this.SerialSlogan1.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.SerialSlogan1.FormattingEnabled = true;
this.SerialSlogan1.Location = new System.Drawing.Point(555, 159);
this.SerialSlogan1.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.SerialSlogan1.Name = "SerialSlogan1";
this.SerialSlogan1.Size = new System.Drawing.Size(147, 23);
this.SerialSlogan1.TabIndex = 24;
this.SerialSlogan1.MouseClick += new System.Windows.Forms.MouseEventHandler(this.SerialSlogan1_MouseClick);
//
// label13
//
this.label13.AutoSize = true;
this.label13.Location = new System.Drawing.Point(431, 109);
this.label13.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label13.Name = "label13";
this.label13.Size = new System.Drawing.Size(82, 15);
this.label13.TabIndex = 25;
this.label13.Text = "信号阈值:";
//
// RSSIText
//
this.RSSIText.Location = new System.Drawing.Point(555, 105);
this.RSSIText.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.RSSIText.Name = "RSSIText";
this.RSSIText.Size = new System.Drawing.Size(147, 25);
this.RSSIText.TabIndex = 26;
this.RSSIText.Text = "-45";
//
// label14
//
this.label14.AutoSize = true;
this.label14.Location = new System.Drawing.Point(415, 214);
this.label14.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label14.Name = "label14";
this.label14.Size = new System.Drawing.Size(105, 15);
this.label14.TabIndex = 27;
this.label14.Text = "辅助串口号2:";
//
// SerialSlogan2
//
this.SerialSlogan2.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.SerialSlogan2.FormattingEnabled = true;
this.SerialSlogan2.Location = new System.Drawing.Point(555, 214);
this.SerialSlogan2.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.SerialSlogan2.Name = "SerialSlogan2";
this.SerialSlogan2.Size = new System.Drawing.Size(147, 23);
this.SerialSlogan2.TabIndex = 28;
this.SerialSlogan2.MouseClick += new System.Windows.Forms.MouseEventHandler(this.SerialSlogan2_MouseClick);
//
// label16
//
this.label16.AutoSize = true;
this.label16.Location = new System.Drawing.Point(431, 272);
this.label16.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label16.Name = "label16";
this.label16.Size = new System.Drawing.Size(82, 15);
this.label16.TabIndex = 33;
this.label16.Text = "最高功率:";
//
// HighPower
//
this.HighPower.Location = new System.Drawing.Point(555, 265);
this.HighPower.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.HighPower.Name = "HighPower";
this.HighPower.Size = new System.Drawing.Size(147, 25);
this.HighPower.TabIndex = 34;
this.HighPower.Text = "10";
//
// label17
//
this.label17.AutoSize = true;
this.label17.Location = new System.Drawing.Point(431, 401);
this.label17.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label17.Name = "label17";
this.label17.Size = new System.Drawing.Size(82, 15);
this.label17.TabIndex = 35;
this.label17.Text = "最小电流:";
//
// label18
//
this.label18.AutoSize = true;
this.label18.Location = new System.Drawing.Point(431, 362);
this.label18.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label18.Name = "label18";
this.label18.Size = new System.Drawing.Size(82, 15);
this.label18.TabIndex = 36;
this.label18.Text = "最大电流:";
//
// label19
//
this.label19.AutoSize = true;
this.label19.Location = new System.Drawing.Point(431, 316);
this.label19.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label19.Name = "label19";
this.label19.Size = new System.Drawing.Size(82, 15);
this.label19.TabIndex = 37;
this.label19.Text = "最低功率:";
//
// LowPower
//
this.LowPower.Location = new System.Drawing.Point(555, 305);
this.LowPower.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.LowPower.Name = "LowPower";
this.LowPower.Size = new System.Drawing.Size(147, 25);
this.LowPower.TabIndex = 38;
this.LowPower.Text = "1";
//
// HighA
//
this.HighA.Location = new System.Drawing.Point(555, 351);
this.HighA.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.HighA.Name = "HighA";
this.HighA.Size = new System.Drawing.Size(147, 25);
this.HighA.TabIndex = 39;
this.HighA.Text = "10";
//
// LowA
//
this.LowA.Location = new System.Drawing.Point(555, 398);
this.LowA.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.LowA.Name = "LowA";
this.LowA.Size = new System.Drawing.Size(147, 25);
this.LowA.TabIndex = 40;
this.LowA.Text = "1";
//
// BackToLoad
//
this.BackToLoad.Location = new System.Drawing.Point(907, 519);
this.BackToLoad.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.BackToLoad.Name = "BackToLoad";
this.BackToLoad.Size = new System.Drawing.Size(100, 29);
this.BackToLoad.TabIndex = 43;
this.BackToLoad.Text = "上一页";
this.BackToLoad.UseVisualStyleBackColor = true;
this.BackToLoad.Click += new System.EventHandler(this.BackToLoad_Click);
//
// ConfigureText
//
this.ConfigureText.AutoSize = true;
this.ConfigureText.ForeColor = System.Drawing.Color.Red;
this.ConfigureText.Location = new System.Drawing.Point(888, 415);
this.ConfigureText.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.ConfigureText.Name = "ConfigureText";
this.ConfigureText.Size = new System.Drawing.Size(112, 15);
this.ConfigureText.TabIndex = 44;
this.ConfigureText.Text = "请配置完整信息";
this.ConfigureText.Visible = false;
//
// label1
//
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(16, 152);
this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(82, 15);
this.label1.TabIndex = 45;
this.label1.Text = "产品名称:";
//
// DevNameText
//
this.DevNameText.Enabled = false;
this.DevNameText.Location = new System.Drawing.Point(131, 145);
this.DevNameText.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.DevNameText.Multiline = true;
this.DevNameText.Name = "DevNameText";
this.DevNameText.Size = new System.Drawing.Size(195, 49);
this.DevNameText.TabIndex = 46;
//
// label3
//
this.label3.AutoSize = true;
this.label3.Location = new System.Drawing.Point(16, 379);
this.label3.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(68, 15);
this.label3.TabIndex = 47;
this.label3.Text = "工厂ID:";
//
// label6
//
this.label6.AutoSize = true;
this.label6.Location = new System.Drawing.Point(16, 428);
this.label6.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label6.Name = "label6";
this.label6.Size = new System.Drawing.Size(68, 15);
this.label6.TabIndex = 48;
this.label6.Text = "产线ID:";
//
// factoryIdText
//
this.factoryIdText.Enabled = false;
this.factoryIdText.Location = new System.Drawing.Point(129, 375);
this.factoryIdText.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.factoryIdText.Name = "factoryIdText";
this.factoryIdText.Size = new System.Drawing.Size(196, 25);
this.factoryIdText.TabIndex = 49;
//
// factoryLineIdText
//
this.factoryLineIdText.Enabled = false;
this.factoryLineIdText.Location = new System.Drawing.Point(129, 424);
this.factoryLineIdText.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.factoryLineIdText.Name = "factoryLineIdText";
this.factoryLineIdText.Size = new System.Drawing.Size(196, 25);
this.factoryLineIdText.TabIndex = 50;
//
// label7
//
this.label7.AutoSize = true;
this.label7.Location = new System.Drawing.Point(15, 528);
this.label7.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label7.Name = "label7";
this.label7.Size = new System.Drawing.Size(97, 15);
this.label7.TabIndex = 51;
this.label7.Text = "硬件版本号:";
//
// HVNumber
//
this.HVNumber.Enabled = false;
this.HVNumber.Location = new System.Drawing.Point(147, 524);
this.HVNumber.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.HVNumber.Name = "HVNumber";
this.HVNumber.Size = new System.Drawing.Size(179, 25);
this.HVNumber.TabIndex = 52;
//
// label8
//
this.label8.AutoSize = true;
this.label8.Location = new System.Drawing.Point(16, 576);
this.label8.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label8.Name = "label8";
this.label8.Size = new System.Drawing.Size(68, 15);
this.label8.TabIndex = 53;
this.label8.Text = "产品ID:";
//
// productID
//
this.productID.Enabled = false;
this.productID.Location = new System.Drawing.Point(129, 572);
this.productID.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.productID.Name = "productID";
this.productID.Size = new System.Drawing.Size(196, 25);
this.productID.TabIndex = 54;
//
// label9
//
this.label9.AutoSize = true;
this.label9.Location = new System.Drawing.Point(796, 166);
this.label9.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label9.Name = "label9";
this.label9.Size = new System.Drawing.Size(82, 15);
this.label9.TabIndex = 55;
this.label9.Text = "测试界面:";
//
// FormComboBox
//
this.FormComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.FormComboBox.FormattingEnabled = true;
this.FormComboBox.Location = new System.Drawing.Point(799, 205);
this.FormComboBox.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.FormComboBox.Name = "FormComboBox";
this.FormComboBox.Size = new System.Drawing.Size(160, 23);
this.FormComboBox.TabIndex = 56;
//
// label10
//
this.label10.AutoSize = true;
this.label10.Location = new System.Drawing.Point(16, 301);
this.label10.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label10.Name = "label10";
this.label10.Size = new System.Drawing.Size(69, 15);
this.label10.TabIndex = 57;
this.label10.Text = "SAP名称:";
//
// SAPName
//
this.SAPName.Enabled = false;
this.SAPName.Location = new System.Drawing.Point(129, 298);
this.SAPName.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.SAPName.Multiline = true;
this.SAPName.Name = "SAPName";
this.SAPName.Size = new System.Drawing.Size(196, 54);
this.SAPName.TabIndex = 58;
//
// label15
//
this.label15.AutoSize = true;
this.label15.Location = new System.Drawing.Point(16, 256);
this.label15.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label15.Name = "label15";
this.label15.Size = new System.Drawing.Size(76, 15);
this.label15.TabIndex = 59;
this.label15.Text = "SAP编号:";
//
// SAPBH
//
this.SAPBH.Enabled = false;
this.SAPBH.Location = new System.Drawing.Point(129, 252);
this.SAPBH.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.SAPBH.Name = "SAPBH";
this.SAPBH.Size = new System.Drawing.Size(193, 25);
this.SAPBH.TabIndex = 60;
//
// label20
//
this.label20.AutoSize = true;
this.label20.Location = new System.Drawing.Point(13, 214);
this.label20.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label20.Name = "label20";
this.label20.Size = new System.Drawing.Size(91, 15);
this.label20.TabIndex = 61;
this.label20.Text = "SAP订单号:";
//
// SAPDDH
//
this.SAPDDH.Enabled = false;
this.SAPDDH.Location = new System.Drawing.Point(129, 210);
this.SAPDDH.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.SAPDDH.Name = "SAPDDH";
this.SAPDDH.Size = new System.Drawing.Size(196, 25);
this.SAPDDH.TabIndex = 62;
//
// XMLComboBox
//
this.XMLComboBox.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.XMLComboBox.FormattingEnabled = true;
this.XMLComboBox.Items.AddRange(new object[] {
"整机",
"电源板单板",
"WIFI板单板"});
this.XMLComboBox.Location = new System.Drawing.Point(799, 91);
this.XMLComboBox.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.XMLComboBox.Name = "XMLComboBox";
this.XMLComboBox.Size = new System.Drawing.Size(160, 23);
this.XMLComboBox.TabIndex = 64;
this.XMLComboBox.SelectedIndexChanged += new System.EventHandler(this.XMLComboBox_SelectedIndexChanged);
//
// label21
//
this.label21.AutoSize = true;
this.label21.Location = new System.Drawing.Point(796, 52);
this.label21.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label21.Name = "label21";
this.label21.Size = new System.Drawing.Size(82, 15);
this.label21.TabIndex = 63;
this.label21.Text = "测试阶段:";
//
// btnLogWindow
//
this.btnLogWindow.Location = new System.Drawing.Point(799, 519);
this.btnLogWindow.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.btnLogWindow.Name = "btnLogWindow";
this.btnLogWindow.Size = new System.Drawing.Size(100, 29);
this.btnLogWindow.TabIndex = 65;
this.btnLogWindow.Text = "日志";
this.btnLogWindow.UseVisualStyleBackColor = true;
//
// btnConfigSerialPort
//
this.btnConfigSerialPort.Location = new System.Drawing.Point(799, 295);
this.btnConfigSerialPort.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.btnConfigSerialPort.Name = "btnConfigSerialPort";
this.btnConfigSerialPort.Size = new System.Drawing.Size(100, 36);
this.btnConfigSerialPort.TabIndex = 66;
this.btnConfigSerialPort.Text = "串口设置";
this.btnConfigSerialPort.UseVisualStyleBackColor = true;
//
// comboBox1
//
this.comboBox1.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.comboBox1.FormattingEnabled = true;
this.comboBox1.Items.AddRange(new object[] {
"1*1",
"1*2",
"2*2",
"2*3",
"2*4",
"2*5"});
this.comboBox1.Location = new System.Drawing.Point(555, 456);
this.comboBox1.Margin = new System.Windows.Forms.Padding(4);
this.comboBox1.Name = "comboBox1";
this.comboBox1.Size = new System.Drawing.Size(147, 23);
this.comboBox1.TabIndex = 68;
//
// label22
//
this.label22.AutoSize = true;
this.label22.Location = new System.Drawing.Point(416, 456);
this.label22.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label22.Name = "label22";
this.label22.Size = new System.Drawing.Size(82, 15);
this.label22.TabIndex = 67;
this.label22.Text = "界面布局:";
//
// Configure
//
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(1067, 611);
this.Controls.Add(this.comboBox1);
this.Controls.Add(this.label22);
this.Controls.Add(this.btnConfigSerialPort);
this.Controls.Add(this.btnLogWindow);
this.Controls.Add(this.XMLComboBox);
this.Controls.Add(this.label21);
this.Controls.Add(this.SAPDDH);
this.Controls.Add(this.label20);
this.Controls.Add(this.SAPBH);
this.Controls.Add(this.label15);
this.Controls.Add(this.SAPName);
this.Controls.Add(this.label10);
this.Controls.Add(this.FormComboBox);
this.Controls.Add(this.label9);
this.Controls.Add(this.productID);
this.Controls.Add(this.label8);
this.Controls.Add(this.HVNumber);
this.Controls.Add(this.label7);
this.Controls.Add(this.factoryLineIdText);
this.Controls.Add(this.factoryIdText);
this.Controls.Add(this.label6);
this.Controls.Add(this.label3);
this.Controls.Add(this.DevNameText);
this.Controls.Add(this.label1);
this.Controls.Add(this.ConfigureText);
this.Controls.Add(this.BackToLoad);
this.Controls.Add(this.LowA);
this.Controls.Add(this.HighA);
this.Controls.Add(this.LowPower);
this.Controls.Add(this.label19);
this.Controls.Add(this.label18);
this.Controls.Add(this.label17);
this.Controls.Add(this.HighPower);
this.Controls.Add(this.label16);
this.Controls.Add(this.SerialSlogan2);
this.Controls.Add(this.label14);
this.Controls.Add(this.RSSIText);
this.Controls.Add(this.label13);
this.Controls.Add(this.SerialSlogan1);
this.Controls.Add(this.label12);
this.Controls.Add(this.label11);
this.Controls.Add(this.SSIDName);
this.Controls.Add(this.SVNumber);
this.Controls.Add(this.ProductModel);
this.Controls.Add(this.DEVName);
this.Controls.Add(this.label5);
this.Controls.Add(this.label4);
this.Controls.Add(this.label2);
this.Controls.Add(this.ConfigureOK);
//this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.Margin = new System.Windows.Forms.Padding(4, 4, 4, 4);
this.Name = "Configure";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
this.Text = "配置界面";
this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.Configure_Closing);
this.Load += new System.EventHandler(this.Configure_Load);
this.Resize += new System.EventHandler(this.Configure_Resize);
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.Button ConfigureOK;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.Label label4;
private System.Windows.Forms.Label label5;
private System.Windows.Forms.ComboBox DEVName;
private System.Windows.Forms.TextBox ProductModel;
private System.Windows.Forms.TextBox SVNumber;
private System.Windows.Forms.TextBox SSIDName;
private System.Windows.Forms.Label label11;
private System.Windows.Forms.Label label12;
private System.Windows.Forms.ComboBox SerialSlogan1;
private System.Windows.Forms.Label label13;
private System.Windows.Forms.TextBox RSSIText;
private System.Windows.Forms.Label label14;
private System.Windows.Forms.ComboBox SerialSlogan2;
private System.Windows.Forms.Label label16;
private System.Windows.Forms.TextBox HighPower;
private System.Windows.Forms.Label label17;
private System.Windows.Forms.Label label18;
private System.Windows.Forms.Label label19;
private System.Windows.Forms.TextBox LowPower;
private System.Windows.Forms.TextBox HighA;
private System.Windows.Forms.TextBox LowA;
private System.Windows.Forms.Button BackToLoad;
private System.Windows.Forms.Label ConfigureText;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.TextBox DevNameText;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.Label label6;
private System.Windows.Forms.TextBox factoryIdText;
private System.Windows.Forms.TextBox factoryLineIdText;
private System.Windows.Forms.Label label7;
private System.Windows.Forms.TextBox HVNumber;
private System.Windows.Forms.Label label8;
private System.Windows.Forms.TextBox productID;
private System.Windows.Forms.Label label9;
private System.Windows.Forms.ComboBox FormComboBox;
private System.Windows.Forms.Label label10;
private System.Windows.Forms.TextBox SAPName;
private System.Windows.Forms.Label label15;
private System.Windows.Forms.TextBox SAPBH;
private System.Windows.Forms.Label label20;
private System.Windows.Forms.TextBox SAPDDH;
private System.Windows.Forms.ComboBox XMLComboBox;
private System.Windows.Forms.Label label21;
private System.Windows.Forms.Button btnLogWindow;
private System.Windows.Forms.Button btnConfigSerialPort;
private System.Windows.Forms.ComboBox comboBox1;
private System.Windows.Forms.Label label22;
}
}
\ No newline at end of file
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace KonkeDemo
{
public partial class Configure : Form
{
public static Configure Configure_interface = null;
private string MyDepartment = "";//工厂信息
public string MyToolName = "";
public Configure()
{
InitializeComponent();
Configure_interface = this;
MyDepartment = LoadForm.Load_interface.GetRootDepartment();
InitControl();
}
private void InitControl()
{
btnConfigSerialPort.Click += BtnConfigSerialPort_Click;
btnConfigSerialPort.Visible = false;
FormComboBox.SelectedValueChanged += FormComboBox_SelectedValueChanged;
}
private void BtnConfigSerialPort_Click(object sender, EventArgs e)
{
try
{
}
catch (Exception ex)
{
MessageBox.Show("串口设置失败:" + ex.ToString());
}
}
#region 传递值
public string GetTempbatchNumber() //传递sap订单号
{
//return DEVName.Text;
return SAPDDH.Text.ToUpper();
}
public string GetMySAPB() //传递SAP编号
{
return SAPBH.Text.ToUpper();
}
public string GetMyToolName()
{
return MyToolName;
}
public string GetTempfactoryId() //传递工厂ID
{
return factoryIdText.Text;
}
public string GetTempfactoryLineId() //传递产线ID
{
return factoryLineIdText.Text;
}
public string GetProductModel() //传递设备型号
{
return ProductModel.Text;
}
public string GetProductName() //传递设备名称
{
return DevNameText.Text;
}
public string GetTempSVNumber() //传递sv
{
return SVNumber.Text;
}
public string GetTempHVNumber() //传递hv
{
return HVNumber.Text;
}
public string GetSerialSlogan1() //传递辅助串口1
{
return SerialSlogan1.Text;
}
public string GetproductID() //传递产品ID
{
return productID.Text;
}
public string GetMyRssi() //传递RSSI
{
return RSSIText.Text;
}
public int GetMyPowerH() //传递Power
{
string MyhighP = System.Text.RegularExpressions.Regex.Replace(HighPower.Text, @"[^0-9]+", "");
return Convert.ToInt16(MyhighP);
}
public int GetMyPowerL() //传递Power
{
string MyLowP = System.Text.RegularExpressions.Regex.Replace(LowPower.Text, @"[^0-9]+", "");
return Convert.ToInt16(MyLowP);
}
public string GetMyForm() //传递界面
{
return FormComboBox.Text;
}
public string GetJHH() //传递计划号
{
//return DEVName.Text;
return SAPDDH.Text.ToUpper();
}
public string GetWIFIName() //传递wifi名称
{
return SSIDName.Text;
}
public string GetLayout()
{
return comboBox1.Text;
}
#endregion
#region 窗口最大化控件变化
ControlChangesWithWindows ConfigureWindows = new ControlChangesWithWindows(); //随窗口改变大小类的实例化
private static int ConfigureColseAll = 1; //是否关闭所有窗口 1-关闭所有 0-关闭当前
//将控件的宽,高,左边距,顶边距和字体大小暂存到tag属性中
private void Configure_Load(object sender, EventArgs e)
{
try
{
btnLogWindow.Click += ConsoleShow_Click;
ConfigureWindows.MethodForLoad(this);//调用方法
}
catch (Exception ex)
{
MessageBox.Show("界面Load-操作失败:" + ex.ToString());
}
}
//根据窗体大小调整控件大小
private void Configure_Resize(object sender, EventArgs e)
{
try
{
int Width = this.Width;
int Height = this.Height;
if (Width >= 816 && Height >= 528)
{
this.AutoScroll = false;
ConfigureWindows.MethodForResize(this);//
}
else
this.AutoScroll = true;
}
catch (Exception ex)
{
MessageBox.Show("窗口改变大小-操作失败:" + ex.ToString());
}
}
#endregion
#region 页面切换
private void BackToLoad_Click(object sender, EventArgs e)
{
ConfigureColseAll = 0;
this.Close();
}
private void SerialSlogan1_MouseClick(object sender, MouseEventArgs e)
{
}
private void SerialSlogan2_MouseClick(object sender, MouseEventArgs e)
{
}
#endregion
#region 事件
//关闭时显示登陆界面
private void Configure_Closing(object sender, FormClosingEventArgs e)
{
try
{
if (ConfigureColseAll == 1)
System.Environment.Exit(0);
else
{
ConfigureColseAll = 1;
this.DialogResult = DialogResult.OK;
}
}
catch (Exception ex)
{
MessageBox.Show("操作界面关闭-操作失败:" + ex.ToString());
}
}
//点击确定,进入测试界面
private void ConfigureOK_Click(object sender, EventArgs e)
{
try
{
ConfigureText.Visible = false;
CreatePvtForm();
//验证正确,登陆配置界面
this.Hide(); //隐藏主界面
FormMain FCTest = new FormMain();
if (FCTest.ShowDialog() == DialogResult.OK) //以对话框形式显示配置界面
{
this.Show(); //显示主界面
}
}
catch (Exception ex)
{
MessageBox.Show("确定按钮-操作失败:" + ex.ToString());
}
}
private void DEVName_SelectedIndexChanged(object sender, EventArgs e)
{
GetSelectedItem();
}
private void GetSelectedItem()
{
try
{
if (DEVName.Text.Contains("请选择"))
{
return;
}
}
catch (Exception ex)
{
MessageBox.Show("选择工单-操作失败:" + ex.ToString());
}
}
#endregion
#region 测试阶段 + 测试界面的配置选择
private void XMLComboBox_SelectedIndexChanged(object sender, EventArgs e)
{
BindProcessStepOption();
}
private void BindProcessStepOption(string Str = "")
{
FormComboBox.Items.Clear();
if (Str == "")
Str = XMLComboBox.Text;
}
private void FormComboBox_SelectedValueChanged(object sender, EventArgs e)
{
CreatePvtForm();
}
private void CreatePvtForm()
{
}
#endregion
private void DEVName_TextChanged(object sender, EventArgs e)
{
//Console.WriteLine("DEVName_TextChanged:{0}, [SelectedValue:{1}]", DEVName.Text, UtilControlDataBind.GetSelectedItemValue(DEVName));
GetSelectedItem();
}
private void ConsoleShow_Click(object sender, EventArgs e)
{
}
}
}
This source diff could not be displayed because it is too large. You can view the blob instead.
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace KonkeDemo
{
public partial class FormConfigure : Form
{
private BaseConfig newbaseConfig;
public FormConfigure()
{
InitializeComponent();
}
public FormConfigure(BaseConfig baseConfig)
{
InitializeComponent();
this.newbaseConfig = baseConfig;
}
}
}
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>
\ No newline at end of file
namespace KonkeDemo
{
partial class FormMain
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.panel1 = new System.Windows.Forms.Panel();
this.ucBtnExt3 = new HZH_Controls.Controls.UCBtnExt();
this.ucBtnExt4 = new HZH_Controls.Controls.UCBtnExt();
this.textEdit4 = new DevExpress.XtraEditors.TextEdit();
this.textEdit3 = new DevExpress.XtraEditors.TextEdit();
this.textEdit2 = new DevExpress.XtraEditors.TextEdit();
this.textEdit1 = new DevExpress.XtraEditors.TextEdit();
this.labelControl5 = new DevExpress.XtraEditors.LabelControl();
this.labelControl4 = new DevExpress.XtraEditors.LabelControl();
this.labelControl3 = new DevExpress.XtraEditors.LabelControl();
this.ucBtnExt2 = new HZH_Controls.Controls.UCBtnExt();
this.ucBtnExt1 = new HZH_Controls.Controls.UCBtnExt();
this.labelControl1 = new DevExpress.XtraEditors.LabelControl();
this.panel2 = new System.Windows.Forms.Panel();
this.panel1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.textEdit4.Properties)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.textEdit3.Properties)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.textEdit2.Properties)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.textEdit1.Properties)).BeginInit();
this.SuspendLayout();
//
// panel1
//
this.panel1.BackColor = System.Drawing.Color.Cyan;
this.panel1.Controls.Add(this.ucBtnExt3);
this.panel1.Controls.Add(this.ucBtnExt4);
this.panel1.Controls.Add(this.textEdit4);
this.panel1.Controls.Add(this.textEdit3);
this.panel1.Controls.Add(this.textEdit2);
this.panel1.Controls.Add(this.textEdit1);
this.panel1.Controls.Add(this.labelControl5);
this.panel1.Controls.Add(this.labelControl4);
this.panel1.Controls.Add(this.labelControl3);
this.panel1.Controls.Add(this.ucBtnExt2);
this.panel1.Controls.Add(this.ucBtnExt1);
this.panel1.Controls.Add(this.labelControl1);
this.panel1.Dock = System.Windows.Forms.DockStyle.Top;
this.panel1.Location = new System.Drawing.Point(0, 0);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(1663, 136);
this.panel1.TabIndex = 3;
//
// ucBtnExt3
//
this.ucBtnExt3.BackColor = System.Drawing.Color.White;
this.ucBtnExt3.BtnBackColor = System.Drawing.Color.White;
this.ucBtnExt3.BtnFont = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.ucBtnExt3.BtnForeColor = System.Drawing.Color.White;
this.ucBtnExt3.BtnText = "帮助";
this.ucBtnExt3.ConerRadius = 5;
this.ucBtnExt3.Cursor = System.Windows.Forms.Cursors.Hand;
this.ucBtnExt3.EnabledMouseEffect = false;
this.ucBtnExt3.FillColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(192)))), ((int)(((byte)(255)))));
this.ucBtnExt3.Font = new System.Drawing.Font("微软雅黑", 15F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Pixel);
this.ucBtnExt3.IsRadius = true;
this.ucBtnExt3.IsShowRect = true;
this.ucBtnExt3.IsShowTips = false;
this.ucBtnExt3.Location = new System.Drawing.Point(1411, 71);
this.ucBtnExt3.Margin = new System.Windows.Forms.Padding(0);
this.ucBtnExt3.Name = "ucBtnExt3";
this.ucBtnExt3.RectColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(77)))), ((int)(((byte)(58)))));
this.ucBtnExt3.RectWidth = 1;
this.ucBtnExt3.Size = new System.Drawing.Size(150, 46);
this.ucBtnExt3.TabIndex = 29;
this.ucBtnExt3.TabStop = false;
this.ucBtnExt3.TipsColor = System.Drawing.Color.FromArgb(((int)(((byte)(232)))), ((int)(((byte)(30)))), ((int)(((byte)(99)))));
this.ucBtnExt3.TipsText = "";
this.ucBtnExt3.BtnClick += new System.EventHandler(this.ucBtnExt3_BtnClick);
//
// ucBtnExt4
//
this.ucBtnExt4.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(77)))), ((int)(((byte)(59)))));
this.ucBtnExt4.BtnBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(77)))), ((int)(((byte)(59)))));
this.ucBtnExt4.BtnFont = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.ucBtnExt4.BtnForeColor = System.Drawing.Color.White;
this.ucBtnExt4.BtnText = "配置";
this.ucBtnExt4.ConerRadius = 5;
this.ucBtnExt4.Cursor = System.Windows.Forms.Cursors.Hand;
this.ucBtnExt4.EnabledMouseEffect = false;
this.ucBtnExt4.FillColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(192)))), ((int)(((byte)(255)))));
this.ucBtnExt4.Font = new System.Drawing.Font("微软雅黑", 15F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Pixel);
this.ucBtnExt4.IsRadius = true;
this.ucBtnExt4.IsShowRect = true;
this.ucBtnExt4.IsShowTips = false;
this.ucBtnExt4.Location = new System.Drawing.Point(1411, 11);
this.ucBtnExt4.Margin = new System.Windows.Forms.Padding(0);
this.ucBtnExt4.Name = "ucBtnExt4";
this.ucBtnExt4.RectColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(77)))), ((int)(((byte)(58)))));
this.ucBtnExt4.RectWidth = 1;
this.ucBtnExt4.Size = new System.Drawing.Size(150, 46);
this.ucBtnExt4.TabIndex = 28;
this.ucBtnExt4.TabStop = false;
this.ucBtnExt4.Tag = "";
this.ucBtnExt4.TipsColor = System.Drawing.Color.FromArgb(((int)(((byte)(232)))), ((int)(((byte)(30)))), ((int)(((byte)(99)))));
this.ucBtnExt4.TipsText = "";
this.ucBtnExt4.BtnClick += new System.EventHandler(this.ucBtnExt4_BtnClick);
//
// textEdit4
//
this.textEdit4.Enabled = false;
this.textEdit4.Location = new System.Drawing.Point(984, 87);
this.textEdit4.Name = "textEdit4";
this.textEdit4.Size = new System.Drawing.Size(219, 25);
this.textEdit4.TabIndex = 27;
//
// textEdit3
//
this.textEdit3.Enabled = false;
this.textEdit3.Location = new System.Drawing.Point(984, 50);
this.textEdit3.Name = "textEdit3";
this.textEdit3.Size = new System.Drawing.Size(219, 25);
this.textEdit3.TabIndex = 26;
//
// textEdit2
//
this.textEdit2.Enabled = false;
this.textEdit2.Location = new System.Drawing.Point(984, 10);
this.textEdit2.Name = "textEdit2";
this.textEdit2.Size = new System.Drawing.Size(219, 25);
this.textEdit2.TabIndex = 25;
//
// textEdit1
//
this.textEdit1.Location = new System.Drawing.Point(118, 46);
this.textEdit1.Name = "textEdit1";
this.textEdit1.Size = new System.Drawing.Size(283, 25);
this.textEdit1.TabIndex = 24;
this.textEdit1.KeyUp += new System.Windows.Forms.KeyEventHandler(this.textEdit1_KeyUp);
//
// labelControl5
//
this.labelControl5.Location = new System.Drawing.Point(867, 90);
this.labelControl5.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.labelControl5.Name = "labelControl5";
this.labelControl5.Size = new System.Drawing.Size(60, 18);
this.labelControl5.TabIndex = 23;
this.labelControl5.Text = "通过数量";
//
// labelControl4
//
this.labelControl4.Location = new System.Drawing.Point(867, 53);
this.labelControl4.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.labelControl4.Name = "labelControl4";
this.labelControl4.Size = new System.Drawing.Size(60, 18);
this.labelControl4.TabIndex = 22;
this.labelControl4.Text = "工单数量";
//
// labelControl3
//
this.labelControl3.Location = new System.Drawing.Point(867, 13);
this.labelControl3.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.labelControl3.Name = "labelControl3";
this.labelControl3.Size = new System.Drawing.Size(45, 18);
this.labelControl3.TabIndex = 21;
this.labelControl3.Text = "工单号";
//
// ucBtnExt2
//
this.ucBtnExt2.BackColor = System.Drawing.Color.White;
this.ucBtnExt2.BtnBackColor = System.Drawing.Color.White;
this.ucBtnExt2.BtnFont = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.ucBtnExt2.BtnForeColor = System.Drawing.Color.White;
this.ucBtnExt2.BtnText = "重置";
this.ucBtnExt2.ConerRadius = 5;
this.ucBtnExt2.Cursor = System.Windows.Forms.Cursors.Hand;
this.ucBtnExt2.EnabledMouseEffect = false;
this.ucBtnExt2.FillColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(192)))), ((int)(((byte)(255)))));
this.ucBtnExt2.Font = new System.Drawing.Font("微软雅黑", 15F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Pixel);
this.ucBtnExt2.IsRadius = true;
this.ucBtnExt2.IsShowRect = true;
this.ucBtnExt2.IsShowTips = false;
this.ucBtnExt2.Location = new System.Drawing.Point(531, 70);
this.ucBtnExt2.Margin = new System.Windows.Forms.Padding(0);
this.ucBtnExt2.Name = "ucBtnExt2";
this.ucBtnExt2.RectColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(77)))), ((int)(((byte)(58)))));
this.ucBtnExt2.RectWidth = 1;
this.ucBtnExt2.Size = new System.Drawing.Size(164, 46);
this.ucBtnExt2.TabIndex = 20;
this.ucBtnExt2.TabStop = false;
this.ucBtnExt2.TipsColor = System.Drawing.Color.FromArgb(((int)(((byte)(232)))), ((int)(((byte)(30)))), ((int)(((byte)(99)))));
this.ucBtnExt2.TipsText = "";
this.ucBtnExt2.BtnClick += new System.EventHandler(this.ucBtnExt2_BtnClick);
//
// ucBtnExt1
//
this.ucBtnExt1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(77)))), ((int)(((byte)(59)))));
this.ucBtnExt1.BtnBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(77)))), ((int)(((byte)(59)))));
this.ucBtnExt1.BtnFont = new System.Drawing.Font("微软雅黑", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134)));
this.ucBtnExt1.BtnForeColor = System.Drawing.Color.White;
this.ucBtnExt1.BtnText = "开始";
this.ucBtnExt1.ConerRadius = 5;
this.ucBtnExt1.Cursor = System.Windows.Forms.Cursors.Hand;
this.ucBtnExt1.EnabledMouseEffect = false;
this.ucBtnExt1.FillColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(192)))), ((int)(((byte)(255)))));
this.ucBtnExt1.Font = new System.Drawing.Font("微软雅黑", 15F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Pixel);
this.ucBtnExt1.IsRadius = true;
this.ucBtnExt1.IsShowRect = true;
this.ucBtnExt1.IsShowTips = false;
this.ucBtnExt1.Location = new System.Drawing.Point(531, 10);
this.ucBtnExt1.Margin = new System.Windows.Forms.Padding(0);
this.ucBtnExt1.Name = "ucBtnExt1";
this.ucBtnExt1.RectColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(77)))), ((int)(((byte)(58)))));
this.ucBtnExt1.RectWidth = 1;
this.ucBtnExt1.Size = new System.Drawing.Size(164, 46);
this.ucBtnExt1.TabIndex = 19;
this.ucBtnExt1.TabStop = false;
this.ucBtnExt1.Tag = "";
this.ucBtnExt1.TipsColor = System.Drawing.Color.FromArgb(((int)(((byte)(232)))), ((int)(((byte)(30)))), ((int)(((byte)(99)))));
this.ucBtnExt1.TipsText = "";
this.ucBtnExt1.BtnClick += new System.EventHandler(this.ucBtnExt1_BtnClick);
//
// labelControl1
//
this.labelControl1.Location = new System.Drawing.Point(23, 49);
this.labelControl1.Margin = new System.Windows.Forms.Padding(3, 2, 3, 2);
this.labelControl1.Name = "labelControl1";
this.labelControl1.Size = new System.Drawing.Size(60, 18);
this.labelControl1.TabIndex = 18;
this.labelControl1.Text = "扫入数据";
//
// panel2
//
this.panel2.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel2.Location = new System.Drawing.Point(0, 136);
this.panel2.Name = "panel2";
this.panel2.Size = new System.Drawing.Size(1663, 571);
this.panel2.TabIndex = 4;
//
// FormMain
//
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(1663, 707);
this.Controls.Add(this.panel2);
this.Controls.Add(this.panel1);
this.Name = "FormMain";
this.Text = "Form7";
this.WindowState = System.Windows.Forms.FormWindowState.Maximized;
this.Load += new System.EventHandler(this.Form7_Load);
this.Resize += new System.EventHandler(this.FormMain_Resize);
this.panel1.ResumeLayout(false);
this.panel1.PerformLayout();
((System.ComponentModel.ISupportInitialize)(this.textEdit4.Properties)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.textEdit3.Properties)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.textEdit2.Properties)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.textEdit1.Properties)).EndInit();
this.ResumeLayout(false);
}
#endregion
//private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
private System.Windows.Forms.Panel panel1;
private DevExpress.XtraEditors.TextEdit textEdit4;
private DevExpress.XtraEditors.TextEdit textEdit3;
private DevExpress.XtraEditors.TextEdit textEdit2;
private DevExpress.XtraEditors.TextEdit textEdit1;
private DevExpress.XtraEditors.LabelControl labelControl5;
private DevExpress.XtraEditors.LabelControl labelControl4;
private DevExpress.XtraEditors.LabelControl labelControl3;
private HZH_Controls.Controls.UCBtnExt ucBtnExt2;
private HZH_Controls.Controls.UCBtnExt ucBtnExt1;
private DevExpress.XtraEditors.LabelControl labelControl1;
private HZH_Controls.Controls.UCBtnExt ucBtnExt3;
private HZH_Controls.Controls.UCBtnExt ucBtnExt4;
private System.Windows.Forms.Panel panel2;
}
}
\ No newline at end of file
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Diagnostics;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace KonkeDemo
{
public partial class FormMain : Form
{
ControlChangesWithWindows LoadFormWindows = new ControlChangesWithWindows(); //随窗口改变大小类的实例化
private ConcurrentDictionary<int, UserControlmodular> ModularDictionary = new ConcurrentDictionary<int, UserControlmodular>();//双向链表
public FormMain()
{
InitializeComponent();
}
private void UIfresh()
{
this.WindowState = FormWindowState.Maximized;
string Layout = Configure.Configure_interface.GetLayout();
System.Windows.Forms.TableLayoutPanel tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
tableLayoutPanel1.AutoScroll = true;
tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
tableLayoutPanel1.Name = "tableLayoutPanel1";
tableLayoutPanel1.Size = new System.Drawing.Size(1663, 571);
tableLayoutPanel1.TabIndex = 2;
panel2.Controls.Add(tableLayoutPanel1);
int iColumnCount = 3;
int iRowCount = 2;
iRowCount = int.Parse(Layout.Split(new string[] { "*" }, StringSplitOptions.RemoveEmptyEntries)[0]);
iColumnCount = int.Parse(Layout.Split(new string[] { "*" }, StringSplitOptions.RemoveEmptyEntries)[1]);
tableLayoutPanel1.ColumnCount = iColumnCount;
tableLayoutPanel1.RowCount = iRowCount;
UserControlmodular usermodular = new UserControlmodular();
float width = this.Width / iColumnCount;
if (width >= usermodular.Width)
{
for (int i = 0; i < iColumnCount; i++)
{
tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
}
}
else
{
for (int i = 0; i < iColumnCount; i++)
{
tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, usermodular.Width));
}
}
for (int k = 0; k < iRowCount; k++)
{
tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, usermodular.Height));
}
int position = 0;
for (int i = 0; i < iRowCount; i++)
{
for (int j = 0; j < iColumnCount; j++)
{
usermodular = new UserControlmodular();
usermodular.BackColor = System.Drawing.Color.Aqua;
usermodular.Process = 0;
usermodular.iconclusion = 2;
usermodular.position = (++position);
usermodular.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
usermodular.Dock = System.Windows.Forms.DockStyle.Fill;
tableLayoutPanel1.Controls.Add(usermodular, j, i);
ModularDictionary.TryAdd(position, usermodular);
}
}
}
private void Form7_Load(object sender, EventArgs e)
{
UIfresh();
}
private void ucBtnExt3_BtnClick(object sender, EventArgs e)
{
Process.Start(AppDomain.CurrentDomain.BaseDirectory.ToString() + "Beacon.chm");
}
private void FormMain_Resize(object sender, EventArgs e)
{
LoadFormWindows.MethodForResize(this);
}
private void FillSN()
{
for (int i = 0; i < ModularDictionary.Count; i++)
{
if (string.IsNullOrEmpty(ModularDictionary[i + 1].SN))
{
ModularDictionary[i + 1].SN = textEdit1.Text.Trim();
textEdit1.Text = "";
break;
}
}
}
private void checkSN(out string ErrorMessage)
{
string errorlog = "";
for (int i = 0; i < ModularDictionary.Count; i++)
{
if (string.IsNullOrEmpty(ModularDictionary[i + 1].SN))
{
errorlog = string.Format("工站{0}请输入SN", i + 1);
break;
}
}
ErrorMessage = errorlog;
}
private void textEdit1_KeyUp(object sender, KeyEventArgs e)
{
if (e.KeyCode == Keys.Enter)
FillSN();
}
private void ucBtnExt2_BtnClick(object sender, EventArgs e)
{
for (int i = 0; i < ModularDictionary.Count; i++)
{
ModularDictionary[i + 1].SN = "";
}
}
private void ucBtnExt1_BtnClick(object sender, EventArgs e)
{
if (ucBtnExt1.BtnText == "开始")
{
string ErrorMessage = "";
checkSN(out ErrorMessage);
if (string.IsNullOrEmpty(ErrorMessage))
{
ucBtnExt1.BtnText = "停止";
textEdit1.Enabled = false;
ucBtnExt2.Enabled = false;
ucBtnExt4.Enabled = false;
ucBtnExt3.Enabled = false;
AutoTestService autoTestService = new AutoTestService(ModularDictionary);
autoTestService.Run(null);
ucBtnExt1.BtnText = "开始";
ucBtnExt2.Enabled = true;
ucBtnExt4.Enabled = true;
ucBtnExt3.Enabled = true;
textEdit1.Enabled = true;
}
else
{
MessageBox.Show(ErrorMessage);
}
}
else if (ucBtnExt1.BtnText == "停止")
{
AutoTestService autoTest = new AutoTestService();
autoTest.Stop();
ucBtnExt1.BtnText = "开始";
ucBtnExt2.Enabled = true;
ucBtnExt4.Enabled = true;
ucBtnExt3.Enabled = true;
}
}
private void ucBtnExt4_BtnClick(object sender, EventArgs e)
{
AutoTestService autoTest = new AutoTestService();
BaseConfig baseConfig = autoTest.GetConfig();
FormConfigure configure = new FormConfigure();
if (configure.ShowDialog(this) == DialogResult.OK)
{
autoTest.SetConfig(baseConfig);
}
}
}
}
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>
\ No newline at end of file
namespace KonkeDemo
{
partial class LoadForm
{
/// <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()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(LoadForm));
this.label1 = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label();
this.PassnameText = new System.Windows.Forms.TextBox();
this.PasswordText = new System.Windows.Forms.TextBox();
this.LoadButton = new System.Windows.Forms.Button();
this.LoadErrorText = new System.Windows.Forms.Label();
this.pictureBox1 = new System.Windows.Forms.PictureBox();
this.SignOut = new System.Windows.Forms.Button();
this.LoadTextShow = new System.Windows.Forms.Label();
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
this.SuspendLayout();
//
// label1
//
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(455, 86);
this.label1.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(52, 15);
this.label1.TabIndex = 0;
this.label1.Text = "账号:";
//
// label2
//
this.label2.AutoSize = true;
this.label2.Location = new System.Drawing.Point(455, 154);
this.label2.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(52, 15);
this.label2.TabIndex = 1;
this.label2.Text = "密码:";
//
// PassnameText
//
this.PassnameText.BackColor = System.Drawing.Color.Lavender;
this.PassnameText.Location = new System.Drawing.Point(547, 82);
this.PassnameText.Margin = new System.Windows.Forms.Padding(4);
this.PassnameText.Name = "PassnameText";
this.PassnameText.Size = new System.Drawing.Size(191, 25);
this.PassnameText.TabIndex = 2;
this.PassnameText.Text = "surukun";
this.PassnameText.KeyUp += new System.Windows.Forms.KeyEventHandler(this.PassNameEnter);
//
// PasswordText
//
this.PasswordText.BackColor = System.Drawing.Color.Lavender;
this.PasswordText.Location = new System.Drawing.Point(547, 142);
this.PasswordText.Margin = new System.Windows.Forms.Padding(4);
this.PasswordText.Name = "PasswordText";
this.PasswordText.PasswordChar = '*';
this.PasswordText.Size = new System.Drawing.Size(191, 25);
this.PasswordText.TabIndex = 3;
this.PasswordText.Text = "123456";
this.PasswordText.KeyUp += new System.Windows.Forms.KeyEventHandler(this.PassWordEnter);
//
// LoadButton
//
this.LoadButton.Location = new System.Drawing.Point(457, 290);
this.LoadButton.Margin = new System.Windows.Forms.Padding(4);
this.LoadButton.Name = "LoadButton";
this.LoadButton.Size = new System.Drawing.Size(99, 39);
this.LoadButton.TabIndex = 6;
this.LoadButton.Text = "登陆";
this.LoadButton.UseVisualStyleBackColor = true;
this.LoadButton.Click += new System.EventHandler(this.LoadButton_Click);
//
// LoadErrorText
//
this.LoadErrorText.AutoSize = true;
this.LoadErrorText.ForeColor = System.Drawing.Color.Red;
this.LoadErrorText.Location = new System.Drawing.Point(455, 244);
this.LoadErrorText.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.LoadErrorText.Name = "LoadErrorText";
this.LoadErrorText.Size = new System.Drawing.Size(157, 15);
this.LoadErrorText.TabIndex = 7;
this.LoadErrorText.Text = "账号不存在或密码错误";
this.LoadErrorText.Visible = false;
//
// pictureBox1
//
//this.pictureBox1.Image = global::WindowsFormsApp7.Properties.Resources.KongKe;
this.pictureBox1.Location = new System.Drawing.Point(72, 71);
this.pictureBox1.Margin = new System.Windows.Forms.Padding(4);
this.pictureBox1.Name = "pictureBox1";
this.pictureBox1.Size = new System.Drawing.Size(257, 258);
this.pictureBox1.TabIndex = 8;
this.pictureBox1.TabStop = false;
//
// SignOut
//
this.SignOut.Location = new System.Drawing.Point(640, 290);
this.SignOut.Margin = new System.Windows.Forms.Padding(4);
this.SignOut.Name = "SignOut";
this.SignOut.Size = new System.Drawing.Size(99, 39);
this.SignOut.TabIndex = 9;
this.SignOut.Text = "退出";
this.SignOut.UseVisualStyleBackColor = true;
this.SignOut.Click += new System.EventHandler(this.SignOut_Click);
//
// LoadTextShow
//
this.LoadTextShow.AutoSize = true;
this.LoadTextShow.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0)))));
this.LoadTextShow.Location = new System.Drawing.Point(544, 190);
this.LoadTextShow.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
this.LoadTextShow.Name = "LoadTextShow";
this.LoadTextShow.Size = new System.Drawing.Size(160, 15);
this.LoadTextShow.TabIndex = 10;
this.LoadTextShow.Text = "登陆中,请等待......";
this.LoadTextShow.Visible = false;
//
// LoadForm
//
this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.BackColor = System.Drawing.Color.Lavender;
this.ClientSize = new System.Drawing.Size(801, 431);
this.Controls.Add(this.LoadTextShow);
this.Controls.Add(this.SignOut);
this.Controls.Add(this.pictureBox1);
this.Controls.Add(this.LoadErrorText);
this.Controls.Add(this.LoadButton);
this.Controls.Add(this.PasswordText);
this.Controls.Add(this.PassnameText);
this.Controls.Add(this.label2);
this.Controls.Add(this.label1);
//this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.Margin = new System.Windows.Forms.Padding(4);
this.Name = "LoadForm";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "登陆 Ver2.2.6";
this.Load += new System.EventHandler(this.LoadForm_Load);
this.Resize += new System.EventHandler(this.LoadForm_Resize);
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.TextBox PassnameText;
private System.Windows.Forms.TextBox PasswordText;
private System.Windows.Forms.Button LoadButton;
private System.Windows.Forms.Label LoadErrorText;
private System.Windows.Forms.PictureBox pictureBox1;
private System.Windows.Forms.Button SignOut;
private System.Windows.Forms.Label LoadTextShow;
}
}
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Runtime.InteropServices;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace KonkeDemo
{
public partial class LoadForm : Form //登陆界面
{
public static LoadForm Load_interface = null; //用于将账号类型传给子窗口
public LoadForm()
{
InitializeComponent();
Load_interface = this; //用于将账号类型传给子窗口
}
//窗口最大化控件变化 - start
ControlChangesWithWindows LoadFormWindows = new ControlChangesWithWindows(); //随窗口改变大小类的实例化
private int RootType = 0;
private string RootName = "Unknow";
private string RootPW = "";
private string RootDepartment = "";
private void LoadXmlFile(string URL, string FileName)
{
try
{
}
catch
{
}
}
private void LoadConfigsFile()
{
}
//将控件的宽,高,左边距,顶边距和字体大小暂存到tag属性中
private void LoadForm_Load(object sender, EventArgs e)
{
LoadFormWindows.MethodForLoad(this);//调用方法
}
//根据窗体大小调整控件大小
private void LoadForm_Resize(object sender, EventArgs e)
{
try
{
int Width = this.Width;
int Height = this.Height;
if (Width >= 617 && Height >= 384)
{
this.AutoScroll = false;
LoadFormWindows.MethodForResize(this);//随窗体改变控件大小
}
else
this.AutoScroll = true;
}
catch (Exception ex)
{
MessageBox.Show("窗体大小改变-操作失败:" + ex.ToString());
}
}
//登陆操作 - start
[DllImport(".\\barcodex.ocx")]
public static extern int DllRegisterServer();//用于注册barcodex.OCX文件,用于生成条形码的控件
public int GetTempType() //用于将账号类型传给子窗口
{
return RootType;
}
public string GetRootName() //用于将账号名称传给子窗口
{
return RootName;
}
public string GetRootPW() //用于将账号密码传给子窗口
{
return RootPW;
}
public string GetRootDepartment() //用于将工厂信息传给子窗口
{
return RootDepartment;
}
//登陆按钮,检查账号密码是否正确,是否选择设备类型
private void LoadButton_Click(object sender, EventArgs e)
{
try
{
LoadTextShow.Visible = true; //登录提示
LoadErrorText.Visible = false; //隐藏错误提示框
RootName = PassnameText.Text;
Dictionary<string, object> dicPara = new Dictionary<string, object>
{
{ "item", "loginAccount" },
{ "value", PassnameText.Text.Trim() }
};
if (PassnameText.Text.Trim() == "surukun"
&& PasswordText.Text.Trim() == "123456")
{
this.Hide();
Configure ConfigureWindows = new Configure();
if (ConfigureWindows.ShowDialog() == DialogResult.OK) //以对话框形式显示配置界面
{
//this.Show(); //显示主界面
}
}
LoadTextShow.Visible = false;
LoadErrorText.Visible = true;//显示错误提示框
}
catch (Exception ex)
{
LoadErrorText.Text = "登录异常";
LoadTextShow.Visible = false;
LoadErrorText.Visible = true;//显示错误提示框
MessageBox.Show("登录异常:请检查网络后重试");
}
}
private bool CheckClientKey(string userName, string password)
{
return true;
}
private void PassNameEnter(object sender, KeyEventArgs e)
{
if (e.KeyCode == Keys.Enter)
PasswordText.Focus(); //将焦点设置到密码输入框
}
private void PassWordEnter(object sender, KeyEventArgs e)
{
if (e.KeyCode == Keys.Enter)
this.LoadButton_Click(sender, e); //点击名为LoadButton按键,即登陆
}
private void SignOut_Click(object sender, EventArgs e)
{
Application.Exit();
}
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace KonkeDemo
{
public class UIDemoInterface
{
public virtual string CheckInput(string strData)
{
return string.Empty;
}
public virtual SNInfo GetSNInfo(string sn)
{
return new SNInfo();
}
public virtual BaseConfig GetConfig()
{
return new BaseConfig();
}
public virtual void SetConfig(BaseConfig baseconfig) { }
public virtual void Run(DeviceInfo deviceinfo) { }
public virtual void Stop() { }
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace KonkeDemo
{
public class UIDemoProcess : UIDemoInterface
{
public delegate void SendMessageEventHandler(Helper.CustomMessage customMessage, string recv);
public event SendMessageEventHandler SendMessage;
public const int stateJoinNetWork = 0; //设备入网
public const int stateGetInfo = 1; //获取设备信息
public const int stateGetRssi = 2; //获取rssi
public const int stateAction = 3; //操作设备
public const int stateLED = 4;
public const int stateWriteAndRead = 5;//序列号写入
public const int stateRetireNetS = 6;//退网(成功)
public const int stateSuccess = 7;//测试成功
public const int stateFailed = 8;//测试失败
public const int statePower = 9; //功率校准
public const int stateOpen = 10; //下发开
public const int stateToFailing = 11;//测试失败
public const int stateClose = 12; //下发开
public int OutTimeFlag = -1;//超时标志位
protected int timerTick;//协调器状态
public int nowStep = stateJoinNetWork;//协调器状态
bool FlagW = true;
public override void Run(DeviceInfo deviceinfo)
{
try
{
while (FlagW)
{
if (Helper.Stop)
{
FlagW = false;
break;
}
System.Threading.Thread.Sleep(100);
//模组测试流程
RunMachineTest();
}
}
catch (Exception exc) { }
}
public void RunMachineTest()//整机产测执行函数,返回进度
{
timerTick++;
//执行整机产测的每个步骤
if (timerTick % 10 == 0) //约2s执行一次
{
switch (nowStep)
{
case stateJoinNetWork:
{
if (OutTimeFlag == -1)
OutTimeFlag = timerTick;
if ((timerTick - OutTimeFlag) > 50) //10s
{
nowStep = stateFailed;
OutTimeFlag = -1;
Console.WriteLine(string.Format("入网超时"));
SendMessage(Helper.CustomMessage.ViewLog, "入网超时");
SendMessage(Helper.CustomMessage.Progress, "25");
SendMessage(Helper.CustomMessage.Alarm, "入网超时");
}
Random random = new Random();
int iConclusion = random.Next(0, 2);
if (iConclusion == 0)
{
nowStep = stateFailed;
OutTimeFlag = -1;
Console.WriteLine(string.Format("入网失败"));
SendMessage(Helper.CustomMessage.ViewLog, "入网失败");
SendMessage(Helper.CustomMessage.Progress, "25");
SendMessage(Helper.CustomMessage.Alarm, "入网失败");
}
else if (iConclusion == 1)
{
nowStep = stateGetInfo;
OutTimeFlag = -1;
Console.WriteLine(string.Format("入网成功"));
SendMessage(Helper.CustomMessage.ViewLog, "入网成功");
SendMessage(Helper.CustomMessage.Progress, "25");
}
}
break;
case stateGetInfo:
{
if (OutTimeFlag == -1)
OutTimeFlag = timerTick;
if ((timerTick - OutTimeFlag) > 50) //10s
{
nowStep = stateFailed;
OutTimeFlag = -1;
Console.WriteLine(string.Format("读取版本号超时"));
SendMessage(Helper.CustomMessage.ViewLog, "读取版本号超时");
SendMessage(Helper.CustomMessage.Progress, "50");
SendMessage(Helper.CustomMessage.Alarm, "读取版本号超时");
}
Random random = new Random();
int iConclusion = random.Next(0, 2);
if (iConclusion == 0)
{
nowStep = stateFailed;
OutTimeFlag = -1;
Console.WriteLine(string.Format("读取版本号失败"));
SendMessage(Helper.CustomMessage.ViewLog, "读取版本号失败");
SendMessage(Helper.CustomMessage.Progress, "50");
SendMessage(Helper.CustomMessage.Alarm, "读取版本号失败");
}
else if (iConclusion == 1)
{
nowStep = stateGetRssi;
OutTimeFlag = -1;
Console.WriteLine(string.Format("读取版本号成功"));
SendMessage(Helper.CustomMessage.ViewLog, "读取版本号成功");
SendMessage(Helper.CustomMessage.Progress, "50");
}
}
break;
case stateGetRssi:
{
if (OutTimeFlag == -1)
OutTimeFlag = timerTick;
if ((timerTick - OutTimeFlag) > 50) //10s
{
nowStep = stateFailed;
OutTimeFlag = -1;
Console.WriteLine(string.Format("读取信号强度超时"));
SendMessage(Helper.CustomMessage.ViewLog, "读取信号强度超时");
SendMessage(Helper.CustomMessage.Progress, "75");
SendMessage(Helper.CustomMessage.Alarm, "读取信号强度超时");
}
Random random = new Random();
int iConclusion = random.Next(0, 2);
if (iConclusion == 0)
{
nowStep = stateFailed;
OutTimeFlag = -1;
Console.WriteLine(string.Format("读取信号强度失败"));
SendMessage(Helper.CustomMessage.ViewLog, "读取信号强度失败");
SendMessage(Helper.CustomMessage.Progress, "75");
SendMessage(Helper.CustomMessage.Alarm, "读取信号强度失败");
}
else if (iConclusion == 1)
{
nowStep = stateWriteAndRead;
OutTimeFlag = -1;
Console.WriteLine(string.Format("读取信号强度成功"));
SendMessage(Helper.CustomMessage.ViewLog, "读取信号强度成功");
SendMessage(Helper.CustomMessage.Progress, "75");
}
}
break;
case stateWriteAndRead:
{
if (OutTimeFlag == -1)
OutTimeFlag = timerTick;
if ((timerTick - OutTimeFlag) > 50) //10s
{
nowStep = stateFailed;
OutTimeFlag = -1;
Console.WriteLine(string.Format("读取InstallCode超时"));
SendMessage(Helper.CustomMessage.ViewLog, "读取InstallCode超时");
SendMessage(Helper.CustomMessage.Progress, "100");
SendMessage(Helper.CustomMessage.Alarm, "读取InstallCode超时");
}
Random random = new Random();
int iConclusion = random.Next(0, 2);
if (iConclusion == 0)
{
nowStep = stateFailed;
OutTimeFlag = -1;
Console.WriteLine(string.Format("读取InstallCode失败"));
SendMessage(Helper.CustomMessage.ViewLog, "读取InstallCode失败");
SendMessage(Helper.CustomMessage.Progress, "100");
SendMessage(Helper.CustomMessage.Alarm, "读取InstallCode失败");
}
else if (iConclusion == 1)
{
nowStep = stateSuccess;
OutTimeFlag = -1;
Console.WriteLine(string.Format("读取InstallCode成功"));
SendMessage(Helper.CustomMessage.ViewLog, "读取InstallCode成功");
SendMessage(Helper.CustomMessage.Progress, "100");
}
}
break;
case stateSuccess:
{
FlagW = false;
SendMessage(Helper.CustomMessage.Result, "1");
SendMessage(Helper.CustomMessage.Progress, "100");
SendMessage(Helper.CustomMessage.ViewLog, "成功");
}
break;
case stateFailed:
{
FlagW = false;
SendMessage(Helper.CustomMessage.Result, "0");
}
break;
default:
break;
}
}
}
}
}
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.7.2" />
</startup>
</configuration>
\ No newline at end of file
// <autogenerated />
using System;
using System.Reflection;
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETFramework,Version=v4.7.2", FrameworkDisplayName = ".NET Framework 4.7.2")]
E:\test\ModuleTest\KonkeDemo\obj\Debug\KonkeDemo.Properties.Resources.resources
E:\test\ModuleTest\KonkeDemo\obj\Debug\KonkeDemo.csproj.GenerateResource.cache
E:\test\ModuleTest\KonkeDemo\obj\Debug\KonkeDemo.csproj.CoreCompileInputs.cache
E:\test\ModuleTest\KonkeDemo\obj\Debug\KonkeDemo.UserControlmodular.resources
E:\test\ModuleTest\KonkeDemo\bin\Debug\KonkeDemo.exe.config
E:\test\ModuleTest\KonkeDemo\bin\Debug\KonkeDemo.exe
E:\test\ModuleTest\KonkeDemo\bin\Debug\KonkeDemo.pdb
E:\test\ModuleTest\KonkeDemo\bin\Debug\DevExpress.Data.v10.2.dll
E:\test\ModuleTest\KonkeDemo\bin\Debug\DevExpress.Utils.v10.2.dll
E:\test\ModuleTest\KonkeDemo\bin\Debug\DevExpress.XtraEditors.v10.2.Design.dll
E:\test\ModuleTest\KonkeDemo\bin\Debug\DevExpress.XtraEditors.v10.2.dll
E:\test\ModuleTest\KonkeDemo\bin\Debug\HZH_Controls.dll
E:\test\ModuleTest\KonkeDemo\bin\Debug\DevExpress.Design.v10.2.dll
E:\test\ModuleTest\KonkeDemo\obj\Debug\KonkeDemo.csproj.CopyComplete
E:\test\ModuleTest\KonkeDemo\obj\Debug\KonkeDemo.exe
E:\test\ModuleTest\KonkeDemo\obj\Debug\KonkeDemo.pdb
E:\test\ModuleTest\KonkeDemo\obj\Debug\KonkeDemo.FormMain.resources
E:\test\ModuleTest\KonkeDemo\bin\Debug\DevExpress.XtraBars.v10.2.dll
E:\test\ModuleTest\KonkeDemo\bin\Debug\DevExpress.XtraGrid.v10.2.dll
E:\test\ModuleTest\KonkeDemo\bin\Debug\DevExpress.XtraLayout.v10.2.Design.dll
E:\test\ModuleTest\KonkeDemo\bin\Debug\DevExpress.XtraLayout.v10.2.dll
E:\test\ModuleTest\KonkeDemo\bin\Debug\DevExpress.XtraNavBar.v10.2.dll
E:\test\ModuleTest\KonkeDemo\bin\Debug\DevExpress.XtraTreeList.v10.2.dll
E:\test\ModuleTest\KonkeDemo\obj\Debug\KonkeDemo.FormConfigure.resources
E:\test\ModuleTest\KonkeDemo\obj\Debug\KonkeDemo.csprojAssemblyReference.cache
E:\UIDemo\KonkeDemo\bin\Debug\KonkeDemo.exe.config
E:\UIDemo\KonkeDemo\bin\Debug\KonkeDemo.exe
E:\UIDemo\KonkeDemo\bin\Debug\KonkeDemo.pdb
E:\UIDemo\KonkeDemo\bin\Debug\DevExpress.Data.v10.2.dll
E:\UIDemo\KonkeDemo\bin\Debug\DevExpress.Design.v10.2.dll
E:\UIDemo\KonkeDemo\bin\Debug\DevExpress.Utils.v10.2.dll
E:\UIDemo\KonkeDemo\bin\Debug\DevExpress.XtraBars.v10.2.dll
E:\UIDemo\KonkeDemo\bin\Debug\DevExpress.XtraEditors.v10.2.Design.dll
E:\UIDemo\KonkeDemo\bin\Debug\DevExpress.XtraEditors.v10.2.dll
E:\UIDemo\KonkeDemo\bin\Debug\DevExpress.XtraGrid.v10.2.dll
E:\UIDemo\KonkeDemo\bin\Debug\DevExpress.XtraLayout.v10.2.Design.dll
E:\UIDemo\KonkeDemo\bin\Debug\DevExpress.XtraLayout.v10.2.dll
E:\UIDemo\KonkeDemo\bin\Debug\DevExpress.XtraNavBar.v10.2.dll
E:\UIDemo\KonkeDemo\bin\Debug\DevExpress.XtraTreeList.v10.2.dll
E:\UIDemo\KonkeDemo\obj\Debug\KonkeDemo.csprojAssemblyReference.cache
E:\UIDemo\KonkeDemo\obj\Debug\KonkeDemo.FormConfigure.resources
E:\UIDemo\KonkeDemo\obj\Debug\KonkeDemo.FormMain.resources
E:\UIDemo\KonkeDemo\obj\Debug\KonkeDemo.Properties.Resources.resources
E:\UIDemo\KonkeDemo\obj\Debug\KonkeDemo.UserControlmodular.resources
E:\UIDemo\KonkeDemo\obj\Debug\KonkeDemo.csproj.GenerateResource.cache
E:\UIDemo\KonkeDemo\obj\Debug\KonkeDemo.csproj.CoreCompileInputs.cache
E:\UIDemo\KonkeDemo\obj\Debug\KonkeDemo.csproj.CopyComplete
E:\UIDemo\KonkeDemo\obj\Debug\KonkeDemo.exe
E:\UIDemo\KonkeDemo\obj\Debug\KonkeDemo.pdb
E:\NewUIDemo\konkedemo\bin\Debug\KonkeDemo.exe.config
E:\NewUIDemo\konkedemo\bin\Debug\KonkeDemo.exe
E:\NewUIDemo\konkedemo\bin\Debug\KonkeDemo.pdb
E:\NewUIDemo\konkedemo\bin\Debug\DevExpress.Data.v10.2.dll
E:\NewUIDemo\konkedemo\bin\Debug\DevExpress.Design.v10.2.dll
E:\NewUIDemo\konkedemo\bin\Debug\DevExpress.Utils.v10.2.dll
E:\NewUIDemo\konkedemo\bin\Debug\DevExpress.XtraBars.v10.2.dll
E:\NewUIDemo\konkedemo\bin\Debug\DevExpress.XtraEditors.v10.2.Design.dll
E:\NewUIDemo\konkedemo\bin\Debug\DevExpress.XtraEditors.v10.2.dll
E:\NewUIDemo\konkedemo\bin\Debug\DevExpress.XtraGrid.v10.2.dll
E:\NewUIDemo\konkedemo\bin\Debug\DevExpress.XtraLayout.v10.2.Design.dll
E:\NewUIDemo\konkedemo\bin\Debug\DevExpress.XtraLayout.v10.2.dll
E:\NewUIDemo\konkedemo\bin\Debug\DevExpress.XtraNavBar.v10.2.dll
E:\NewUIDemo\konkedemo\bin\Debug\DevExpress.XtraTreeList.v10.2.dll
E:\NewUIDemo\konkedemo\obj\Debug\KonkeDemo.FormConfigure.resources
E:\NewUIDemo\konkedemo\obj\Debug\KonkeDemo.FormMain.resources
E:\NewUIDemo\konkedemo\obj\Debug\KonkeDemo.Properties.Resources.resources
E:\NewUIDemo\konkedemo\obj\Debug\KonkeDemo.UserControlmodular.resources
E:\NewUIDemo\konkedemo\obj\Debug\KonkeDemo.csproj.GenerateResource.cache
E:\NewUIDemo\konkedemo\obj\Debug\KonkeDemo.csproj.CoreCompileInputs.cache
E:\NewUIDemo\konkedemo\obj\Debug\KonkeDemo.csproj.CopyComplete
E:\NewUIDemo\konkedemo\obj\Debug\KonkeDemo.exe
E:\NewUIDemo\konkedemo\obj\Debug\KonkeDemo.pdb
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="HZH_Controls" version="1.0.14" targetFramework="net472" />
<package id="System.Collections.Concurrent" version="4.3.0" targetFramework="net472" />
</packages>
\ No newline at end of file
This Microsoft .NET Library may incorporate components from the projects listed
below. Microsoft licenses these components under the Microsoft .NET Library
software license terms. The original copyright notices and the licenses under
which Microsoft received such components are set forth below for informational
purposes only. Microsoft reserves all rights not expressly granted herein,
whether by implication, estoppel or otherwise.
1. .NET Core (https://github.com/dotnet/core/)
.NET Core
Copyright (c) .NET Foundation and Contributors
The MIT License (MIT)
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
\ No newline at end of file
MICROSOFT SOFTWARE LICENSE TERMS
MICROSOFT .NET LIBRARY
These license terms are an agreement between Microsoft Corporation (or based on where you live, one of its affiliates) and you. Please read them. They apply to the software named above, which includes the media on which you received it, if any. The terms also apply to any Microsoft
· updates,
· supplements,
· Internet-based services, and
· support services
for this software, unless other terms accompany those items. If so, those terms apply.
BY USING THE SOFTWARE, YOU ACCEPT THESE TERMS. IF YOU DO NOT ACCEPT THEM, DO NOT USE THE SOFTWARE.
IF YOU COMPLY WITH THESE LICENSE TERMS, YOU HAVE THE PERPETUAL RIGHTS BELOW.
1. INSTALLATION AND USE RIGHTS.
a. Installation and Use. You may install and use any number of copies of the software to design, develop and test your programs.
b. Third Party Programs. The software may include third party programs that Microsoft, not the third party, licenses to you under this agreement. Notices, if any, for the third party program are included for your information only.
2. ADDITIONAL LICENSING REQUIREMENTS AND/OR USE RIGHTS.
a. DISTRIBUTABLE CODE. The software is comprised of Distributable Code. “Distributable Code” is code that you are permitted to distribute in programs you develop if you comply with the terms below.
i. Right to Use and Distribute.
· You may copy and distribute the object code form of the software.
· Third Party Distribution. You may permit distributors of your programs to copy and distribute the Distributable Code as part of those programs.
ii. Distribution Requirements. For any Distributable Code you distribute, you must
· add significant primary functionality to it in your programs;
· require distributors and external end users to agree to terms that protect it at least as much as this agreement;
· display your valid copyright notice on your programs; and
· indemnify, defend, and hold harmless Microsoft from any claims, including attorneys’ fees, related to the distribution or use of your programs.
iii. Distribution Restrictions. You may not
· alter any copyright, trademark or patent notice in the Distributable Code;
· use Microsoft’s trademarks in your programs’ names or in a way that suggests your programs come from or are endorsed by Microsoft;
· include Distributable Code in malicious, deceptive or unlawful programs; or
· modify or distribute the source code of any Distributable Code so that any part of it becomes subject to an Excluded License. An Excluded License is one that requires, as a condition of use, modification or distribution, that
· the code be disclosed or distributed in source code form; or
· others have the right to modify it.
3. SCOPE OF LICENSE. The software is licensed, not sold. This agreement only gives you some rights to use the software. Microsoft reserves all other rights. Unless applicable law gives you more rights despite this limitation, you may use the software only as expressly permitted in this agreement. In doing so, you must comply with any technical limitations in the software that only allow you to use it in certain ways. You may not
· work around any technical limitations in the software;
· reverse engineer, decompile or disassemble the software, except and only to the extent that applicable law expressly permits, despite this limitation;
· publish the software for others to copy;
· rent, lease or lend the software;
· transfer the software or this agreement to any third party; or
· use the software for commercial software hosting services.
4. BACKUP COPY. You may make one backup copy of the software. You may use it only to reinstall the software.
5. DOCUMENTATION. Any person that has valid access to your computer or internal network may copy and use the documentation for your internal, reference purposes.
6. EXPORT RESTRICTIONS. The software is subject to United States export laws and regulations. You must comply with all domestic and international export laws and regulations that apply to the software. These laws include restrictions on destinations, end users and end use. For additional information, see www.microsoft.com/exporting.
7. SUPPORT SERVICES. Because this software is “as is,” we may not provide support services for it.
8. ENTIRE AGREEMENT. This agreement, and the terms for supplements, updates, Internet-based services and support services that you use, are the entire agreement for the software and support services.
9. APPLICABLE LAW.
a. United States. If you acquired the software in the United States, Washington state law governs the interpretation of this agreement and applies to claims for breach of it, regardless of conflict of laws principles. The laws of the state where you live govern all other claims, including claims under state consumer protection laws, unfair competition laws, and in tort.
b. Outside the United States. If you acquired the software in any other country, the laws of that country apply.
10. LEGAL EFFECT. This agreement describes certain legal rights. You may have other rights under the laws of your country. You may also have rights with respect to the party from whom you acquired the software. This agreement does not change your rights under the laws of your country if the laws of your country do not permit it to do so.
11. DISCLAIMER OF WARRANTY. THE SOFTWARE IS LICENSED “AS-IS.” YOU BEAR THE RISK OF USING IT. MICROSOFT GIVES NO EXPRESS WARRANTIES, GUARANTEES OR CONDITIONS. YOU MAY HAVE ADDITIONAL CONSUMER RIGHTS OR STATUTORY GUARANTEES UNDER YOUR LOCAL LAWS WHICH THIS AGREEMENT CANNOT CHANGE. TO THE EXTENT PERMITTED UNDER YOUR LOCAL LAWS, MICROSOFT EXCLUDES THE IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
FOR AUSTRALIA – YOU HAVE STATUTORY GUARANTEES UNDER THE AUSTRALIAN CONSUMER LAW AND NOTHING IN THESE TERMS IS INTENDED TO AFFECT THOSE RIGHTS.
12. LIMITATION ON AND EXCLUSION OF REMEDIES AND DAMAGES. YOU CAN RECOVER FROM MICROSOFT AND ITS SUPPLIERS ONLY DIRECT DAMAGES UP TO U.S. $5.00. YOU CANNOT RECOVER ANY OTHER DAMAGES, INCLUDING CONSEQUENTIAL, LOST PROFITS, SPECIAL, INDIRECT OR INCIDENTAL DAMAGES.
This limitation applies to
· anything related to the software, services, content (including code) on third party Internet sites, or third party programs; and
· claims for breach of contract, breach of warranty, guarantee or condition, strict liability, negligence, or other tort to the extent permitted by applicable law.
It also applies even if Microsoft knew or should have known about the possibility of the damages. The above limitation or exclusion may not apply to you because your country may not allow the exclusion or limitation of incidental, consequential or other damages.
Please note: As this software is distributed in Quebec, Canada, some of the clauses in this agreement are provided below in French.
Remarque : Ce logiciel étant distribué au Québec, Canada, certaines des clauses dans ce contrat sont fournies ci-dessous en français.
EXONÉRATION DE GARANTIE. Le logiciel visé par une licence est offert « tel quel ». Toute utilisation de ce logiciel est à votre seule risque et péril. Microsoft n’accorde aucune autre garantie expresse. Vous pouvez bénéficier de droits additionnels en vertu du droit local sur la protection des consommateurs, que ce contrat ne peut modifier. La ou elles sont permises par le droit locale, les garanties implicites de qualité marchande, d’adéquation à un usage particulier et d’absence de contrefaçon sont exclues.
LIMITATION DES DOMMAGES-INTÉRÊTS ET EXCLUSION DE RESPONSABILITÉ POUR LES DOMMAGES. Vous pouvez obtenir de Microsoft et de ses fournisseurs une indemnisation en cas de dommages directs uniquement à hauteur de 5,00 $ US. Vous ne pouvez prétendre à aucune indemnisation pour les autres dommages, y compris les dommages spéciaux, indirects ou accessoires et pertes de bénéfices.
Cette limitation concerne :
· tout ce qui est relié au logiciel, aux services ou au contenu (y compris le code) figurant sur des sites Internet tiers ou dans des programmes tiers ; et
· les réclamations au titre de violation de contrat ou de garantie, ou au titre de responsabilité stricte, de négligence ou d’une autre faute dans la limite autorisée par la loi en vigueur.
Elle s’applique également, même si Microsoft connaissait ou devrait connaître l’éventualité d’un tel dommage. Si votre pays n’autorise pas l’exclusion ou la limitation de responsabilité pour les dommages indirects, accessoires ou de quelque nature que ce soit, il se peut que la limitation ou l’exclusion ci-dessus ne s’appliquera pas à votre égard.
EFFET JURIDIQUE. Le présent contrat décrit certains droits juridiques. Vous pourriez avoir d’autres droits prévus par les lois de votre pays. Le présent contrat ne modifie pas les droits que vous confèrent les lois de votre pays si celles-ci ne le permettent pas.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment