초기 커밋.
This commit is contained in:
152
LFP_Manager_PRM/Forms/fmCalibration.Designer.cs
generated
Normal file
152
LFP_Manager_PRM/Forms/fmCalibration.Designer.cs
generated
Normal file
@@ -0,0 +1,152 @@
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
partial class fmxCalibration
|
||||
{
|
||||
/// <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.components = new System.ComponentModel.Container();
|
||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(fmxCalibration));
|
||||
this.layoutControl1 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.layoutControlGroup1 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.ucCalibration1 = new LFP_Manager.Controls.ucCalibration();
|
||||
this.layoutControlItem1 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.btnClose = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.layoutControlItem2 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.tmrDisplay = new System.Windows.Forms.Timer(this.components);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).BeginInit();
|
||||
this.layoutControl1.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// layoutControl1
|
||||
//
|
||||
this.layoutControl1.Controls.Add(this.btnClose);
|
||||
this.layoutControl1.Controls.Add(this.ucCalibration1);
|
||||
this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControl1.Name = "layoutControl1";
|
||||
this.layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(668, 306, 250, 350);
|
||||
this.layoutControl1.Root = this.layoutControlGroup1;
|
||||
this.layoutControl1.Size = new System.Drawing.Size(612, 485);
|
||||
this.layoutControl1.TabIndex = 0;
|
||||
this.layoutControl1.Text = "layoutControl1";
|
||||
//
|
||||
// layoutControlGroup1
|
||||
//
|
||||
this.layoutControlGroup1.CustomizationFormText = "layoutControlGroup1";
|
||||
this.layoutControlGroup1.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.layoutControlGroup1.GroupBordersVisible = false;
|
||||
this.layoutControlGroup1.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem1,
|
||||
this.layoutControlItem2});
|
||||
this.layoutControlGroup1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlGroup1.Name = "layoutControlGroup1";
|
||||
this.layoutControlGroup1.Size = new System.Drawing.Size(612, 485);
|
||||
this.layoutControlGroup1.Text = "layoutControlGroup1";
|
||||
this.layoutControlGroup1.TextVisible = false;
|
||||
//
|
||||
// ucCalibration1
|
||||
//
|
||||
this.ucCalibration1.Location = new System.Drawing.Point(12, 12);
|
||||
this.ucCalibration1.Name = "ucCalibration1";
|
||||
this.ucCalibration1.Size = new System.Drawing.Size(588, 423);
|
||||
this.ucCalibration1.TabIndex = 4;
|
||||
//
|
||||
// layoutControlItem1
|
||||
//
|
||||
this.layoutControlItem1.Control = this.ucCalibration1;
|
||||
this.layoutControlItem1.CustomizationFormText = "layoutControlItem1";
|
||||
this.layoutControlItem1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem1.MinSize = new System.Drawing.Size(104, 24);
|
||||
this.layoutControlItem1.Name = "layoutControlItem1";
|
||||
this.layoutControlItem1.Size = new System.Drawing.Size(592, 427);
|
||||
this.layoutControlItem1.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem1.Text = "layoutControlItem1";
|
||||
this.layoutControlItem1.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem1.TextToControlDistance = 0;
|
||||
this.layoutControlItem1.TextVisible = false;
|
||||
//
|
||||
// btnClose
|
||||
//
|
||||
this.btnClose.Location = new System.Drawing.Point(12, 439);
|
||||
this.btnClose.Name = "btnClose";
|
||||
this.btnClose.Size = new System.Drawing.Size(588, 34);
|
||||
this.btnClose.StyleController = this.layoutControl1;
|
||||
this.btnClose.TabIndex = 5;
|
||||
this.btnClose.Text = "Close";
|
||||
this.btnClose.Click += new System.EventHandler(this.btnClose_Click);
|
||||
//
|
||||
// layoutControlItem2
|
||||
//
|
||||
this.layoutControlItem2.Control = this.btnClose;
|
||||
this.layoutControlItem2.CustomizationFormText = "layoutControlItem2";
|
||||
this.layoutControlItem2.Location = new System.Drawing.Point(0, 427);
|
||||
this.layoutControlItem2.MinSize = new System.Drawing.Size(93, 26);
|
||||
this.layoutControlItem2.Name = "layoutControlItem2";
|
||||
this.layoutControlItem2.Size = new System.Drawing.Size(592, 38);
|
||||
this.layoutControlItem2.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem2.Text = "layoutControlItem2";
|
||||
this.layoutControlItem2.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem2.TextToControlDistance = 0;
|
||||
this.layoutControlItem2.TextVisible = false;
|
||||
//
|
||||
// tmrDisplay
|
||||
//
|
||||
this.tmrDisplay.Interval = 500;
|
||||
this.tmrDisplay.Tick += new System.EventHandler(this.tmrDisplay_Tick);
|
||||
//
|
||||
// fmxCalibration
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(612, 485);
|
||||
this.Controls.Add(this.layoutControl1);
|
||||
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
|
||||
this.Name = "fmxCalibration";
|
||||
this.Text = "Calibration";
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).EndInit();
|
||||
this.layoutControl1.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl1;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup1;
|
||||
private DevExpress.XtraEditors.SimpleButton btnClose;
|
||||
private Controls.ucCalibration ucCalibration1;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem1;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem2;
|
||||
private System.Windows.Forms.Timer tmrDisplay;
|
||||
}
|
||||
}
|
||||
79
LFP_Manager_PRM/Forms/fmCalibration.cs
Normal file
79
LFP_Manager_PRM/Forms/fmCalibration.cs
Normal file
@@ -0,0 +1,79 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Text;
|
||||
using System.Linq;
|
||||
using System.Windows.Forms;
|
||||
using DevExpress.XtraEditors;
|
||||
|
||||
using LFP_Manager.DataStructure;
|
||||
using LFP_Manager.Function;
|
||||
using LFP_Manager.Controls;
|
||||
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
public delegate void CalibUpdateEvent(object sendor);
|
||||
public delegate void CalibCmdEvent(int sId, int mode, int flag, DeviceParamData aParam, DeviceCalibration aCalib);
|
||||
|
||||
public partial class fmxCalibration : DevExpress.XtraEditors.XtraForm
|
||||
{
|
||||
#region VARIABLES
|
||||
|
||||
int SystemId = 0;
|
||||
DeviceParamData Param;
|
||||
DeviceCalibration Calib;
|
||||
|
||||
public event CalibUpdateEvent OnUpdate = null;
|
||||
public event CalibCmdEvent OnCommand = null;
|
||||
|
||||
#endregion
|
||||
|
||||
#region CONSTRUCTORS
|
||||
|
||||
public fmxCalibration()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
public fmxCalibration(int sId, DeviceCalibration aCalib)
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
SystemId = sId;
|
||||
Calib = aCalib;
|
||||
|
||||
tmrDisplay.Enabled = true;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private void btnClose_Click(object sender, EventArgs e)
|
||||
{
|
||||
Close();
|
||||
}
|
||||
|
||||
#region TIMER EVENT
|
||||
|
||||
private void tmrDisplay_Tick(object sender, EventArgs e)
|
||||
{
|
||||
if (OnUpdate != null)
|
||||
{
|
||||
OnUpdate(this);
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region PUBLIC FUCTIONS
|
||||
|
||||
public void UpdateData(DeviceParamData aParam, DeviceCalibration aCalib)
|
||||
{
|
||||
Param = aParam;
|
||||
Calib = aCalib;
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
4574
LFP_Manager_PRM/Forms/fmCalibration.resx
Normal file
4574
LFP_Manager_PRM/Forms/fmCalibration.resx
Normal file
File diff suppressed because it is too large
Load Diff
192
LFP_Manager_PRM/Forms/fmxCalibration.Designer.cs
generated
Normal file
192
LFP_Manager_PRM/Forms/fmxCalibration.Designer.cs
generated
Normal file
@@ -0,0 +1,192 @@
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
partial class fmxCalibration
|
||||
{
|
||||
/// <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.components = new System.ComponentModel.Container();
|
||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(fmxCalibration));
|
||||
this.layoutControl1 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.btnResetAll = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.btnClose = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.ucCalibrationConfig = new LFP_Manager.Controls.ucCalibration();
|
||||
this.layoutControlGroup1 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem1 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem2 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.emptySpaceItem1 = new DevExpress.XtraLayout.EmptySpaceItem();
|
||||
this.layoutControlItem3 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.tmrDisplay = new System.Windows.Forms.Timer(this.components);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).BeginInit();
|
||||
this.layoutControl1.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// layoutControl1
|
||||
//
|
||||
this.layoutControl1.Controls.Add(this.btnResetAll);
|
||||
this.layoutControl1.Controls.Add(this.btnClose);
|
||||
this.layoutControl1.Controls.Add(this.ucCalibrationConfig);
|
||||
this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControl1.Name = "layoutControl1";
|
||||
this.layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(1265, 291, 250, 350);
|
||||
this.layoutControl1.Root = this.layoutControlGroup1;
|
||||
this.layoutControl1.Size = new System.Drawing.Size(806, 599);
|
||||
this.layoutControl1.TabIndex = 0;
|
||||
this.layoutControl1.Text = "layoutControl1";
|
||||
//
|
||||
// btnResetAll
|
||||
//
|
||||
this.btnResetAll.Location = new System.Drawing.Point(4, 559);
|
||||
this.btnResetAll.Name = "btnResetAll";
|
||||
this.btnResetAll.Size = new System.Drawing.Size(110, 36);
|
||||
this.btnResetAll.StyleController = this.layoutControl1;
|
||||
this.btnResetAll.TabIndex = 6;
|
||||
this.btnResetAll.Text = "Reset";
|
||||
this.btnResetAll.Click += new System.EventHandler(this.btnResetAll_Click);
|
||||
//
|
||||
// btnClose
|
||||
//
|
||||
this.btnClose.Location = new System.Drawing.Point(702, 559);
|
||||
this.btnClose.Name = "btnClose";
|
||||
this.btnClose.Size = new System.Drawing.Size(100, 36);
|
||||
this.btnClose.StyleController = this.layoutControl1;
|
||||
this.btnClose.TabIndex = 5;
|
||||
this.btnClose.Text = "Close";
|
||||
this.btnClose.Click += new System.EventHandler(this.btnClose_Click);
|
||||
//
|
||||
// ucCalibrationConfig
|
||||
//
|
||||
this.ucCalibrationConfig.Location = new System.Drawing.Point(4, 4);
|
||||
this.ucCalibrationConfig.Name = "ucCalibrationConfig";
|
||||
this.ucCalibrationConfig.Size = new System.Drawing.Size(798, 551);
|
||||
this.ucCalibrationConfig.TabIndex = 4;
|
||||
//
|
||||
// layoutControlGroup1
|
||||
//
|
||||
this.layoutControlGroup1.CustomizationFormText = "layoutControlGroup1";
|
||||
this.layoutControlGroup1.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.layoutControlGroup1.GroupBordersVisible = false;
|
||||
this.layoutControlGroup1.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem1,
|
||||
this.layoutControlItem2,
|
||||
this.emptySpaceItem1,
|
||||
this.layoutControlItem3});
|
||||
this.layoutControlGroup1.Name = "Root";
|
||||
this.layoutControlGroup1.Padding = new DevExpress.XtraLayout.Utils.Padding(2, 2, 2, 2);
|
||||
this.layoutControlGroup1.Size = new System.Drawing.Size(806, 599);
|
||||
this.layoutControlGroup1.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem1
|
||||
//
|
||||
this.layoutControlItem1.Control = this.ucCalibrationConfig;
|
||||
this.layoutControlItem1.CustomizationFormText = "layoutControlItem1";
|
||||
this.layoutControlItem1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem1.MinSize = new System.Drawing.Size(104, 24);
|
||||
this.layoutControlItem1.Name = "layoutControlItem1";
|
||||
this.layoutControlItem1.Size = new System.Drawing.Size(802, 555);
|
||||
this.layoutControlItem1.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem1.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem1.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem2
|
||||
//
|
||||
this.layoutControlItem2.Control = this.btnClose;
|
||||
this.layoutControlItem2.CustomizationFormText = "layoutControlItem2";
|
||||
this.layoutControlItem2.Location = new System.Drawing.Point(698, 555);
|
||||
this.layoutControlItem2.MinSize = new System.Drawing.Size(93, 26);
|
||||
this.layoutControlItem2.Name = "layoutControlItem2";
|
||||
this.layoutControlItem2.Size = new System.Drawing.Size(104, 40);
|
||||
this.layoutControlItem2.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem2.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem2.TextVisible = false;
|
||||
//
|
||||
// emptySpaceItem1
|
||||
//
|
||||
this.emptySpaceItem1.AllowHotTrack = false;
|
||||
this.emptySpaceItem1.CustomizationFormText = "emptySpaceItem1";
|
||||
this.emptySpaceItem1.Location = new System.Drawing.Point(114, 555);
|
||||
this.emptySpaceItem1.Name = "emptySpaceItem1";
|
||||
this.emptySpaceItem1.Size = new System.Drawing.Size(584, 40);
|
||||
this.emptySpaceItem1.TextSize = new System.Drawing.Size(0, 0);
|
||||
//
|
||||
// layoutControlItem3
|
||||
//
|
||||
this.layoutControlItem3.Control = this.btnResetAll;
|
||||
this.layoutControlItem3.CustomizationFormText = "layoutControlItem3";
|
||||
this.layoutControlItem3.Location = new System.Drawing.Point(0, 555);
|
||||
this.layoutControlItem3.MinSize = new System.Drawing.Size(93, 26);
|
||||
this.layoutControlItem3.Name = "layoutControlItem3";
|
||||
this.layoutControlItem3.Size = new System.Drawing.Size(114, 40);
|
||||
this.layoutControlItem3.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem3.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem3.TextVisible = false;
|
||||
//
|
||||
// tmrDisplay
|
||||
//
|
||||
this.tmrDisplay.Interval = 500;
|
||||
this.tmrDisplay.Tick += new System.EventHandler(this.tmrDisplay_Tick);
|
||||
//
|
||||
// fmxCalibration
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(806, 599);
|
||||
this.Controls.Add(this.layoutControl1);
|
||||
this.IconOptions.Icon = ((System.Drawing.Icon)(resources.GetObject("fmxCalibration.IconOptions.Icon")));
|
||||
this.Name = "fmxCalibration";
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
|
||||
this.Text = "Calibration";
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).EndInit();
|
||||
this.layoutControl1.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl1;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup1;
|
||||
private DevExpress.XtraEditors.SimpleButton btnClose;
|
||||
private Controls.ucCalibration ucCalibrationConfig;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem1;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem2;
|
||||
private System.Windows.Forms.Timer tmrDisplay;
|
||||
private DevExpress.XtraLayout.EmptySpaceItem emptySpaceItem1;
|
||||
private DevExpress.XtraEditors.SimpleButton btnResetAll;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem3;
|
||||
}
|
||||
}
|
||||
137
LFP_Manager_PRM/Forms/fmxCalibration.cs
Normal file
137
LFP_Manager_PRM/Forms/fmxCalibration.cs
Normal file
@@ -0,0 +1,137 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Text;
|
||||
using System.Linq;
|
||||
using System.Windows.Forms;
|
||||
using DevExpress.XtraEditors;
|
||||
|
||||
using LFP_Manager.DataStructure;
|
||||
using LFP_Manager.Function;
|
||||
using LFP_Manager.Controls;
|
||||
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
public delegate void CalibUpdateEvent(object sendor);
|
||||
public delegate void CalibCmdEvent(int sId, int mode, int flag, ref DeviceParamData aParam, ref DeviceCalibration aCalib);
|
||||
|
||||
public partial class fmxCalibration : DevExpress.XtraEditors.XtraForm
|
||||
{
|
||||
#region VARIABLES
|
||||
|
||||
int SystemId = 0;
|
||||
DeviceSystemData SystemData;
|
||||
DeviceParamData Param;
|
||||
DeviceCalibration Calib;
|
||||
|
||||
public event CalibUpdateEvent OnUpdate = null;
|
||||
public event CalibCmdEvent OnCommand = null;
|
||||
|
||||
#endregion
|
||||
|
||||
#region CONSTRUCTORS
|
||||
|
||||
public fmxCalibration()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
public fmxCalibration(int sId, DeviceCalibration aCalib)
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
InitComponent();
|
||||
|
||||
SystemId = sId;
|
||||
Calib = aCalib;
|
||||
|
||||
tmrDisplay.Enabled = true;
|
||||
}
|
||||
|
||||
public void InitComponent()
|
||||
{
|
||||
// Cell Voltage Calibration
|
||||
ucCalibrationConfig.OnCommand += OnCmdEvent;
|
||||
ucCalibrationConfig.OnGetBattData += OnGetCellDataEvent;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region COMMAND EVENT
|
||||
|
||||
private void OnCmdEvent(int mode, int flag, ref DeviceCalibration aCalib, ref DeviceSystemTotalData aTotal)
|
||||
{
|
||||
OnCommand?.Invoke(SystemId, mode, flag, ref Param, ref aCalib);
|
||||
}
|
||||
|
||||
private Int32 OnGetCellDataEvent(int item, int cno)
|
||||
{
|
||||
Int32 result = 0;
|
||||
|
||||
switch (item)
|
||||
{
|
||||
case 0: // Cell Voltagae Value
|
||||
if ((cno > 0) && (cno <= csConstData.SystemInfo.MAX_MODULE_CELL_SIZE)) result = (Int32)SystemData.ValueData.CellVoltage[cno - 1];
|
||||
break;
|
||||
case 1:
|
||||
result = (Int32)SystemData.ValueData.voltageOfPack;
|
||||
break;
|
||||
case 2:
|
||||
result = (Int32)SystemData.ValueData.current;
|
||||
break;
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region BUTTON EVENT
|
||||
|
||||
private void btnClose_Click(object sender, EventArgs e)
|
||||
{
|
||||
Close();
|
||||
}
|
||||
private void btnResetAll_Click(object sender, EventArgs e)
|
||||
{
|
||||
OnCommand?.Invoke(0xFF, 25, 1, ref Param, ref Calib);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region TIMER EVENT
|
||||
|
||||
private void tmrDisplay_Tick(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
DisplayValue();
|
||||
OnUpdate?.Invoke(this);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region DISPLAY DATA
|
||||
|
||||
private void DisplayValue()
|
||||
{
|
||||
// Cell Voltage Parameter
|
||||
ucCalibrationConfig.UpdateData(Calib);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region PUBLIC FUCTIONS
|
||||
|
||||
public void UpdateData(DeviceParamData aParam, DeviceCalibration aCalib, DeviceSystemData aSystemData)
|
||||
{
|
||||
SystemData = aSystemData;
|
||||
Param = aParam;
|
||||
Calib = aCalib;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
}
|
||||
}
|
||||
4574
LFP_Manager_PRM/Forms/fmxCalibration.resx
Normal file
4574
LFP_Manager_PRM/Forms/fmxCalibration.resx
Normal file
File diff suppressed because it is too large
Load Diff
108
LFP_Manager_PRM/Forms/fmxCommConfig.Designer.cs
generated
Normal file
108
LFP_Manager_PRM/Forms/fmxCommConfig.Designer.cs
generated
Normal file
@@ -0,0 +1,108 @@
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
partial class fmxCommConfig
|
||||
{
|
||||
/// <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(fmxCommConfig));
|
||||
this.layoutControl1 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.layoutControlGroup1 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.ucCommConfig1 = new LFP_Manager.Controls.ucCommConfig();
|
||||
this.layoutControlItem1 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).BeginInit();
|
||||
this.layoutControl1.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// layoutControl1
|
||||
//
|
||||
this.layoutControl1.Controls.Add(this.ucCommConfig1);
|
||||
this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControl1.Name = "layoutControl1";
|
||||
this.layoutControl1.Root = this.layoutControlGroup1;
|
||||
this.layoutControl1.Size = new System.Drawing.Size(404, 507);
|
||||
this.layoutControl1.TabIndex = 0;
|
||||
this.layoutControl1.Text = "layoutControl1";
|
||||
//
|
||||
// layoutControlGroup1
|
||||
//
|
||||
this.layoutControlGroup1.CustomizationFormText = "layoutControlGroup1";
|
||||
this.layoutControlGroup1.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.layoutControlGroup1.GroupBordersVisible = false;
|
||||
this.layoutControlGroup1.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem1});
|
||||
this.layoutControlGroup1.Name = "layoutControlGroup1";
|
||||
this.layoutControlGroup1.Padding = new DevExpress.XtraLayout.Utils.Padding(1, 1, 1, 1);
|
||||
this.layoutControlGroup1.Size = new System.Drawing.Size(404, 507);
|
||||
this.layoutControlGroup1.TextVisible = false;
|
||||
//
|
||||
// ucCommConfig1
|
||||
//
|
||||
this.ucCommConfig1.Location = new System.Drawing.Point(3, 3);
|
||||
this.ucCommConfig1.Name = "ucCommConfig1";
|
||||
this.ucCommConfig1.Size = new System.Drawing.Size(398, 501);
|
||||
this.ucCommConfig1.TabIndex = 4;
|
||||
//
|
||||
// layoutControlItem1
|
||||
//
|
||||
this.layoutControlItem1.Control = this.ucCommConfig1;
|
||||
this.layoutControlItem1.CustomizationFormText = "layoutControlItem1";
|
||||
this.layoutControlItem1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem1.Name = "layoutControlItem1";
|
||||
this.layoutControlItem1.Size = new System.Drawing.Size(402, 505);
|
||||
this.layoutControlItem1.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem1.TextVisible = false;
|
||||
//
|
||||
// fmxCommConfig
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(404, 507);
|
||||
this.Controls.Add(this.layoutControl1);
|
||||
this.IconOptions.Icon = ((System.Drawing.Icon)(resources.GetObject("fmxCommConfig.IconOptions.Icon")));
|
||||
this.Name = "fmxCommConfig";
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
|
||||
this.Text = "Communication Config";
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).EndInit();
|
||||
this.layoutControl1.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl1;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup1;
|
||||
private Controls.ucCommConfig ucCommConfig1;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem1;
|
||||
|
||||
}
|
||||
}
|
||||
36
LFP_Manager_PRM/Forms/fmxCommConfig.cs
Normal file
36
LFP_Manager_PRM/Forms/fmxCommConfig.cs
Normal file
@@ -0,0 +1,36 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Text;
|
||||
using System.Linq;
|
||||
using System.Windows.Forms;
|
||||
using DevExpress.XtraEditors;
|
||||
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
public delegate void UpdateEvent(object aConfig);
|
||||
|
||||
public partial class fmxCommConfig : DevExpress.XtraEditors.XtraForm
|
||||
{
|
||||
public event UpdateEvent OnUpdate = null;
|
||||
|
||||
public fmxCommConfig()
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
ucCommConfig1.OnClose += FormClose;
|
||||
}
|
||||
|
||||
private void FormClose(object Config)
|
||||
{
|
||||
if (OnUpdate != null)
|
||||
{
|
||||
OnUpdate(Config);
|
||||
}
|
||||
|
||||
Close();
|
||||
}
|
||||
}
|
||||
}
|
||||
4571
LFP_Manager_PRM/Forms/fmxCommConfig.resx
Normal file
4571
LFP_Manager_PRM/Forms/fmxCommConfig.resx
Normal file
File diff suppressed because it is too large
Load Diff
741
LFP_Manager_PRM/Forms/fmxExcelFile.Designer.cs
generated
Normal file
741
LFP_Manager_PRM/Forms/fmxExcelFile.Designer.cs
generated
Normal file
@@ -0,0 +1,741 @@
|
||||
namespace LFP_Manager
|
||||
{
|
||||
partial class fmxExcelFile
|
||||
{
|
||||
/// <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(fmxExcelFile));
|
||||
this.layoutControl1 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.tbPcbSn = new DevExpress.XtraEditors.TextEdit();
|
||||
this.btnOpenDbFolder = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.edResultCount = new DevExpress.XtraEditors.TextEdit();
|
||||
this.btnResultListClear = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.btnSearchPcbSn = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.btnOutputAll = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.btnCheckMeasData = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.btnCheckDimData = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.btnCheckGroupData = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.cbResultList = new DevExpress.XtraEditors.ComboBoxEdit();
|
||||
this.cbLotNo = new DevExpress.XtraEditors.ComboBoxEdit();
|
||||
this.btnExcuteTCell = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.gbDbCommnad = new DevExpress.XtraEditors.GroupControl();
|
||||
this.layoutControl2 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.btnOpenSchema = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.btnBmsDuplicateCheck = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.btnQueryExcute = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.layoutControlGroup2 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem5 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem6 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem7 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.tbSchema = new System.Windows.Forms.TextBox();
|
||||
this.gridCell = new System.Windows.Forms.DataGridView();
|
||||
this.btnFindFile = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.edFileName = new DevExpress.XtraEditors.TextEdit();
|
||||
this.layoutControlGroup1 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem1 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem2 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.emptySpaceItem1 = new DevExpress.XtraLayout.EmptySpaceItem();
|
||||
this.layoutControlItem3 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem4 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem8 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem9 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.lcitemLot = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem10 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.emptySpaceItem2 = new DevExpress.XtraLayout.EmptySpaceItem();
|
||||
this.layoutControlItem11 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem12 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem13 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem14 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem15 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem16 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem18 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem17 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem19 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).BeginInit();
|
||||
this.layoutControl1.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.tbPcbSn.Properties)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.edResultCount.Properties)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.cbResultList.Properties)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.cbLotNo.Properties)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.gbDbCommnad)).BeginInit();
|
||||
this.gbDbCommnad.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl2)).BeginInit();
|
||||
this.layoutControl2.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup2)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.gridCell)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.edFileName.Properties)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.lcitemLot)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem10)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem2)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem11)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem12)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem13)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem14)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem15)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem16)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem18)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem17)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem19)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// layoutControl1
|
||||
//
|
||||
this.layoutControl1.Controls.Add(this.tbPcbSn);
|
||||
this.layoutControl1.Controls.Add(this.btnOpenDbFolder);
|
||||
this.layoutControl1.Controls.Add(this.edResultCount);
|
||||
this.layoutControl1.Controls.Add(this.btnResultListClear);
|
||||
this.layoutControl1.Controls.Add(this.btnSearchPcbSn);
|
||||
this.layoutControl1.Controls.Add(this.btnOutputAll);
|
||||
this.layoutControl1.Controls.Add(this.btnCheckMeasData);
|
||||
this.layoutControl1.Controls.Add(this.btnCheckDimData);
|
||||
this.layoutControl1.Controls.Add(this.btnCheckGroupData);
|
||||
this.layoutControl1.Controls.Add(this.cbResultList);
|
||||
this.layoutControl1.Controls.Add(this.cbLotNo);
|
||||
this.layoutControl1.Controls.Add(this.btnExcuteTCell);
|
||||
this.layoutControl1.Controls.Add(this.gbDbCommnad);
|
||||
this.layoutControl1.Controls.Add(this.tbSchema);
|
||||
this.layoutControl1.Controls.Add(this.gridCell);
|
||||
this.layoutControl1.Controls.Add(this.btnFindFile);
|
||||
this.layoutControl1.Controls.Add(this.edFileName);
|
||||
this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControl1.Name = "layoutControl1";
|
||||
this.layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(1347, 290, 250, 350);
|
||||
this.layoutControl1.Root = this.layoutControlGroup1;
|
||||
this.layoutControl1.Size = new System.Drawing.Size(999, 578);
|
||||
this.layoutControl1.TabIndex = 0;
|
||||
this.layoutControl1.Text = "layoutControl1";
|
||||
//
|
||||
// tbPcbSn
|
||||
//
|
||||
this.tbPcbSn.Location = new System.Drawing.Point(681, 265);
|
||||
this.tbPcbSn.Name = "tbPcbSn";
|
||||
this.tbPcbSn.Size = new System.Drawing.Size(163, 20);
|
||||
this.tbPcbSn.StyleController = this.layoutControl1;
|
||||
this.tbPcbSn.TabIndex = 23;
|
||||
//
|
||||
// btnOpenDbFolder
|
||||
//
|
||||
this.btnOpenDbFolder.Location = new System.Drawing.Point(876, 12);
|
||||
this.btnOpenDbFolder.Name = "btnOpenDbFolder";
|
||||
this.btnOpenDbFolder.Size = new System.Drawing.Size(111, 22);
|
||||
this.btnOpenDbFolder.StyleController = this.layoutControl1;
|
||||
this.btnOpenDbFolder.TabIndex = 22;
|
||||
this.btnOpenDbFolder.Text = "Open DB Folder";
|
||||
this.btnOpenDbFolder.Click += new System.EventHandler(this.btnOpenDbFolder_Click);
|
||||
//
|
||||
// edResultCount
|
||||
//
|
||||
this.edResultCount.Location = new System.Drawing.Point(89, 265);
|
||||
this.edResultCount.Name = "edResultCount";
|
||||
this.edResultCount.Size = new System.Drawing.Size(59, 20);
|
||||
this.edResultCount.StyleController = this.layoutControl1;
|
||||
this.edResultCount.TabIndex = 21;
|
||||
//
|
||||
// btnResultListClear
|
||||
//
|
||||
this.btnResultListClear.Location = new System.Drawing.Point(402, 265);
|
||||
this.btnResultListClear.Name = "btnResultListClear";
|
||||
this.btnResultListClear.Size = new System.Drawing.Size(89, 22);
|
||||
this.btnResultListClear.StyleController = this.layoutControl1;
|
||||
this.btnResultListClear.TabIndex = 20;
|
||||
this.btnResultListClear.Text = "Clear";
|
||||
this.btnResultListClear.Click += new System.EventHandler(this.btnResultListClear_Click);
|
||||
//
|
||||
// btnSearchPcbSn
|
||||
//
|
||||
this.btnSearchPcbSn.Location = new System.Drawing.Point(848, 265);
|
||||
this.btnSearchPcbSn.Name = "btnSearchPcbSn";
|
||||
this.btnSearchPcbSn.Size = new System.Drawing.Size(139, 22);
|
||||
this.btnSearchPcbSn.StyleController = this.layoutControl1;
|
||||
this.btnSearchPcbSn.TabIndex = 19;
|
||||
this.btnSearchPcbSn.Text = "Search PCB SN";
|
||||
this.btnSearchPcbSn.Click += new System.EventHandler(this.btnModuleResult_Click);
|
||||
//
|
||||
// btnOutputAll
|
||||
//
|
||||
this.btnOutputAll.Location = new System.Drawing.Point(897, 229);
|
||||
this.btnOutputAll.Name = "btnOutputAll";
|
||||
this.btnOutputAll.Size = new System.Drawing.Size(90, 32);
|
||||
this.btnOutputAll.StyleController = this.layoutControl1;
|
||||
this.btnOutputAll.TabIndex = 18;
|
||||
this.btnOutputAll.Text = "Output All";
|
||||
this.btnOutputAll.Click += new System.EventHandler(this.btnOutputAll_Click);
|
||||
//
|
||||
// btnCheckMeasData
|
||||
//
|
||||
this.btnCheckMeasData.Location = new System.Drawing.Point(740, 229);
|
||||
this.btnCheckMeasData.Name = "btnCheckMeasData";
|
||||
this.btnCheckMeasData.Size = new System.Drawing.Size(123, 32);
|
||||
this.btnCheckMeasData.StyleController = this.layoutControl1;
|
||||
this.btnCheckMeasData.TabIndex = 17;
|
||||
this.btnCheckMeasData.Text = "Check Measure";
|
||||
this.btnCheckMeasData.Click += new System.EventHandler(this.btnCheckMeasData_Click);
|
||||
//
|
||||
// btnCheckDimData
|
||||
//
|
||||
this.btnCheckDimData.Location = new System.Drawing.Point(867, 197);
|
||||
this.btnCheckDimData.Name = "btnCheckDimData";
|
||||
this.btnCheckDimData.Size = new System.Drawing.Size(120, 28);
|
||||
this.btnCheckDimData.StyleController = this.layoutControl1;
|
||||
this.btnCheckDimData.TabIndex = 16;
|
||||
this.btnCheckDimData.Text = "Module Value";
|
||||
this.btnCheckDimData.Click += new System.EventHandler(this.btnCheckDimData_Click);
|
||||
//
|
||||
// btnCheckGroupData
|
||||
//
|
||||
this.btnCheckGroupData.Location = new System.Drawing.Point(740, 197);
|
||||
this.btnCheckGroupData.Name = "btnCheckGroupData";
|
||||
this.btnCheckGroupData.Size = new System.Drawing.Size(123, 28);
|
||||
this.btnCheckGroupData.StyleController = this.layoutControl1;
|
||||
this.btnCheckGroupData.TabIndex = 15;
|
||||
this.btnCheckGroupData.Text = "Inventory Value";
|
||||
this.btnCheckGroupData.Click += new System.EventHandler(this.btnCheckGroupData_Click);
|
||||
//
|
||||
// cbResultList
|
||||
//
|
||||
this.cbResultList.Location = new System.Drawing.Point(237, 265);
|
||||
this.cbResultList.Name = "cbResultList";
|
||||
this.cbResultList.Properties.Appearance.Font = new System.Drawing.Font("Tahoma", 10F);
|
||||
this.cbResultList.Properties.Appearance.Options.UseFont = true;
|
||||
this.cbResultList.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
|
||||
new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)});
|
||||
this.cbResultList.Size = new System.Drawing.Size(161, 22);
|
||||
this.cbResultList.StyleController = this.layoutControl1;
|
||||
this.cbResultList.TabIndex = 14;
|
||||
this.cbResultList.SelectedIndexChanged += new System.EventHandler(this.cbResultList_SelectedIndexChanged);
|
||||
//
|
||||
// cbLotNo
|
||||
//
|
||||
this.cbLotNo.Location = new System.Drawing.Point(805, 147);
|
||||
this.cbLotNo.Name = "cbLotNo";
|
||||
this.cbLotNo.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
|
||||
new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)});
|
||||
this.cbLotNo.Size = new System.Drawing.Size(182, 20);
|
||||
this.cbLotNo.StyleController = this.layoutControl1;
|
||||
this.cbLotNo.TabIndex = 13;
|
||||
//
|
||||
// btnExcuteTCell
|
||||
//
|
||||
this.btnExcuteTCell.Location = new System.Drawing.Point(740, 171);
|
||||
this.btnExcuteTCell.Name = "btnExcuteTCell";
|
||||
this.btnExcuteTCell.Size = new System.Drawing.Size(247, 22);
|
||||
this.btnExcuteTCell.StyleController = this.layoutControl1;
|
||||
this.btnExcuteTCell.TabIndex = 12;
|
||||
this.btnExcuteTCell.Text = "SQL Excute";
|
||||
this.btnExcuteTCell.Click += new System.EventHandler(this.btnExcuteTCell_Click);
|
||||
//
|
||||
// gbDbCommnad
|
||||
//
|
||||
this.gbDbCommnad.Controls.Add(this.layoutControl2);
|
||||
this.gbDbCommnad.Location = new System.Drawing.Point(740, 38);
|
||||
this.gbDbCommnad.Name = "gbDbCommnad";
|
||||
this.gbDbCommnad.Size = new System.Drawing.Size(247, 105);
|
||||
this.gbDbCommnad.TabIndex = 11;
|
||||
this.gbDbCommnad.Text = "Management DB";
|
||||
//
|
||||
// layoutControl2
|
||||
//
|
||||
this.layoutControl2.Controls.Add(this.btnOpenSchema);
|
||||
this.layoutControl2.Controls.Add(this.btnBmsDuplicateCheck);
|
||||
this.layoutControl2.Controls.Add(this.btnQueryExcute);
|
||||
this.layoutControl2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl2.Location = new System.Drawing.Point(2, 23);
|
||||
this.layoutControl2.Name = "layoutControl2";
|
||||
this.layoutControl2.Root = this.layoutControlGroup2;
|
||||
this.layoutControl2.Size = new System.Drawing.Size(243, 80);
|
||||
this.layoutControl2.TabIndex = 0;
|
||||
this.layoutControl2.Text = "layoutControl2";
|
||||
//
|
||||
// btnOpenSchema
|
||||
//
|
||||
this.btnOpenSchema.Location = new System.Drawing.Point(3, 3);
|
||||
this.btnOpenSchema.Name = "btnOpenSchema";
|
||||
this.btnOpenSchema.Size = new System.Drawing.Size(237, 22);
|
||||
this.btnOpenSchema.StyleController = this.layoutControl2;
|
||||
this.btnOpenSchema.TabIndex = 8;
|
||||
this.btnOpenSchema.Text = "Open Schema";
|
||||
this.btnOpenSchema.Click += new System.EventHandler(this.btnOpenSchema_Click);
|
||||
//
|
||||
// btnBmsDuplicateCheck
|
||||
//
|
||||
this.btnBmsDuplicateCheck.Location = new System.Drawing.Point(3, 55);
|
||||
this.btnBmsDuplicateCheck.Name = "btnBmsDuplicateCheck";
|
||||
this.btnBmsDuplicateCheck.Size = new System.Drawing.Size(237, 22);
|
||||
this.btnBmsDuplicateCheck.StyleController = this.layoutControl2;
|
||||
this.btnBmsDuplicateCheck.TabIndex = 10;
|
||||
this.btnBmsDuplicateCheck.Text = "BMS Duplicate Check";
|
||||
this.btnBmsDuplicateCheck.Click += new System.EventHandler(this.btnBmsDuplicateCheck_Click);
|
||||
//
|
||||
// btnQueryExcute
|
||||
//
|
||||
this.btnQueryExcute.Location = new System.Drawing.Point(3, 29);
|
||||
this.btnQueryExcute.Name = "btnQueryExcute";
|
||||
this.btnQueryExcute.Size = new System.Drawing.Size(237, 22);
|
||||
this.btnQueryExcute.StyleController = this.layoutControl2;
|
||||
this.btnQueryExcute.TabIndex = 9;
|
||||
this.btnQueryExcute.Text = "Query Excute";
|
||||
this.btnQueryExcute.Click += new System.EventHandler(this.btnQueryExcute_Click);
|
||||
//
|
||||
// layoutControlGroup2
|
||||
//
|
||||
this.layoutControlGroup2.CustomizationFormText = "layoutControlGroup2";
|
||||
this.layoutControlGroup2.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.layoutControlGroup2.GroupBordersVisible = false;
|
||||
this.layoutControlGroup2.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem5,
|
||||
this.layoutControlItem6,
|
||||
this.layoutControlItem7});
|
||||
this.layoutControlGroup2.Name = "layoutControlGroup2";
|
||||
this.layoutControlGroup2.Padding = new DevExpress.XtraLayout.Utils.Padding(1, 1, 1, 1);
|
||||
this.layoutControlGroup2.Size = new System.Drawing.Size(243, 80);
|
||||
this.layoutControlGroup2.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem5
|
||||
//
|
||||
this.layoutControlItem5.Control = this.btnOpenSchema;
|
||||
this.layoutControlItem5.CustomizationFormText = "layoutControlItem5";
|
||||
this.layoutControlItem5.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem5.Name = "layoutControlItem5";
|
||||
this.layoutControlItem5.Size = new System.Drawing.Size(241, 26);
|
||||
this.layoutControlItem5.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem5.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem6
|
||||
//
|
||||
this.layoutControlItem6.Control = this.btnQueryExcute;
|
||||
this.layoutControlItem6.CustomizationFormText = "layoutControlItem6";
|
||||
this.layoutControlItem6.Location = new System.Drawing.Point(0, 26);
|
||||
this.layoutControlItem6.Name = "layoutControlItem6";
|
||||
this.layoutControlItem6.Size = new System.Drawing.Size(241, 26);
|
||||
this.layoutControlItem6.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem6.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem7
|
||||
//
|
||||
this.layoutControlItem7.Control = this.btnBmsDuplicateCheck;
|
||||
this.layoutControlItem7.CustomizationFormText = "layoutControlItem7";
|
||||
this.layoutControlItem7.Location = new System.Drawing.Point(0, 52);
|
||||
this.layoutControlItem7.Name = "layoutControlItem7";
|
||||
this.layoutControlItem7.Size = new System.Drawing.Size(241, 26);
|
||||
this.layoutControlItem7.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem7.TextVisible = false;
|
||||
//
|
||||
// tbSchema
|
||||
//
|
||||
this.tbSchema.Location = new System.Drawing.Point(12, 38);
|
||||
this.tbSchema.Multiline = true;
|
||||
this.tbSchema.Name = "tbSchema";
|
||||
this.tbSchema.ScrollBars = System.Windows.Forms.ScrollBars.Both;
|
||||
this.tbSchema.Size = new System.Drawing.Size(724, 223);
|
||||
this.tbSchema.TabIndex = 7;
|
||||
//
|
||||
// gridCell
|
||||
//
|
||||
this.gridCell.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
||||
this.gridCell.Location = new System.Drawing.Point(12, 291);
|
||||
this.gridCell.Name = "gridCell";
|
||||
this.gridCell.RowTemplate.Height = 23;
|
||||
this.gridCell.Size = new System.Drawing.Size(975, 275);
|
||||
this.gridCell.TabIndex = 6;
|
||||
//
|
||||
// btnFindFile
|
||||
//
|
||||
this.btnFindFile.Location = new System.Drawing.Point(740, 12);
|
||||
this.btnFindFile.Name = "btnFindFile";
|
||||
this.btnFindFile.Size = new System.Drawing.Size(132, 22);
|
||||
this.btnFindFile.StyleController = this.layoutControl1;
|
||||
this.btnFindFile.TabIndex = 5;
|
||||
this.btnFindFile.Text = "Find File ....";
|
||||
this.btnFindFile.Click += new System.EventHandler(this.btnFindFile_Click);
|
||||
//
|
||||
// edFileName
|
||||
//
|
||||
this.edFileName.Location = new System.Drawing.Point(89, 12);
|
||||
this.edFileName.Name = "edFileName";
|
||||
this.edFileName.Size = new System.Drawing.Size(647, 20);
|
||||
this.edFileName.StyleController = this.layoutControl1;
|
||||
this.edFileName.TabIndex = 4;
|
||||
//
|
||||
// layoutControlGroup1
|
||||
//
|
||||
this.layoutControlGroup1.CustomizationFormText = "layoutControlGroup1";
|
||||
this.layoutControlGroup1.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.layoutControlGroup1.GroupBordersVisible = false;
|
||||
this.layoutControlGroup1.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem1,
|
||||
this.layoutControlItem2,
|
||||
this.emptySpaceItem1,
|
||||
this.layoutControlItem3,
|
||||
this.layoutControlItem4,
|
||||
this.layoutControlItem8,
|
||||
this.layoutControlItem9,
|
||||
this.lcitemLot,
|
||||
this.layoutControlItem10,
|
||||
this.emptySpaceItem2,
|
||||
this.layoutControlItem11,
|
||||
this.layoutControlItem12,
|
||||
this.layoutControlItem13,
|
||||
this.layoutControlItem14,
|
||||
this.layoutControlItem15,
|
||||
this.layoutControlItem16,
|
||||
this.layoutControlItem18,
|
||||
this.layoutControlItem17,
|
||||
this.layoutControlItem19});
|
||||
this.layoutControlGroup1.Name = "layoutControlGroup1";
|
||||
this.layoutControlGroup1.Size = new System.Drawing.Size(999, 578);
|
||||
this.layoutControlGroup1.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem1
|
||||
//
|
||||
this.layoutControlItem1.Control = this.edFileName;
|
||||
this.layoutControlItem1.CustomizationFormText = "layoutControlItem1";
|
||||
this.layoutControlItem1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem1.MinSize = new System.Drawing.Size(162, 24);
|
||||
this.layoutControlItem1.Name = "layoutControlItem1";
|
||||
this.layoutControlItem1.Size = new System.Drawing.Size(728, 26);
|
||||
this.layoutControlItem1.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem1.Text = "File Name: ";
|
||||
this.layoutControlItem1.TextSize = new System.Drawing.Size(74, 14);
|
||||
//
|
||||
// layoutControlItem2
|
||||
//
|
||||
this.layoutControlItem2.Control = this.btnFindFile;
|
||||
this.layoutControlItem2.CustomizationFormText = "layoutControlItem2";
|
||||
this.layoutControlItem2.Location = new System.Drawing.Point(728, 0);
|
||||
this.layoutControlItem2.MinSize = new System.Drawing.Size(93, 26);
|
||||
this.layoutControlItem2.Name = "layoutControlItem2";
|
||||
this.layoutControlItem2.Size = new System.Drawing.Size(136, 26);
|
||||
this.layoutControlItem2.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem2.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem2.TextVisible = false;
|
||||
//
|
||||
// emptySpaceItem1
|
||||
//
|
||||
this.emptySpaceItem1.AllowHotTrack = false;
|
||||
this.emptySpaceItem1.CustomizationFormText = "emptySpaceItem1";
|
||||
this.emptySpaceItem1.Location = new System.Drawing.Point(855, 217);
|
||||
this.emptySpaceItem1.Name = "emptySpaceItem1";
|
||||
this.emptySpaceItem1.Size = new System.Drawing.Size(30, 36);
|
||||
this.emptySpaceItem1.TextSize = new System.Drawing.Size(0, 0);
|
||||
//
|
||||
// layoutControlItem3
|
||||
//
|
||||
this.layoutControlItem3.Control = this.gridCell;
|
||||
this.layoutControlItem3.CustomizationFormText = "layoutControlItem3";
|
||||
this.layoutControlItem3.Location = new System.Drawing.Point(0, 279);
|
||||
this.layoutControlItem3.MinSize = new System.Drawing.Size(104, 24);
|
||||
this.layoutControlItem3.Name = "layoutControlItem3";
|
||||
this.layoutControlItem3.Size = new System.Drawing.Size(979, 279);
|
||||
this.layoutControlItem3.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem3.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem3.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem4
|
||||
//
|
||||
this.layoutControlItem4.Control = this.tbSchema;
|
||||
this.layoutControlItem4.CustomizationFormText = "layoutControlItem4";
|
||||
this.layoutControlItem4.Location = new System.Drawing.Point(0, 26);
|
||||
this.layoutControlItem4.MinSize = new System.Drawing.Size(132, 24);
|
||||
this.layoutControlItem4.Name = "layoutControlItem4";
|
||||
this.layoutControlItem4.Size = new System.Drawing.Size(728, 227);
|
||||
this.layoutControlItem4.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem4.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem4.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem8
|
||||
//
|
||||
this.layoutControlItem8.Control = this.gbDbCommnad;
|
||||
this.layoutControlItem8.CustomizationFormText = "layoutControlItem8";
|
||||
this.layoutControlItem8.Location = new System.Drawing.Point(728, 26);
|
||||
this.layoutControlItem8.Name = "layoutControlItem8";
|
||||
this.layoutControlItem8.Size = new System.Drawing.Size(251, 109);
|
||||
this.layoutControlItem8.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem8.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem9
|
||||
//
|
||||
this.layoutControlItem9.Control = this.btnExcuteTCell;
|
||||
this.layoutControlItem9.CustomizationFormText = "layoutControlItem9";
|
||||
this.layoutControlItem9.Location = new System.Drawing.Point(728, 159);
|
||||
this.layoutControlItem9.Name = "layoutControlItem9";
|
||||
this.layoutControlItem9.Size = new System.Drawing.Size(251, 26);
|
||||
this.layoutControlItem9.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem9.TextVisible = false;
|
||||
//
|
||||
// lcitemLot
|
||||
//
|
||||
this.lcitemLot.Control = this.cbLotNo;
|
||||
this.lcitemLot.CustomizationFormText = " Lot No";
|
||||
this.lcitemLot.Location = new System.Drawing.Point(728, 135);
|
||||
this.lcitemLot.Name = "lcitemLot";
|
||||
this.lcitemLot.Size = new System.Drawing.Size(251, 24);
|
||||
this.lcitemLot.Text = " Lot No";
|
||||
this.lcitemLot.TextAlignMode = DevExpress.XtraLayout.TextAlignModeItem.CustomSize;
|
||||
this.lcitemLot.TextSize = new System.Drawing.Size(60, 14);
|
||||
this.lcitemLot.TextToControlDistance = 5;
|
||||
//
|
||||
// layoutControlItem10
|
||||
//
|
||||
this.layoutControlItem10.Control = this.cbResultList;
|
||||
this.layoutControlItem10.CustomizationFormText = " Result List";
|
||||
this.layoutControlItem10.Location = new System.Drawing.Point(140, 253);
|
||||
this.layoutControlItem10.MaxSize = new System.Drawing.Size(0, 26);
|
||||
this.layoutControlItem10.MinSize = new System.Drawing.Size(187, 26);
|
||||
this.layoutControlItem10.Name = "layoutControlItem10";
|
||||
this.layoutControlItem10.Size = new System.Drawing.Size(250, 26);
|
||||
this.layoutControlItem10.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem10.Text = " Result List";
|
||||
this.layoutControlItem10.TextAlignMode = DevExpress.XtraLayout.TextAlignModeItem.CustomSize;
|
||||
this.layoutControlItem10.TextSize = new System.Drawing.Size(80, 14);
|
||||
this.layoutControlItem10.TextToControlDistance = 5;
|
||||
//
|
||||
// emptySpaceItem2
|
||||
//
|
||||
this.emptySpaceItem2.AllowHotTrack = false;
|
||||
this.emptySpaceItem2.CustomizationFormText = "emptySpaceItem2";
|
||||
this.emptySpaceItem2.Location = new System.Drawing.Point(483, 253);
|
||||
this.emptySpaceItem2.Name = "emptySpaceItem2";
|
||||
this.emptySpaceItem2.Size = new System.Drawing.Size(109, 26);
|
||||
this.emptySpaceItem2.TextSize = new System.Drawing.Size(0, 0);
|
||||
//
|
||||
// layoutControlItem11
|
||||
//
|
||||
this.layoutControlItem11.Control = this.btnCheckGroupData;
|
||||
this.layoutControlItem11.CustomizationFormText = "layoutControlItem11";
|
||||
this.layoutControlItem11.Location = new System.Drawing.Point(728, 185);
|
||||
this.layoutControlItem11.MinSize = new System.Drawing.Size(93, 26);
|
||||
this.layoutControlItem11.Name = "layoutControlItem11";
|
||||
this.layoutControlItem11.Size = new System.Drawing.Size(127, 32);
|
||||
this.layoutControlItem11.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem11.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem11.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem12
|
||||
//
|
||||
this.layoutControlItem12.Control = this.btnCheckDimData;
|
||||
this.layoutControlItem12.CustomizationFormText = "layoutControlItem12";
|
||||
this.layoutControlItem12.Location = new System.Drawing.Point(855, 185);
|
||||
this.layoutControlItem12.MinSize = new System.Drawing.Size(93, 26);
|
||||
this.layoutControlItem12.Name = "layoutControlItem12";
|
||||
this.layoutControlItem12.Size = new System.Drawing.Size(124, 32);
|
||||
this.layoutControlItem12.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem12.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem12.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem13
|
||||
//
|
||||
this.layoutControlItem13.Control = this.btnCheckMeasData;
|
||||
this.layoutControlItem13.CustomizationFormText = "layoutControlItem13";
|
||||
this.layoutControlItem13.Location = new System.Drawing.Point(728, 217);
|
||||
this.layoutControlItem13.MinSize = new System.Drawing.Size(93, 26);
|
||||
this.layoutControlItem13.Name = "layoutControlItem13";
|
||||
this.layoutControlItem13.Size = new System.Drawing.Size(127, 36);
|
||||
this.layoutControlItem13.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem13.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem13.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem14
|
||||
//
|
||||
this.layoutControlItem14.Control = this.btnOutputAll;
|
||||
this.layoutControlItem14.CustomizationFormText = "layoutControlItem14";
|
||||
this.layoutControlItem14.Location = new System.Drawing.Point(885, 217);
|
||||
this.layoutControlItem14.MinSize = new System.Drawing.Size(93, 26);
|
||||
this.layoutControlItem14.Name = "layoutControlItem14";
|
||||
this.layoutControlItem14.Size = new System.Drawing.Size(94, 36);
|
||||
this.layoutControlItem14.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem14.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem14.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem15
|
||||
//
|
||||
this.layoutControlItem15.Control = this.btnSearchPcbSn;
|
||||
this.layoutControlItem15.CustomizationFormText = "layoutControlItem15";
|
||||
this.layoutControlItem15.Location = new System.Drawing.Point(836, 253);
|
||||
this.layoutControlItem15.MinSize = new System.Drawing.Size(93, 26);
|
||||
this.layoutControlItem15.Name = "layoutControlItem15";
|
||||
this.layoutControlItem15.Size = new System.Drawing.Size(143, 26);
|
||||
this.layoutControlItem15.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem15.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem15.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem16
|
||||
//
|
||||
this.layoutControlItem16.Control = this.btnResultListClear;
|
||||
this.layoutControlItem16.CustomizationFormText = "layoutControlItem16";
|
||||
this.layoutControlItem16.Location = new System.Drawing.Point(390, 253);
|
||||
this.layoutControlItem16.MinSize = new System.Drawing.Size(93, 26);
|
||||
this.layoutControlItem16.Name = "layoutControlItem16";
|
||||
this.layoutControlItem16.Size = new System.Drawing.Size(93, 26);
|
||||
this.layoutControlItem16.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem16.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem16.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem18
|
||||
//
|
||||
this.layoutControlItem18.Control = this.btnOpenDbFolder;
|
||||
this.layoutControlItem18.Location = new System.Drawing.Point(864, 0);
|
||||
this.layoutControlItem18.Name = "layoutControlItem18";
|
||||
this.layoutControlItem18.Size = new System.Drawing.Size(115, 26);
|
||||
this.layoutControlItem18.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem18.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem17
|
||||
//
|
||||
this.layoutControlItem17.Control = this.edResultCount;
|
||||
this.layoutControlItem17.CustomizationFormText = "layoutControlItem17";
|
||||
this.layoutControlItem17.Location = new System.Drawing.Point(0, 253);
|
||||
this.layoutControlItem17.MinSize = new System.Drawing.Size(54, 24);
|
||||
this.layoutControlItem17.Name = "layoutControlItem17";
|
||||
this.layoutControlItem17.Size = new System.Drawing.Size(140, 26);
|
||||
this.layoutControlItem17.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem17.Text = "Result Count ";
|
||||
this.layoutControlItem17.TextSize = new System.Drawing.Size(74, 14);
|
||||
//
|
||||
// layoutControlItem19
|
||||
//
|
||||
this.layoutControlItem19.Control = this.tbPcbSn;
|
||||
this.layoutControlItem19.Location = new System.Drawing.Point(592, 253);
|
||||
this.layoutControlItem19.MinSize = new System.Drawing.Size(131, 24);
|
||||
this.layoutControlItem19.Name = "layoutControlItem19";
|
||||
this.layoutControlItem19.Size = new System.Drawing.Size(244, 26);
|
||||
this.layoutControlItem19.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem19.Text = "PCB SN";
|
||||
this.layoutControlItem19.TextSize = new System.Drawing.Size(74, 14);
|
||||
//
|
||||
// fmxExcelFile
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(999, 578);
|
||||
this.Controls.Add(this.layoutControl1);
|
||||
this.IconOptions.Icon = ((System.Drawing.Icon)(resources.GetObject("fmxExcelFile.IconOptions.Icon")));
|
||||
this.Name = "fmxExcelFile";
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
|
||||
this.Text = "Database Control";
|
||||
this.Load += new System.EventHandler(this.fmxExcelFile_Load);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).EndInit();
|
||||
this.layoutControl1.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.tbPcbSn.Properties)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.edResultCount.Properties)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.cbResultList.Properties)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.cbLotNo.Properties)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.gbDbCommnad)).EndInit();
|
||||
this.gbDbCommnad.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl2)).EndInit();
|
||||
this.layoutControl2.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup2)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.gridCell)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.edFileName.Properties)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.lcitemLot)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem10)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem2)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem11)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem12)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem13)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem14)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem15)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem16)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem18)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem17)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem19)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl1;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup1;
|
||||
private DevExpress.XtraEditors.SimpleButton btnFindFile;
|
||||
private DevExpress.XtraEditors.TextEdit edFileName;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem1;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem2;
|
||||
private DevExpress.XtraLayout.EmptySpaceItem emptySpaceItem1;
|
||||
private System.Windows.Forms.DataGridView gridCell;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem3;
|
||||
private System.Windows.Forms.TextBox tbSchema;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem4;
|
||||
private DevExpress.XtraEditors.SimpleButton btnOpenSchema;
|
||||
private DevExpress.XtraEditors.SimpleButton btnQueryExcute;
|
||||
private DevExpress.XtraEditors.SimpleButton btnBmsDuplicateCheck;
|
||||
private DevExpress.XtraEditors.GroupControl gbDbCommnad;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem8;
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl2;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup2;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem5;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem6;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem7;
|
||||
private DevExpress.XtraEditors.SimpleButton btnExcuteTCell;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem9;
|
||||
private DevExpress.XtraEditors.ComboBoxEdit cbLotNo;
|
||||
private DevExpress.XtraLayout.LayoutControlItem lcitemLot;
|
||||
private DevExpress.XtraEditors.ComboBoxEdit cbResultList;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem10;
|
||||
private DevExpress.XtraLayout.EmptySpaceItem emptySpaceItem2;
|
||||
private DevExpress.XtraEditors.SimpleButton btnCheckGroupData;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem11;
|
||||
private DevExpress.XtraEditors.SimpleButton btnCheckDimData;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem12;
|
||||
private DevExpress.XtraEditors.SimpleButton btnCheckMeasData;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem13;
|
||||
private DevExpress.XtraEditors.SimpleButton btnOutputAll;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem14;
|
||||
private DevExpress.XtraEditors.SimpleButton btnSearchPcbSn;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem15;
|
||||
private DevExpress.XtraEditors.SimpleButton btnResultListClear;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem16;
|
||||
private DevExpress.XtraEditors.TextEdit edResultCount;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem17;
|
||||
private DevExpress.XtraEditors.SimpleButton btnOpenDbFolder;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem18;
|
||||
private DevExpress.XtraEditors.TextEdit tbPcbSn;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem19;
|
||||
}
|
||||
}
|
||||
391
LFP_Manager_PRM/Forms/fmxExcelFile.cs
Normal file
391
LFP_Manager_PRM/Forms/fmxExcelFile.cs
Normal file
@@ -0,0 +1,391 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Text;
|
||||
using System.Linq;
|
||||
using System.Windows.Forms;
|
||||
using DevExpress.XtraEditors;
|
||||
using System.Data.SQLite;
|
||||
|
||||
using System.IO;
|
||||
|
||||
using System.Data.OleDb;
|
||||
using LFP_Manager.DataStructure;
|
||||
using LFP_Manager.Function;
|
||||
using LFP_Manager.Utils;
|
||||
using DevExpress.Utils.FormShadow;
|
||||
|
||||
namespace LFP_Manager
|
||||
{
|
||||
public partial class fmxExcelFile : DevExpress.XtraEditors.XtraForm
|
||||
{
|
||||
#region VARIABLES
|
||||
|
||||
CommConfig Config;
|
||||
string[] dbFiles;
|
||||
//private string Excel03ConString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source={0};Extended Properties='Excel 8.0;HDR={1}'";
|
||||
//private string Excel07ConString = "Provider=Microsoft.ACE.OLEDB.12.0;Data Source={0};Extended Properties='Excel 8.0;HDR={1}'";
|
||||
//Workbook workbook;
|
||||
DataSet dsCell;
|
||||
DataTable dtCell;
|
||||
|
||||
#endregion
|
||||
|
||||
#region CONSTRUCTORS
|
||||
|
||||
public fmxExcelFile(CommConfig aConfig)
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
Config = aConfig;
|
||||
|
||||
//tbSchema.Text = "select * from TInventoryData" + "\r\n" + "where pcb_sn like 'BMU18SA20120169%'";
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region FORM EVENT
|
||||
private void fmxExcelFile_Load(object sender, EventArgs e)
|
||||
{
|
||||
string dbfilePath = Path.GetDirectoryName(Application.ExecutablePath) + @"\db";
|
||||
dbFiles = Directory.GetFiles(dbfilePath, "*.db", SearchOption.AllDirectories);
|
||||
|
||||
if (dbFiles.Length > 0)
|
||||
{
|
||||
for (int i = 0; i < dbFiles.Length; i++)
|
||||
{
|
||||
cbLotNo.Properties.Items.Add(Path.GetFileName(dbFiles[i]));
|
||||
}
|
||||
cbLotNo.SelectedIndex = 0;
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
// Copy Table Value
|
||||
// INSERT INTO TModuleResultBak SELECT * FROM TModuleResult
|
||||
// INSERT INTO [TModuleBmsBak] (sn, result, module_ocv_b) SELECT sn, result, module_ocv_b FROM TModuleBms
|
||||
|
||||
#region BUTTON EVENT
|
||||
private void btnFindFile_Click(object sender, EventArgs e)
|
||||
{
|
||||
OpenFileDialog oDialog = new OpenFileDialog();
|
||||
oDialog.DefaultExt = "*.*";
|
||||
oDialog.Filter = "excel files 2003 (*.xls)|*.xls|excel files 2007 (*.xlsx)|*.xlsx|All files (*.*)|*.*";
|
||||
|
||||
if (oDialog.ShowDialog() == DialogResult.OK)
|
||||
{
|
||||
edFileName.Text = oDialog.FileName;
|
||||
|
||||
try
|
||||
{
|
||||
dsCell = csExcelControl.OpenExcelDB(edFileName.Text);
|
||||
|
||||
cbResultList.Properties.Items.Clear();
|
||||
for (int i = 0; i < dsCell.Tables.Count; i++)
|
||||
{
|
||||
cbResultList.Properties.Items.Add(dsCell.Tables[i].TableName);
|
||||
}
|
||||
cbResultList.SelectedIndex = 0;
|
||||
|
||||
dtCell = dsCell.Tables[0];
|
||||
|
||||
gridCell.DataSource = dtCell;
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
MessageBox.Show(ex.Message, "Exception", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void btnExcuteTCell_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (tbSchema.Text != string.Empty)
|
||||
{
|
||||
try
|
||||
{
|
||||
//string path = cbLotNo.Text.Substring(0, 9);
|
||||
//string path = cbLotNo.Text;
|
||||
string path = dbFiles[cbLotNo.SelectedIndex];
|
||||
DataTable aaa = csDbUtils.DbSqlExcuteA3(path, tbSchema.Text);
|
||||
if (aaa != null)
|
||||
{
|
||||
gridCell.DataSource = aaa;
|
||||
edResultCount.Text = String.Format("{0}", aaa.Rows.Count);
|
||||
|
||||
if (aaa.Rows.Count > 0)
|
||||
{
|
||||
var ddd = aaa.Rows[0]["pcb_sn"];
|
||||
byte[] ccc = Encoding.UTF8.GetBytes(ddd.ToString());
|
||||
}
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
MessageBox.Show(ex.Message, "Exception", MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void btnOpenSchema_Click(object sender, EventArgs e)
|
||||
{
|
||||
OpenFileDialog oDialog = new OpenFileDialog();
|
||||
oDialog.DefaultExt = "*.*";
|
||||
oDialog.Filter = "sql files (*.sql)|*.sql|All files (*.*)|*.*";
|
||||
|
||||
if (oDialog.ShowDialog() == DialogResult.OK)
|
||||
{
|
||||
string text = System.IO.File.ReadAllText(oDialog.FileName);
|
||||
tbSchema.Text = text;
|
||||
}
|
||||
}
|
||||
|
||||
private void btnQueryExcute_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (tbSchema.Text != string.Empty)
|
||||
{
|
||||
gridCell.DataSource = csDbUtils.DbSqlExcuteA(Config, Application.ExecutablePath, tbSchema.Text);
|
||||
}
|
||||
}
|
||||
|
||||
private void btnInsertDbByTable_Click(object sender, EventArgs e)
|
||||
{
|
||||
}
|
||||
|
||||
private void btnCheckGroupData_Click(object sender, EventArgs e)
|
||||
{
|
||||
tbSchema.Text = "select * from TInventoryData";
|
||||
}
|
||||
|
||||
private void btnCheckDimData_Click(object sender, EventArgs e)
|
||||
{
|
||||
tbSchema.Text = "select * from TModuleValue";
|
||||
}
|
||||
|
||||
private void btnCheckMeasData_Click(object sender, EventArgs e)
|
||||
{
|
||||
tbSchema.Text = "select * from TModuleMeasurement";
|
||||
}
|
||||
private void btnOutputAll_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (cbResultList.Properties.Items.Count > 0)
|
||||
{
|
||||
for (int i = 0; i < cbResultList.Properties.Items.Count; i++)
|
||||
{
|
||||
string sn = cbResultList.Properties.Items[i].ToString();
|
||||
MakeOutpuDataExcel(sn, cbLotNo.Text);
|
||||
}
|
||||
}
|
||||
}
|
||||
private void btnModuleResult_Click(object sender, EventArgs e)
|
||||
{
|
||||
//
|
||||
try
|
||||
{
|
||||
string dbFilePath = dbFiles[cbLotNo.SelectedIndex];
|
||||
string sql = String.Format("SELECT * FROM TInventoryData")
|
||||
+ String.Format(" where pcb_sn like '{0}%'", tbPcbSn.Text)
|
||||
;
|
||||
DataTable dtBmsData = csDbUtils.DbSqlExcuteA3(dbFilePath, sql);
|
||||
dtBmsData.TableName = "TInventoryData";
|
||||
|
||||
if ((dtBmsData != null) && (dtBmsData.Rows.Count > 0))
|
||||
{
|
||||
cbResultList.Properties.Items.Clear();
|
||||
|
||||
for (int i = 0; i < dtBmsData.Rows.Count; i++)
|
||||
{
|
||||
cbResultList.Properties.Items.Add(String.Format("{0}", dtBmsData.Rows[i]["pcb_sn"]));
|
||||
}
|
||||
gridCell.DataSource = dtBmsData;
|
||||
edResultCount.Text = dtBmsData.Rows.Count.ToString();
|
||||
cbResultList.SelectedIndex = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
MessageBox.Show(String.Format("No TModuleResult data - {0}", dbFilePath));
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
MessageBox.Show(ex.Message);
|
||||
}
|
||||
}
|
||||
private void btnResultListClear_Click(object sender, EventArgs e)
|
||||
{
|
||||
cbResultList.Properties.Items.Clear();
|
||||
}
|
||||
|
||||
private void btnBmsDuplicateCheck_Click(object sender, EventArgs e)
|
||||
{
|
||||
List<string> result = new List<string>();
|
||||
DateTime aDate = DateTime.Now;
|
||||
|
||||
DataTable dtBattPropValue = new DataTable();
|
||||
DataTable dtBmsMatch = new DataTable();
|
||||
DataTable dtErrorLog = new DataTable();
|
||||
|
||||
string dbFilePath = dbFiles[cbLotNo.SelectedIndex]; ;
|
||||
string sql;
|
||||
|
||||
sql = String.Format("SELECT * FROM TBattPropValue");
|
||||
dtBattPropValue = csDbUtils.DbSqlExcuteA3(dbFilePath, sql);
|
||||
dtBattPropValue.TableName = "TBattPropValue";
|
||||
|
||||
if (dtBattPropValue.Rows.Count == 0)
|
||||
{
|
||||
MessageBox.Show("No Battery Property Vaule data", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
return;
|
||||
}
|
||||
|
||||
Forms.fmxWait WaitForm = new Forms.fmxWait
|
||||
{
|
||||
StartPosition = FormStartPosition.CenterScreen
|
||||
};
|
||||
|
||||
try
|
||||
{
|
||||
WaitForm.Show();
|
||||
|
||||
sql = String.Format("SELECT * FROM TBmsPcbMatchTable");
|
||||
dtBmsMatch = csDbUtils.DbSqlExcuteA3(dbFilePath, sql);
|
||||
dtBmsMatch.TableName = "TBmsPcbMatchTable";
|
||||
|
||||
for (int i = 0; i < dtBattPropValue.Rows.Count; i++)
|
||||
{
|
||||
try
|
||||
{
|
||||
csDbUtils.BmsPcbMatchDataInsert(dbFilePath, dtBattPropValue.Rows[i]);
|
||||
}
|
||||
catch (SQLiteException sqle)
|
||||
{
|
||||
// Handle DB exception
|
||||
string eMsg = String.Format("[{0}]{1} - [{2:##0}] - {3}", sqle.ErrorCode, sqle.Message, i, dtBattPropValue.Rows[i]["PCB1_SERIAL_NUMBER"]);
|
||||
result.Add(eMsg);
|
||||
csDbUtils.ErrorLogInsert(dbFilePath, dtBattPropValue.Rows[i], "DUPLICATION CHECK", "SQLiteException", eMsg);
|
||||
}
|
||||
catch (IndexOutOfRangeException ie)
|
||||
{
|
||||
// If you think there might be a problem with index range in the loop, for example
|
||||
string eMsg = String.Format("{0} - [{1:##0}] - {2}", ie.Message, i, dtBattPropValue.Rows[i]["PCB1_SERIAL_NUMBER"]);
|
||||
result.Add(eMsg);
|
||||
csDbUtils.ErrorLogInsert(dbFilePath, dtBattPropValue.Rows[i], "DUPLICATION CHECK", "IndexOutOfRangeException", eMsg);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
string eMsg = String.Format("{0} - [{1:##0}] - {2}", ex.Message, i, dtBattPropValue.Rows[i]["PCB1_SERIAL_NUMBER"]);
|
||||
result.Add(eMsg);
|
||||
csDbUtils.ErrorLogInsert(dbFilePath, dtBattPropValue.Rows[i], "DUPLICATION CHECK", "Exception", eMsg);
|
||||
}
|
||||
WaitForm.SetDescription(String.Format("{0}//{1}", i + 1, dtBattPropValue.Rows.Count));
|
||||
System.Windows.Forms.Application.DoEvents();
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
MessageBox.Show(ex.Message, "Exception", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
return;
|
||||
}
|
||||
finally
|
||||
{
|
||||
sql = String.Format("SELECT * FROM TErrorLogTable");
|
||||
dtErrorLog = csDbUtils.DbSqlExcuteA3(dbFilePath, sql);
|
||||
dtErrorLog.TableName = "TErrorLogTable";
|
||||
|
||||
gridCell.DataSource = dtErrorLog;
|
||||
|
||||
if (WaitForm != null)
|
||||
WaitForm.Close();
|
||||
}
|
||||
}
|
||||
|
||||
private void btnOpenDbFolder_Click(object sender, EventArgs e)
|
||||
{
|
||||
System.Diagnostics.Process ps = new System.Diagnostics.Process();
|
||||
ps.StartInfo.FileName = "explorer.exe";
|
||||
ps.StartInfo.Arguments = csDbUtils.GetDbFolder(Application.ExecutablePath);
|
||||
ps.StartInfo.WorkingDirectory = csDbUtils.GetDbFolder(Application.ExecutablePath);
|
||||
ps.StartInfo.WindowStyle = System.Diagnostics.ProcessWindowStyle.Normal;
|
||||
|
||||
ps.Start();
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region COMPONENT EVETNT
|
||||
private void cbResultList_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
string tbName = "";
|
||||
tbName = cbResultList.Text;
|
||||
|
||||
if ((dtCell != null) && (dtCell.Rows.Count > 0))
|
||||
{
|
||||
if (tbName != "")
|
||||
{
|
||||
int index = cbResultList.SelectedIndex;
|
||||
dtCell = dsCell.Tables[index];
|
||||
gridCell.DataSource = dtCell;
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region MAKE OUTPUT FUNCTION
|
||||
private void MakeOutpuDataExcel(string mSN, string dbFile)
|
||||
{
|
||||
DateTime aDate = DateTime.Now;
|
||||
string filename = String.Format("{0}_PR_57150.xls", mSN);
|
||||
string filepath =
|
||||
Path.GetDirectoryName(Application.ExecutablePath)
|
||||
+ String.Format(@"\output\{0}\", csDbUtils.MakeMdSnLotNumber(mSN))
|
||||
+ filename;
|
||||
|
||||
DataTable dtModuleResult = new DataTable();
|
||||
DataTable dtCellResult = new DataTable();
|
||||
|
||||
string sql;
|
||||
sql = String.Format("SELECT * FROM TModuleResult where m_sn = {0}", mSN);
|
||||
dtModuleResult = csDbUtils.GetDataTableBySelectFromDbName(dbFile, sql, "TModuleResult");
|
||||
dtModuleResult.TableName = "TModuleResult";
|
||||
dtModuleResult.AcceptChanges();
|
||||
|
||||
sql = String.Format("SELECT * FROM TCellResult where m_sn = {0}", mSN);
|
||||
dtCellResult = csDbUtils.GetDataTableBySelectFromDbName(dbFile, sql, "TCellResult");
|
||||
dtCellResult.TableName = "TCellResult";
|
||||
dtCellResult.AcceptChanges();
|
||||
|
||||
if (dtModuleResult.Rows.Count == 0) throw new Exception(String.Format("No ModuleResult data ({0})", mSN));
|
||||
if (dtCellResult.Rows.Count == 0) throw new Exception(String.Format("No CellResult data ({0})", mSN));
|
||||
|
||||
csExcelExport.ExportToExcel(dtModuleResult, filepath);
|
||||
csExcelExport.ExportToExcel(dtCellResult, filepath, false);
|
||||
}
|
||||
|
||||
private DataTable GetModuleResultTable(string dbFileName)
|
||||
{
|
||||
DateTime aDate = DateTime.Now;
|
||||
|
||||
DataTable dtModuleResult = new DataTable();
|
||||
|
||||
string sql;
|
||||
sql = String.Format("SELECT * FROM TModuleResult");
|
||||
dtModuleResult = csDbUtils.GetDataTableBySelectFromDbName(dbFileName, sql, "TModuleResult");
|
||||
dtModuleResult.TableName = "TModuleResult";
|
||||
dtModuleResult.AcceptChanges();
|
||||
|
||||
if (dtModuleResult.Rows.Count == 0) throw new Exception(String.Format("No ModuleResult data ({0})", dbFileName));
|
||||
|
||||
return dtModuleResult;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
|
||||
private void MakeBattPropValue()
|
||||
{
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
4571
LFP_Manager_PRM/Forms/fmxExcelFile.resx
Normal file
4571
LFP_Manager_PRM/Forms/fmxExcelFile.resx
Normal file
File diff suppressed because it is too large
Load Diff
291
LFP_Manager_PRM/Forms/fmxFwImageConverter.Designer.cs
generated
Normal file
291
LFP_Manager_PRM/Forms/fmxFwImageConverter.Designer.cs
generated
Normal file
@@ -0,0 +1,291 @@
|
||||
namespace LFP_Manager
|
||||
{
|
||||
partial class fmxFwImageConverter
|
||||
{
|
||||
/// <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(fmxFwImageConverter));
|
||||
this.layoutControl1 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.lbFileInfo = new System.Windows.Forms.Label();
|
||||
this.btnClose = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.btnConvert = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.btnFileFind = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.teFileName = new DevExpress.XtraEditors.TextEdit();
|
||||
this.layoutControlGroup1 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.lcItemFileName = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.emptySpaceItem1 = new DevExpress.XtraLayout.EmptySpaceItem();
|
||||
this.layoutControlItem1 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.lbFileName = new DevExpress.XtraLayout.SimpleLabelItem();
|
||||
this.emptySpaceItem2 = new DevExpress.XtraLayout.EmptySpaceItem();
|
||||
this.layoutControlItem6 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem7 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem8 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).BeginInit();
|
||||
this.layoutControl1.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.teFileName.Properties)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.lcItemFileName)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.lbFileName)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem2)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// layoutControl1
|
||||
//
|
||||
this.layoutControl1.Controls.Add(this.lbFileInfo);
|
||||
this.layoutControl1.Controls.Add(this.btnClose);
|
||||
this.layoutControl1.Controls.Add(this.btnConvert);
|
||||
this.layoutControl1.Controls.Add(this.btnFileFind);
|
||||
this.layoutControl1.Controls.Add(this.teFileName);
|
||||
this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControl1.Name = "layoutControl1";
|
||||
this.layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(995, 203, 250, 350);
|
||||
this.layoutControl1.Root = this.layoutControlGroup1;
|
||||
this.layoutControl1.Size = new System.Drawing.Size(503, 333);
|
||||
this.layoutControl1.TabIndex = 0;
|
||||
this.layoutControl1.Text = "layoutControl1";
|
||||
//
|
||||
// lbFileInfo
|
||||
//
|
||||
this.lbFileInfo.Location = new System.Drawing.Point(12, 70);
|
||||
this.lbFileInfo.Name = "lbFileInfo";
|
||||
this.lbFileInfo.Size = new System.Drawing.Size(295, 214);
|
||||
this.lbFileInfo.TabIndex = 12;
|
||||
this.lbFileInfo.Text = "File Information";
|
||||
//
|
||||
// btnClose
|
||||
//
|
||||
this.btnClose.Location = new System.Drawing.Point(254, 288);
|
||||
this.btnClose.Name = "btnClose";
|
||||
this.btnClose.Size = new System.Drawing.Size(237, 33);
|
||||
this.btnClose.StyleController = this.layoutControl1;
|
||||
this.btnClose.TabIndex = 11;
|
||||
this.btnClose.Text = "Close";
|
||||
this.btnClose.Click += new System.EventHandler(this.btnClose_Click);
|
||||
//
|
||||
// btnConvert
|
||||
//
|
||||
this.btnConvert.Location = new System.Drawing.Point(12, 288);
|
||||
this.btnConvert.Name = "btnConvert";
|
||||
this.btnConvert.Size = new System.Drawing.Size(238, 33);
|
||||
this.btnConvert.StyleController = this.layoutControl1;
|
||||
this.btnConvert.TabIndex = 10;
|
||||
this.btnConvert.Text = "Image Convert";
|
||||
this.btnConvert.Click += new System.EventHandler(this.btnConvert_Click);
|
||||
//
|
||||
// btnFileFind
|
||||
//
|
||||
this.btnFileFind.Location = new System.Drawing.Point(402, 12);
|
||||
this.btnFileFind.Name = "btnFileFind";
|
||||
this.btnFileFind.Size = new System.Drawing.Size(89, 25);
|
||||
this.btnFileFind.StyleController = this.layoutControl1;
|
||||
this.btnFileFind.TabIndex = 5;
|
||||
this.btnFileFind.Text = "Find ...";
|
||||
this.btnFileFind.Click += new System.EventHandler(this.btnFileFind_Click);
|
||||
//
|
||||
// teFileName
|
||||
//
|
||||
this.teFileName.Location = new System.Drawing.Point(92, 12);
|
||||
this.teFileName.Name = "teFileName";
|
||||
this.teFileName.Properties.Appearance.Font = new System.Drawing.Font("Tahoma", 11F);
|
||||
this.teFileName.Properties.Appearance.Options.UseFont = true;
|
||||
this.teFileName.Size = new System.Drawing.Size(306, 24);
|
||||
this.teFileName.StyleController = this.layoutControl1;
|
||||
this.teFileName.TabIndex = 4;
|
||||
//
|
||||
// layoutControlGroup1
|
||||
//
|
||||
this.layoutControlGroup1.CustomizationFormText = "Root";
|
||||
this.layoutControlGroup1.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.layoutControlGroup1.GroupBordersVisible = false;
|
||||
this.layoutControlGroup1.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.lcItemFileName,
|
||||
this.emptySpaceItem1,
|
||||
this.layoutControlItem1,
|
||||
this.lbFileName,
|
||||
this.emptySpaceItem2,
|
||||
this.layoutControlItem6,
|
||||
this.layoutControlItem7,
|
||||
this.layoutControlItem8});
|
||||
this.layoutControlGroup1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlGroup1.Name = "Root";
|
||||
this.layoutControlGroup1.Size = new System.Drawing.Size(503, 333);
|
||||
this.layoutControlGroup1.Text = "Root";
|
||||
this.layoutControlGroup1.TextVisible = false;
|
||||
//
|
||||
// lcItemFileName
|
||||
//
|
||||
this.lcItemFileName.Control = this.teFileName;
|
||||
this.lcItemFileName.CustomizationFormText = "File Name : ";
|
||||
this.lcItemFileName.Location = new System.Drawing.Point(80, 0);
|
||||
this.lcItemFileName.MaxSize = new System.Drawing.Size(0, 29);
|
||||
this.lcItemFileName.MinSize = new System.Drawing.Size(163, 29);
|
||||
this.lcItemFileName.Name = "lcItemFileName";
|
||||
this.lcItemFileName.Size = new System.Drawing.Size(310, 29);
|
||||
this.lcItemFileName.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.lcItemFileName.Text = "File Name : ";
|
||||
this.lcItemFileName.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.lcItemFileName.TextToControlDistance = 0;
|
||||
this.lcItemFileName.TextVisible = false;
|
||||
//
|
||||
// emptySpaceItem1
|
||||
//
|
||||
this.emptySpaceItem1.AllowHotTrack = false;
|
||||
this.emptySpaceItem1.CustomizationFormText = "emptySpaceItem1";
|
||||
this.emptySpaceItem1.Location = new System.Drawing.Point(299, 58);
|
||||
this.emptySpaceItem1.Name = "emptySpaceItem1";
|
||||
this.emptySpaceItem1.Size = new System.Drawing.Size(184, 218);
|
||||
this.emptySpaceItem1.Text = "emptySpaceItem1";
|
||||
this.emptySpaceItem1.TextSize = new System.Drawing.Size(0, 0);
|
||||
//
|
||||
// layoutControlItem1
|
||||
//
|
||||
this.layoutControlItem1.Control = this.btnFileFind;
|
||||
this.layoutControlItem1.CustomizationFormText = "layoutControlItem1";
|
||||
this.layoutControlItem1.Location = new System.Drawing.Point(390, 0);
|
||||
this.layoutControlItem1.MinSize = new System.Drawing.Size(93, 26);
|
||||
this.layoutControlItem1.Name = "layoutControlItem1";
|
||||
this.layoutControlItem1.Size = new System.Drawing.Size(93, 29);
|
||||
this.layoutControlItem1.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem1.Text = "layoutControlItem1";
|
||||
this.layoutControlItem1.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem1.TextToControlDistance = 0;
|
||||
this.layoutControlItem1.TextVisible = false;
|
||||
//
|
||||
// lbFileName
|
||||
//
|
||||
this.lbFileName.AllowHotTrack = false;
|
||||
this.lbFileName.CustomizationFormText = "File Name";
|
||||
this.lbFileName.Location = new System.Drawing.Point(0, 0);
|
||||
this.lbFileName.MaxSize = new System.Drawing.Size(0, 29);
|
||||
this.lbFileName.MinSize = new System.Drawing.Size(80, 29);
|
||||
this.lbFileName.Name = "lbFileName";
|
||||
this.lbFileName.Size = new System.Drawing.Size(80, 29);
|
||||
this.lbFileName.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.lbFileName.Text = "File Name";
|
||||
this.lbFileName.TextSize = new System.Drawing.Size(52, 14);
|
||||
//
|
||||
// emptySpaceItem2
|
||||
//
|
||||
this.emptySpaceItem2.AllowHotTrack = false;
|
||||
this.emptySpaceItem2.CustomizationFormText = "emptySpaceItem2";
|
||||
this.emptySpaceItem2.Location = new System.Drawing.Point(0, 29);
|
||||
this.emptySpaceItem2.Name = "emptySpaceItem2";
|
||||
this.emptySpaceItem2.Size = new System.Drawing.Size(483, 29);
|
||||
this.emptySpaceItem2.Text = "emptySpaceItem2";
|
||||
this.emptySpaceItem2.TextSize = new System.Drawing.Size(0, 0);
|
||||
//
|
||||
// layoutControlItem6
|
||||
//
|
||||
this.layoutControlItem6.Control = this.btnConvert;
|
||||
this.layoutControlItem6.CustomizationFormText = "layoutControlItem6";
|
||||
this.layoutControlItem6.Location = new System.Drawing.Point(0, 276);
|
||||
this.layoutControlItem6.MinSize = new System.Drawing.Size(93, 26);
|
||||
this.layoutControlItem6.Name = "layoutControlItem6";
|
||||
this.layoutControlItem6.Size = new System.Drawing.Size(242, 37);
|
||||
this.layoutControlItem6.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem6.Text = "layoutControlItem6";
|
||||
this.layoutControlItem6.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem6.TextToControlDistance = 0;
|
||||
this.layoutControlItem6.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem7
|
||||
//
|
||||
this.layoutControlItem7.Control = this.btnClose;
|
||||
this.layoutControlItem7.CustomizationFormText = "layoutControlItem7";
|
||||
this.layoutControlItem7.Location = new System.Drawing.Point(242, 276);
|
||||
this.layoutControlItem7.MinSize = new System.Drawing.Size(93, 26);
|
||||
this.layoutControlItem7.Name = "layoutControlItem7";
|
||||
this.layoutControlItem7.Size = new System.Drawing.Size(241, 37);
|
||||
this.layoutControlItem7.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem7.Text = "layoutControlItem7";
|
||||
this.layoutControlItem7.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem7.TextToControlDistance = 0;
|
||||
this.layoutControlItem7.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem8
|
||||
//
|
||||
this.layoutControlItem8.Control = this.lbFileInfo;
|
||||
this.layoutControlItem8.CustomizationFormText = "layoutControlItem8";
|
||||
this.layoutControlItem8.Location = new System.Drawing.Point(0, 58);
|
||||
this.layoutControlItem8.Name = "layoutControlItem8";
|
||||
this.layoutControlItem8.Size = new System.Drawing.Size(299, 218);
|
||||
this.layoutControlItem8.Text = "layoutControlItem8";
|
||||
this.layoutControlItem8.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem8.TextToControlDistance = 0;
|
||||
this.layoutControlItem8.TextVisible = false;
|
||||
//
|
||||
// fmxFwImageConverter
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(503, 333);
|
||||
this.Controls.Add(this.layoutControl1);
|
||||
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
|
||||
this.Name = "fmxFwImageConverter";
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
|
||||
this.Text = "Firmware Image Converter";
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).EndInit();
|
||||
this.layoutControl1.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.teFileName.Properties)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.lcItemFileName)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.lbFileName)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem2)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl1;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup1;
|
||||
private DevExpress.XtraEditors.TextEdit teFileName;
|
||||
private DevExpress.XtraLayout.LayoutControlItem lcItemFileName;
|
||||
private DevExpress.XtraLayout.EmptySpaceItem emptySpaceItem1;
|
||||
private DevExpress.XtraEditors.SimpleButton btnFileFind;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem1;
|
||||
private DevExpress.XtraLayout.SimpleLabelItem lbFileName;
|
||||
private DevExpress.XtraLayout.EmptySpaceItem emptySpaceItem2;
|
||||
private DevExpress.XtraEditors.SimpleButton btnClose;
|
||||
private DevExpress.XtraEditors.SimpleButton btnConvert;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem6;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem7;
|
||||
private System.Windows.Forms.Label lbFileInfo;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem8;
|
||||
}
|
||||
}
|
||||
259
LFP_Manager_PRM/Forms/fmxFwImageConverter.cs
Normal file
259
LFP_Manager_PRM/Forms/fmxFwImageConverter.cs
Normal file
@@ -0,0 +1,259 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Text;
|
||||
using System.Linq;
|
||||
using System.Windows.Forms;
|
||||
using DevExpress.XtraEditors;
|
||||
|
||||
using System.Runtime.InteropServices;
|
||||
using System.IO;
|
||||
|
||||
using LFP_Manager.Utils;
|
||||
|
||||
namespace LFP_Manager
|
||||
{
|
||||
public partial class fmxFwImageConverter : DevExpress.XtraEditors.XtraForm
|
||||
{
|
||||
#region CONST
|
||||
|
||||
//const
|
||||
// mFileMaxSize : DWORD = 262144; // 256KByte
|
||||
// sFileMaxSize : DWORD = 131072; // 128KByte
|
||||
|
||||
// ImageCode : DWORD = $53454355;
|
||||
// ImageEmpty : DWORD = $00000000;
|
||||
// MasterOnly : DWORD = $00000001;
|
||||
// SlaveOnly : DWORD = $00000002;
|
||||
// MasterSlave : DWORD = $00000003;
|
||||
const UInt32 mFileMaxSize = 262144; // 256KBytes
|
||||
const UInt32 ImageCode = 0x6D424D53; // mBMS
|
||||
const UInt32 ImageEmpty = 0x00000000; //
|
||||
|
||||
const UInt32 POLYNOMIAL = 0x04C11DB7;
|
||||
|
||||
#endregion
|
||||
|
||||
#region STRUCTURE
|
||||
//TImageHeaderStructure = packed record
|
||||
// ImageCode : DWORD;
|
||||
// ImageType : DWORD;
|
||||
// mImageSize : DWORD;
|
||||
// mImageName : array[0..31]of Byte;
|
||||
// mImageVersion : TImageVersionStructure;
|
||||
// mImageCRC : DWORD;
|
||||
// sImageSize : DWORD;
|
||||
// sImageName : array[0..31]of Byte;
|
||||
// sImageVersion : TImageVersionStructure;
|
||||
// sImageCRC : DWORD;
|
||||
// reserved : array[0..927]of Byte;
|
||||
//end;
|
||||
struct TImageHeaderStructure // Total 64bytes
|
||||
{
|
||||
public UInt32 ImageCode; // 4
|
||||
public UInt32 ImageType; // 4
|
||||
public UInt32 ImageSize; // 4
|
||||
[MarshalAs(UnmanagedType.ByValArray, SizeConst = 32)]
|
||||
public byte[] ImageName; // 32
|
||||
[MarshalAs(UnmanagedType.ByValArray, SizeConst = 4)]
|
||||
public byte[] ImageVersion; // 4
|
||||
public UInt32 ImageCRC; // 4
|
||||
[MarshalAs(UnmanagedType.ByValArray, SizeConst = 12)]
|
||||
public byte[] reserved; // 12
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region VARIABLES
|
||||
|
||||
TImageHeaderStructure fwHeader;
|
||||
byte[] fwdata;
|
||||
|
||||
UInt32[] crc_table;
|
||||
|
||||
#endregion
|
||||
|
||||
#region CONSTRUCTORS
|
||||
|
||||
public fmxFwImageConverter()
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
crc_table = new UInt32[256];
|
||||
|
||||
gen_crc_table();
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
/* generate the table of CRC remainders for all possible bytes */
|
||||
void gen_crc_table()
|
||||
{
|
||||
int i, j;
|
||||
UInt32 crc_accum;
|
||||
|
||||
for (i = 0; i < 256; i++)
|
||||
{
|
||||
crc_accum = ((UInt32)i << 24);
|
||||
|
||||
for (j = 0; j < 8; j++) {
|
||||
if ((crc_accum & 0x80000000) != 0)
|
||||
crc_accum = (crc_accum << 1) ^ POLYNOMIAL;
|
||||
else
|
||||
crc_accum = (crc_accum << 1);
|
||||
crc_table[i] = crc_accum;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* update the CRC on the data block one byte at a time */
|
||||
UInt32 update_crc(UInt32 crc_accum, byte[] data_blk_ptr, UInt32 data_blk_size)
|
||||
{
|
||||
int i, j;
|
||||
|
||||
for (j = 0; j < data_blk_size; j++)
|
||||
{
|
||||
i = ((int)(crc_accum >> 24) ^ data_blk_ptr[j]) & 0xff;
|
||||
crc_accum = (crc_accum << 8) ^ crc_table[i];
|
||||
}
|
||||
return crc_accum;
|
||||
}
|
||||
|
||||
byte[] getBytes(TImageHeaderStructure header)
|
||||
{
|
||||
int size = Marshal.SizeOf(header);
|
||||
byte[] arr = new byte[size];
|
||||
|
||||
IntPtr ptr = Marshal.AllocHGlobal(size);
|
||||
Marshal.StructureToPtr(header, ptr, true);
|
||||
Marshal.Copy(ptr, arr, 0, size);
|
||||
Marshal.FreeHGlobal(ptr);
|
||||
return arr;
|
||||
}
|
||||
|
||||
bool MakeFwImageFile(byte[] fData, string AppPath, string FileName)
|
||||
{
|
||||
FileStream aFile = null;
|
||||
string path = System.IO.Path.GetDirectoryName(AppPath);
|
||||
string aFileName = String.Format("{0}\\{1}", path, FileName);
|
||||
|
||||
bool result = false;
|
||||
|
||||
if (File.Exists(aFileName) == false)
|
||||
{
|
||||
try
|
||||
{
|
||||
aFile = new FileStream(aFileName, FileMode.CreateNew, FileAccess.ReadWrite);
|
||||
aFile.Write(fData, 0, fData.Length);
|
||||
aFile.Close();
|
||||
|
||||
result = true;
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
#region BUNTTON EVENT
|
||||
|
||||
private void btnFileFind_Click(object sender, EventArgs e)
|
||||
{
|
||||
OpenFileDialog oDialog;
|
||||
|
||||
oDialog = new OpenFileDialog();
|
||||
oDialog.DefaultExt = "*.*";
|
||||
oDialog.Filter = "bin files (*.bin)|*.bin|All files (*.*)|*.*";
|
||||
|
||||
if (oDialog.ShowDialog() == DialogResult.OK)
|
||||
{
|
||||
teFileName.Text = oDialog.FileName;
|
||||
|
||||
FileStream fwFile = new FileStream(teFileName.Text, FileMode.Open, FileAccess.Read);
|
||||
long fsize = fwFile.Length;
|
||||
|
||||
if (fsize > 0)
|
||||
{
|
||||
fwdata = new byte[fsize];
|
||||
fwFile.Seek(0, SeekOrigin.Begin);
|
||||
fwFile.Read(fwdata, 0, (int)fsize);
|
||||
}
|
||||
fwFile.Close();
|
||||
|
||||
byte[] bName = csUtils.StringToByte(Path.GetFileName(teFileName.Text));
|
||||
|
||||
fwHeader = new TImageHeaderStructure();
|
||||
fwHeader.ImageCode = ImageCode;
|
||||
fwHeader.ImageType = 0x00000001;
|
||||
fwHeader.ImageSize = (UInt32)fsize;
|
||||
fwHeader.ImageName = new byte[32];
|
||||
Buffer.BlockCopy(bName, 0, fwHeader.ImageName, 0, bName.Length);
|
||||
fwHeader.ImageCRC = update_crc(fwHeader.ImageCRC, fwdata, fwHeader.ImageSize);
|
||||
fwHeader.reserved = new byte[12];
|
||||
|
||||
if (bName.Length > 8)
|
||||
{
|
||||
fwHeader.ImageVersion = new byte[4];
|
||||
|
||||
UInt32 nPC = (UInt32)((fwdata[0] << 0) | (fwdata[1] << 8) | (fwdata[2] << 16) | (fwdata[3] << 24));
|
||||
UInt32 nSP = (UInt32)((fwdata[4] << 0) | (fwdata[5] << 8) | (fwdata[6] << 16) | (fwdata[7] << 24));
|
||||
|
||||
for (int i = 0; i < 4; i++)
|
||||
fwHeader.ImageVersion[i] = (byte)(bName[bName.Length - 1 - 3 - 4 + i] - 0x30);
|
||||
|
||||
lbFileInfo.Text = String.Format("File Information");
|
||||
lbFileInfo.Text += String.Format("\r\n - Filename: {0}", Encoding.UTF8.GetString(fwHeader.ImageName).Trim('\0'));
|
||||
lbFileInfo.Text += String.Format("\r\n - File Version: V{0}.{1}.{2}.{3}", fwHeader.ImageVersion[0], fwHeader.ImageVersion[1], fwHeader.ImageVersion[2], fwHeader.ImageVersion[3]);
|
||||
lbFileInfo.Text += String.Format("\r\n - File Size: {0:#,##0} bytes", fwHeader.ImageSize);
|
||||
lbFileInfo.Text += String.Format("\r\n - File CRC32: 0x{0:X8}", fwHeader.ImageCRC);
|
||||
lbFileInfo.Text += String.Format("\r\n - Packet Size: {0:#,##0} packets", fwHeader.ImageSize / 2048);
|
||||
lbFileInfo.Text += String.Format("\r\n - Last packet: {0:#,##0}", fwHeader.ImageSize % 2048);
|
||||
|
||||
lbFileInfo.Text += String.Format("\r\n - PC: 0x{0:X8}", nPC);
|
||||
lbFileInfo.Text += String.Format("\r\n - SP: 0x{0:X8}", nSP);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void btnConvert_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (fwHeader.ImageSize > 0)
|
||||
{
|
||||
byte[] bHeader = getBytes(fwHeader);
|
||||
byte[] cFwData = new byte[bHeader.Length + fwdata.Length];
|
||||
|
||||
Buffer.BlockCopy(bHeader, 0, cFwData, 0, 64);
|
||||
Buffer.BlockCopy(fwdata, 0, cFwData, 64, fwdata.Length);
|
||||
|
||||
string nFileName = String.Format("mBMS_APP_DL_V{0}{1}{2}{3}.bin"
|
||||
, fwHeader.ImageVersion[0]
|
||||
, fwHeader.ImageVersion[1]
|
||||
, fwHeader.ImageVersion[2]
|
||||
, fwHeader.ImageVersion[3]
|
||||
);
|
||||
|
||||
if (MakeFwImageFile(cFwData, teFileName.Text, nFileName))
|
||||
{
|
||||
MessageBox.Show("Firmware Image Convert Success !!", "FwUpdate", MessageBoxButtons.OK, MessageBoxIcon.Information);
|
||||
}
|
||||
else
|
||||
{
|
||||
MessageBox.Show("Firmware Image Convert Fail !!", "FwUpdate", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
MessageBox.Show("Please select firmware file !!", "FwUpdate", MessageBoxButtons.OK, MessageBoxIcon.Warning);
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private void btnClose_Click(object sender, EventArgs e)
|
||||
{
|
||||
Close();
|
||||
}
|
||||
}
|
||||
}
|
||||
4571
LFP_Manager_PRM/Forms/fmxFwImageConverter.resx
Normal file
4571
LFP_Manager_PRM/Forms/fmxFwImageConverter.resx
Normal file
File diff suppressed because it is too large
Load Diff
534
LFP_Manager_PRM/Forms/fmxFwUpdate.Designer.cs
generated
Normal file
534
LFP_Manager_PRM/Forms/fmxFwUpdate.Designer.cs
generated
Normal file
@@ -0,0 +1,534 @@
|
||||
namespace LFP_Manager
|
||||
{
|
||||
partial class fmxFwUpdate
|
||||
{
|
||||
/// <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.components = new System.ComponentModel.Container();
|
||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(fmxFwUpdate));
|
||||
this.layoutControl1 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.teModuleNo = new DevExpress.XtraEditors.TextEdit();
|
||||
this.btnRestart = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.lbUpdateStatus = new DevExpress.XtraEditors.LabelControl();
|
||||
this.lbUpdateProgress = new DevExpress.XtraEditors.LabelControl();
|
||||
this.pgUpdate = new DevExpress.XtraEditors.ProgressBarControl();
|
||||
this.lbUpdateTime = new DevExpress.XtraEditors.LabelControl();
|
||||
this.lbFileInfo = new DevExpress.XtraEditors.LabelControl();
|
||||
this.btnFwUpdate = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.btnClose = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.btnFind = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.edFilename = new DevExpress.XtraEditors.TextEdit();
|
||||
this.layoutControlGroup1 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem3 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlGroup2 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem10 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem11 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem9 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.emptySpaceItem2 = new DevExpress.XtraLayout.EmptySpaceItem();
|
||||
this.layoutControlItem12 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlGroup3 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem5 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem6 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.emptySpaceItem3 = new DevExpress.XtraLayout.EmptySpaceItem();
|
||||
this.layoutControlItem2 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem1 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlGroup4 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem8 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.emptySpaceItem1 = new DevExpress.XtraLayout.EmptySpaceItem();
|
||||
this.layoutControlGroup5 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.emptySpaceItem4 = new DevExpress.XtraLayout.EmptySpaceItem();
|
||||
this.layoutControlItem4 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.tmrFirmwareUpdate = new System.Windows.Forms.Timer(this.components);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).BeginInit();
|
||||
this.layoutControl1.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.teModuleNo.Properties)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pgUpdate.Properties)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.edFilename.Properties)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup2)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem10)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem11)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem2)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem12)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup3)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem3)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup4)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup5)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem4)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// layoutControl1
|
||||
//
|
||||
this.layoutControl1.Controls.Add(this.teModuleNo);
|
||||
this.layoutControl1.Controls.Add(this.btnRestart);
|
||||
this.layoutControl1.Controls.Add(this.lbUpdateStatus);
|
||||
this.layoutControl1.Controls.Add(this.lbUpdateProgress);
|
||||
this.layoutControl1.Controls.Add(this.pgUpdate);
|
||||
this.layoutControl1.Controls.Add(this.lbUpdateTime);
|
||||
this.layoutControl1.Controls.Add(this.lbFileInfo);
|
||||
this.layoutControl1.Controls.Add(this.btnFwUpdate);
|
||||
this.layoutControl1.Controls.Add(this.btnClose);
|
||||
this.layoutControl1.Controls.Add(this.btnFind);
|
||||
this.layoutControl1.Controls.Add(this.edFilename);
|
||||
this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControl1.Name = "layoutControl1";
|
||||
this.layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(1092, 323, 626, 350);
|
||||
this.layoutControl1.Root = this.layoutControlGroup1;
|
||||
this.layoutControl1.Size = new System.Drawing.Size(736, 500);
|
||||
this.layoutControl1.TabIndex = 0;
|
||||
this.layoutControl1.Text = "layoutControl1";
|
||||
//
|
||||
// teModuleNo
|
||||
//
|
||||
this.teModuleNo.EditValue = "1";
|
||||
this.teModuleNo.Location = new System.Drawing.Point(473, 55);
|
||||
this.teModuleNo.Name = "teModuleNo";
|
||||
this.teModuleNo.Properties.Appearance.Options.UseTextOptions = true;
|
||||
this.teModuleNo.Properties.Appearance.TextOptions.HAlignment = DevExpress.Utils.HorzAlignment.Far;
|
||||
this.teModuleNo.Properties.EditFormat.FormatType = DevExpress.Utils.FormatType.Numeric;
|
||||
this.teModuleNo.Size = new System.Drawing.Size(60, 20);
|
||||
this.teModuleNo.StyleController = this.layoutControl1;
|
||||
this.teModuleNo.TabIndex = 18;
|
||||
this.teModuleNo.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.TextBox_KeyPress);
|
||||
//
|
||||
// btnRestart
|
||||
//
|
||||
this.btnRestart.Location = new System.Drawing.Point(535, 290);
|
||||
this.btnRestart.Name = "btnRestart";
|
||||
this.btnRestart.Size = new System.Drawing.Size(189, 26);
|
||||
this.btnRestart.StyleController = this.layoutControl1;
|
||||
this.btnRestart.TabIndex = 17;
|
||||
this.btnRestart.Text = "Restart";
|
||||
this.btnRestart.Click += new System.EventHandler(this.btnRestart_Click);
|
||||
//
|
||||
// lbUpdateStatus
|
||||
//
|
||||
this.lbUpdateStatus.Location = new System.Drawing.Point(8, 353);
|
||||
this.lbUpdateStatus.Name = "lbUpdateStatus";
|
||||
this.lbUpdateStatus.Size = new System.Drawing.Size(525, 30);
|
||||
this.lbUpdateStatus.StyleController = this.layoutControl1;
|
||||
this.lbUpdateStatus.TabIndex = 16;
|
||||
this.lbUpdateStatus.Text = "Update Status : ";
|
||||
//
|
||||
// lbUpdateProgress
|
||||
//
|
||||
this.lbUpdateProgress.Appearance.Options.UseTextOptions = true;
|
||||
this.lbUpdateProgress.Appearance.TextOptions.HAlignment = DevExpress.Utils.HorzAlignment.Far;
|
||||
this.lbUpdateProgress.Location = new System.Drawing.Point(537, 387);
|
||||
this.lbUpdateProgress.Name = "lbUpdateProgress";
|
||||
this.lbUpdateProgress.Size = new System.Drawing.Size(191, 27);
|
||||
this.lbUpdateProgress.StyleController = this.layoutControl1;
|
||||
this.lbUpdateProgress.TabIndex = 15;
|
||||
this.lbUpdateProgress.Text = "0/0 bytes";
|
||||
//
|
||||
// pgUpdate
|
||||
//
|
||||
this.pgUpdate.Location = new System.Drawing.Point(8, 418);
|
||||
this.pgUpdate.Name = "pgUpdate";
|
||||
this.pgUpdate.Size = new System.Drawing.Size(720, 37);
|
||||
this.pgUpdate.StyleController = this.layoutControl1;
|
||||
this.pgUpdate.TabIndex = 14;
|
||||
//
|
||||
// lbUpdateTime
|
||||
//
|
||||
this.lbUpdateTime.Location = new System.Drawing.Point(8, 387);
|
||||
this.lbUpdateTime.Name = "lbUpdateTime";
|
||||
this.lbUpdateTime.Size = new System.Drawing.Size(525, 27);
|
||||
this.lbUpdateTime.StyleController = this.layoutControl1;
|
||||
this.lbUpdateTime.TabIndex = 13;
|
||||
this.lbUpdateTime.Text = "00:00";
|
||||
//
|
||||
// lbFileInfo
|
||||
//
|
||||
this.lbFileInfo.Appearance.Options.UseTextOptions = true;
|
||||
this.lbFileInfo.Appearance.TextOptions.VAlignment = DevExpress.Utils.VertAlignment.Top;
|
||||
this.lbFileInfo.Location = new System.Drawing.Point(12, 106);
|
||||
this.lbFileInfo.Name = "lbFileInfo";
|
||||
this.lbFileInfo.Size = new System.Drawing.Size(519, 151);
|
||||
this.lbFileInfo.StyleController = this.layoutControl1;
|
||||
this.lbFileInfo.TabIndex = 12;
|
||||
this.lbFileInfo.Text = "File Information";
|
||||
//
|
||||
// btnFwUpdate
|
||||
//
|
||||
this.btnFwUpdate.Location = new System.Drawing.Point(537, 55);
|
||||
this.btnFwUpdate.Name = "btnFwUpdate";
|
||||
this.btnFwUpdate.Size = new System.Drawing.Size(191, 22);
|
||||
this.btnFwUpdate.StyleController = this.layoutControl1;
|
||||
this.btnFwUpdate.TabIndex = 8;
|
||||
this.btnFwUpdate.Text = "Firmware Update";
|
||||
this.btnFwUpdate.Click += new System.EventHandler(this.btnFwUpdate_Click);
|
||||
//
|
||||
// btnClose
|
||||
//
|
||||
this.btnClose.Location = new System.Drawing.Point(4, 463);
|
||||
this.btnClose.Name = "btnClose";
|
||||
this.btnClose.Size = new System.Drawing.Size(728, 33);
|
||||
this.btnClose.StyleController = this.layoutControl1;
|
||||
this.btnClose.TabIndex = 6;
|
||||
this.btnClose.Text = "CLOSE";
|
||||
this.btnClose.Click += new System.EventHandler(this.btnClose_Click);
|
||||
//
|
||||
// btnFind
|
||||
//
|
||||
this.btnFind.Location = new System.Drawing.Point(537, 29);
|
||||
this.btnFind.Name = "btnFind";
|
||||
this.btnFind.Size = new System.Drawing.Size(191, 22);
|
||||
this.btnFind.StyleController = this.layoutControl1;
|
||||
this.btnFind.TabIndex = 5;
|
||||
this.btnFind.Text = "Find File...";
|
||||
this.btnFind.Click += new System.EventHandler(this.btnFind_Click);
|
||||
//
|
||||
// edFilename
|
||||
//
|
||||
this.edFilename.Location = new System.Drawing.Point(88, 29);
|
||||
this.edFilename.Name = "edFilename";
|
||||
this.edFilename.Properties.Appearance.Font = new System.Drawing.Font("Tahoma", 10F);
|
||||
this.edFilename.Properties.Appearance.Options.UseFont = true;
|
||||
this.edFilename.Size = new System.Drawing.Size(445, 22);
|
||||
this.edFilename.StyleController = this.layoutControl1;
|
||||
this.edFilename.TabIndex = 4;
|
||||
//
|
||||
// layoutControlGroup1
|
||||
//
|
||||
this.layoutControlGroup1.CustomizationFormText = "layoutControlGroup1";
|
||||
this.layoutControlGroup1.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.layoutControlGroup1.GroupBordersVisible = false;
|
||||
this.layoutControlGroup1.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem3,
|
||||
this.layoutControlGroup2,
|
||||
this.layoutControlGroup3});
|
||||
this.layoutControlGroup1.Name = "Root";
|
||||
this.layoutControlGroup1.Padding = new DevExpress.XtraLayout.Utils.Padding(2, 2, 2, 2);
|
||||
this.layoutControlGroup1.Size = new System.Drawing.Size(736, 500);
|
||||
this.layoutControlGroup1.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem3
|
||||
//
|
||||
this.layoutControlItem3.Control = this.btnClose;
|
||||
this.layoutControlItem3.CustomizationFormText = "layoutControlItem3";
|
||||
this.layoutControlItem3.Location = new System.Drawing.Point(0, 459);
|
||||
this.layoutControlItem3.MinSize = new System.Drawing.Size(93, 26);
|
||||
this.layoutControlItem3.Name = "layoutControlItem3";
|
||||
this.layoutControlItem3.Size = new System.Drawing.Size(732, 37);
|
||||
this.layoutControlItem3.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem3.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem3.TextVisible = false;
|
||||
//
|
||||
// layoutControlGroup2
|
||||
//
|
||||
this.layoutControlGroup2.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem10,
|
||||
this.layoutControlItem11,
|
||||
this.layoutControlItem9,
|
||||
this.emptySpaceItem2,
|
||||
this.layoutControlItem12});
|
||||
this.layoutControlGroup2.Location = new System.Drawing.Point(0, 324);
|
||||
this.layoutControlGroup2.Name = "layoutControlGroup2";
|
||||
this.layoutControlGroup2.Padding = new DevExpress.XtraLayout.Utils.Padding(1, 1, 1, 1);
|
||||
this.layoutControlGroup2.Size = new System.Drawing.Size(732, 135);
|
||||
this.layoutControlGroup2.Text = "Update Status";
|
||||
//
|
||||
// layoutControlItem10
|
||||
//
|
||||
this.layoutControlItem10.Control = this.pgUpdate;
|
||||
this.layoutControlItem10.CustomizationFormText = "layoutControlItem10";
|
||||
this.layoutControlItem10.Location = new System.Drawing.Point(0, 65);
|
||||
this.layoutControlItem10.MinSize = new System.Drawing.Size(54, 16);
|
||||
this.layoutControlItem10.Name = "layoutControlItem10";
|
||||
this.layoutControlItem10.Size = new System.Drawing.Size(724, 41);
|
||||
this.layoutControlItem10.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem10.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem10.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem11
|
||||
//
|
||||
this.layoutControlItem11.Control = this.lbUpdateProgress;
|
||||
this.layoutControlItem11.CustomizationFormText = "layoutControlItem11";
|
||||
this.layoutControlItem11.Location = new System.Drawing.Point(529, 34);
|
||||
this.layoutControlItem11.MinSize = new System.Drawing.Size(74, 18);
|
||||
this.layoutControlItem11.Name = "layoutControlItem11";
|
||||
this.layoutControlItem11.Size = new System.Drawing.Size(195, 31);
|
||||
this.layoutControlItem11.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem11.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem11.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem9
|
||||
//
|
||||
this.layoutControlItem9.Control = this.lbUpdateTime;
|
||||
this.layoutControlItem9.CustomizationFormText = "layoutControlItem9";
|
||||
this.layoutControlItem9.Location = new System.Drawing.Point(0, 34);
|
||||
this.layoutControlItem9.MinSize = new System.Drawing.Size(74, 18);
|
||||
this.layoutControlItem9.Name = "layoutControlItem9";
|
||||
this.layoutControlItem9.Size = new System.Drawing.Size(529, 31);
|
||||
this.layoutControlItem9.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem9.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem9.TextVisible = false;
|
||||
//
|
||||
// emptySpaceItem2
|
||||
//
|
||||
this.emptySpaceItem2.AllowHotTrack = false;
|
||||
this.emptySpaceItem2.CustomizationFormText = "emptySpaceItem2";
|
||||
this.emptySpaceItem2.Location = new System.Drawing.Point(529, 0);
|
||||
this.emptySpaceItem2.Name = "emptySpaceItem2";
|
||||
this.emptySpaceItem2.Size = new System.Drawing.Size(195, 34);
|
||||
this.emptySpaceItem2.TextSize = new System.Drawing.Size(0, 0);
|
||||
//
|
||||
// layoutControlItem12
|
||||
//
|
||||
this.layoutControlItem12.Control = this.lbUpdateStatus;
|
||||
this.layoutControlItem12.CustomizationFormText = "layoutControlItem12";
|
||||
this.layoutControlItem12.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem12.MinSize = new System.Drawing.Size(74, 18);
|
||||
this.layoutControlItem12.Name = "layoutControlItem12";
|
||||
this.layoutControlItem12.Size = new System.Drawing.Size(529, 34);
|
||||
this.layoutControlItem12.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem12.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem12.TextVisible = false;
|
||||
//
|
||||
// layoutControlGroup3
|
||||
//
|
||||
this.layoutControlGroup3.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem5,
|
||||
this.layoutControlItem6,
|
||||
this.emptySpaceItem3,
|
||||
this.layoutControlItem2,
|
||||
this.layoutControlItem1,
|
||||
this.layoutControlGroup4,
|
||||
this.layoutControlGroup5});
|
||||
this.layoutControlGroup3.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlGroup3.Name = "layoutControlGroup3";
|
||||
this.layoutControlGroup3.Padding = new DevExpress.XtraLayout.Utils.Padding(1, 1, 1, 1);
|
||||
this.layoutControlGroup3.Size = new System.Drawing.Size(732, 324);
|
||||
this.layoutControlGroup3.Text = "Update Command";
|
||||
//
|
||||
// layoutControlItem5
|
||||
//
|
||||
this.layoutControlItem5.Control = this.btnFwUpdate;
|
||||
this.layoutControlItem5.CustomizationFormText = "layoutControlItem5";
|
||||
this.layoutControlItem5.Location = new System.Drawing.Point(529, 26);
|
||||
this.layoutControlItem5.MinSize = new System.Drawing.Size(108, 26);
|
||||
this.layoutControlItem5.Name = "layoutControlItem5";
|
||||
this.layoutControlItem5.Size = new System.Drawing.Size(195, 26);
|
||||
this.layoutControlItem5.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem5.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem5.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem6
|
||||
//
|
||||
this.layoutControlItem6.Control = this.teModuleNo;
|
||||
this.layoutControlItem6.CustomizationFormText = "Module No";
|
||||
this.layoutControlItem6.Location = new System.Drawing.Point(385, 26);
|
||||
this.layoutControlItem6.Name = "layoutControlItem6";
|
||||
this.layoutControlItem6.Size = new System.Drawing.Size(144, 26);
|
||||
this.layoutControlItem6.Text = "Module No";
|
||||
this.layoutControlItem6.TextSize = new System.Drawing.Size(68, 14);
|
||||
//
|
||||
// emptySpaceItem3
|
||||
//
|
||||
this.emptySpaceItem3.AllowHotTrack = false;
|
||||
this.emptySpaceItem3.CustomizationFormText = "emptySpaceItem3";
|
||||
this.emptySpaceItem3.Location = new System.Drawing.Point(0, 26);
|
||||
this.emptySpaceItem3.Name = "emptySpaceItem3";
|
||||
this.emptySpaceItem3.Size = new System.Drawing.Size(385, 26);
|
||||
this.emptySpaceItem3.TextSize = new System.Drawing.Size(0, 0);
|
||||
//
|
||||
// layoutControlItem2
|
||||
//
|
||||
this.layoutControlItem2.Control = this.btnFind;
|
||||
this.layoutControlItem2.CustomizationFormText = "layoutControlItem2";
|
||||
this.layoutControlItem2.Location = new System.Drawing.Point(529, 0);
|
||||
this.layoutControlItem2.Name = "layoutControlItem2";
|
||||
this.layoutControlItem2.Size = new System.Drawing.Size(195, 26);
|
||||
this.layoutControlItem2.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem2.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem1
|
||||
//
|
||||
this.layoutControlItem1.Control = this.edFilename;
|
||||
this.layoutControlItem1.CustomizationFormText = "layoutControlItem1";
|
||||
this.layoutControlItem1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem1.Name = "layoutControlItem1";
|
||||
this.layoutControlItem1.Size = new System.Drawing.Size(529, 26);
|
||||
this.layoutControlItem1.Text = "File Name : ";
|
||||
this.layoutControlItem1.TextSize = new System.Drawing.Size(68, 14);
|
||||
//
|
||||
// layoutControlGroup4
|
||||
//
|
||||
this.layoutControlGroup4.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem8,
|
||||
this.emptySpaceItem1});
|
||||
this.layoutControlGroup4.Location = new System.Drawing.Point(0, 52);
|
||||
this.layoutControlGroup4.Name = "layoutControlGroup4";
|
||||
this.layoutControlGroup4.Padding = new DevExpress.XtraLayout.Utils.Padding(1, 1, 1, 1);
|
||||
this.layoutControlGroup4.Size = new System.Drawing.Size(724, 184);
|
||||
this.layoutControlGroup4.Text = "File Information";
|
||||
//
|
||||
// layoutControlItem8
|
||||
//
|
||||
this.layoutControlItem8.Control = this.lbFileInfo;
|
||||
this.layoutControlItem8.CustomizationFormText = "layoutControlItem8";
|
||||
this.layoutControlItem8.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem8.MinSize = new System.Drawing.Size(74, 18);
|
||||
this.layoutControlItem8.Name = "layoutControlItem8";
|
||||
this.layoutControlItem8.Size = new System.Drawing.Size(523, 155);
|
||||
this.layoutControlItem8.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem8.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem8.TextVisible = false;
|
||||
//
|
||||
// emptySpaceItem1
|
||||
//
|
||||
this.emptySpaceItem1.AllowHotTrack = false;
|
||||
this.emptySpaceItem1.CustomizationFormText = "emptySpaceItem1";
|
||||
this.emptySpaceItem1.Location = new System.Drawing.Point(523, 0);
|
||||
this.emptySpaceItem1.Name = "emptySpaceItem1";
|
||||
this.emptySpaceItem1.Size = new System.Drawing.Size(193, 155);
|
||||
this.emptySpaceItem1.TextSize = new System.Drawing.Size(0, 0);
|
||||
//
|
||||
// layoutControlGroup5
|
||||
//
|
||||
this.layoutControlGroup5.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.emptySpaceItem4,
|
||||
this.layoutControlItem4});
|
||||
this.layoutControlGroup5.Location = new System.Drawing.Point(0, 236);
|
||||
this.layoutControlGroup5.Name = "layoutControlGroup5";
|
||||
this.layoutControlGroup5.Padding = new DevExpress.XtraLayout.Utils.Padding(1, 1, 1, 1);
|
||||
this.layoutControlGroup5.Size = new System.Drawing.Size(724, 59);
|
||||
this.layoutControlGroup5.Text = "Extra Command";
|
||||
//
|
||||
// emptySpaceItem4
|
||||
//
|
||||
this.emptySpaceItem4.AllowHotTrack = false;
|
||||
this.emptySpaceItem4.CustomizationFormText = "emptySpaceItem4";
|
||||
this.emptySpaceItem4.Location = new System.Drawing.Point(0, 0);
|
||||
this.emptySpaceItem4.Name = "emptySpaceItem4";
|
||||
this.emptySpaceItem4.Size = new System.Drawing.Size(523, 30);
|
||||
this.emptySpaceItem4.TextSize = new System.Drawing.Size(0, 0);
|
||||
//
|
||||
// layoutControlItem4
|
||||
//
|
||||
this.layoutControlItem4.Control = this.btnRestart;
|
||||
this.layoutControlItem4.CustomizationFormText = "layoutControlItem4";
|
||||
this.layoutControlItem4.Location = new System.Drawing.Point(523, 0);
|
||||
this.layoutControlItem4.MinSize = new System.Drawing.Size(93, 26);
|
||||
this.layoutControlItem4.Name = "layoutControlItem4";
|
||||
this.layoutControlItem4.Size = new System.Drawing.Size(193, 30);
|
||||
this.layoutControlItem4.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem4.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem4.TextVisible = false;
|
||||
//
|
||||
// tmrFirmwareUpdate
|
||||
//
|
||||
this.tmrFirmwareUpdate.Tick += new System.EventHandler(this.tmrFirmwareUpdate_Tick);
|
||||
//
|
||||
// fmxFwUpdate
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(736, 500);
|
||||
this.Controls.Add(this.layoutControl1);
|
||||
this.IconOptions.Image = ((System.Drawing.Image)(resources.GetObject("fmxFwUpdate.IconOptions.Image")));
|
||||
this.Name = "fmxFwUpdate";
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
|
||||
this.Text = "fmFwUpdate";
|
||||
this.FormClosed += new System.Windows.Forms.FormClosedEventHandler(this.fmxFwUpdate_FormClosed);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).EndInit();
|
||||
this.layoutControl1.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.teModuleNo.Properties)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.pgUpdate.Properties)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.edFilename.Properties)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup2)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem10)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem11)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem2)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem12)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup3)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem3)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup4)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup5)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem4)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl1;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup1;
|
||||
private DevExpress.XtraEditors.SimpleButton btnFind;
|
||||
private DevExpress.XtraEditors.TextEdit edFilename;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem1;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem2;
|
||||
private DevExpress.XtraLayout.EmptySpaceItem emptySpaceItem1;
|
||||
private DevExpress.XtraEditors.SimpleButton btnClose;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem3;
|
||||
private DevExpress.XtraEditors.SimpleButton btnFwUpdate;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem5;
|
||||
private DevExpress.XtraLayout.EmptySpaceItem emptySpaceItem3;
|
||||
private DevExpress.XtraLayout.EmptySpaceItem emptySpaceItem4;
|
||||
private DevExpress.XtraEditors.LabelControl lbFileInfo;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem8;
|
||||
private DevExpress.XtraLayout.EmptySpaceItem emptySpaceItem2;
|
||||
private DevExpress.XtraEditors.LabelControl lbUpdateTime;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem9;
|
||||
private DevExpress.XtraEditors.ProgressBarControl pgUpdate;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem10;
|
||||
private DevExpress.XtraEditors.LabelControl lbUpdateProgress;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem11;
|
||||
private DevExpress.XtraEditors.LabelControl lbUpdateStatus;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem12;
|
||||
private DevExpress.XtraEditors.SimpleButton btnRestart;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem4;
|
||||
private DevExpress.XtraEditors.TextEdit teModuleNo;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem6;
|
||||
private System.Windows.Forms.Timer tmrFirmwareUpdate;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup2;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup3;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup4;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup5;
|
||||
}
|
||||
}
|
||||
576
LFP_Manager_PRM/Forms/fmxFwUpdate.cs
Normal file
576
LFP_Manager_PRM/Forms/fmxFwUpdate.cs
Normal file
@@ -0,0 +1,576 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Text;
|
||||
using System.Linq;
|
||||
using System.Windows.Forms;
|
||||
using DevExpress.XtraEditors;
|
||||
using System.IO;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
using System.Threading;
|
||||
|
||||
using LFP_Manager.DataStructure;
|
||||
using LFP_Manager.Function;
|
||||
using LFP_Manager.Utils;
|
||||
using static System.Data.Entity.Infrastructure.Design.Executor;
|
||||
|
||||
namespace LFP_Manager
|
||||
{
|
||||
public delegate void AutoTxCanSetEnvent(bool autoTx);
|
||||
public delegate void SendDataCanEvent(uint header, byte[] data);
|
||||
|
||||
public partial class fmxFwUpdate : DevExpress.XtraEditors.XtraForm
|
||||
{
|
||||
#region DEFINES
|
||||
|
||||
const int FW_UPDATE_START_ADDR = 0x8012000;
|
||||
const int FW_UPDATE_END_ADDR = 0x801FFFF;
|
||||
const int FW_UPDATE_SECTOR_SIZE = 0x20000;
|
||||
const int FW_UPDATE_PACKET_SIZE = 0x800;
|
||||
|
||||
#endregion
|
||||
|
||||
#region VARIABLES
|
||||
|
||||
private uint SystemId = 0;
|
||||
|
||||
private byte[] fwdata;
|
||||
private byte[] fwver;
|
||||
|
||||
private bool StopUpdate = true;
|
||||
|
||||
private uint SectorEraseAddr = 0;
|
||||
private uint SetAddr = 0;
|
||||
private uint SetLength = 0;
|
||||
|
||||
private int WR_PACKET_DELAY = 1;
|
||||
|
||||
private DateTime UpdateStartTime;
|
||||
private TimeSpan UpdateTime;
|
||||
|
||||
private CommConfig Config;
|
||||
|
||||
public event AutoTxCanSetEnvent OnAutoTxCanSet = null;
|
||||
public event SendDataCanEvent OnSendDataCan = null;
|
||||
#endregion
|
||||
|
||||
#region CONSTRUCTORS
|
||||
|
||||
public fmxFwUpdate(uint MdID, CommConfig aConfig)
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
SystemId = MdID;
|
||||
teModuleNo.Text = string.Format("{0}", SystemId);
|
||||
|
||||
fwdata = null;
|
||||
fwver = null;
|
||||
btnFwUpdate.Enabled = false;
|
||||
|
||||
Config = aConfig;
|
||||
|
||||
if (csCanConstData.CanDeviceInfo.DeviceIds[Config.CanDevice] == csCanConstData.CanDeviceInfo.VCI_VALUE_CAN4_1)
|
||||
WR_PACKET_DELAY = 10;
|
||||
else
|
||||
WR_PACKET_DELAY = 1;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region KEY EVENT FUNCTION
|
||||
private void TextBox_KeyPress(object sender, KeyPressEventArgs e)
|
||||
{
|
||||
csUtils.TypingOnlyNumber(sender, e, true, true);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region BUTTON EVENTS
|
||||
|
||||
private void btnClose_Click(object sender, EventArgs e)
|
||||
{
|
||||
Close();
|
||||
}
|
||||
|
||||
private void btnFwUpdate_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (teModuleNo.Text == "")
|
||||
{
|
||||
MessageBox.Show("Please check module no", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
|
||||
uint sId = Convert.ToUInt32(teModuleNo.Text);
|
||||
if ((sId == 0) || (sId > 18))
|
||||
{
|
||||
MessageBox.Show("Please check module no", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning);
|
||||
return;
|
||||
}
|
||||
SystemId = sId;
|
||||
|
||||
if (StopUpdate)
|
||||
{
|
||||
teModuleNo.Enabled = false;
|
||||
if (OnSendDataCan != null)
|
||||
{
|
||||
if (OnAutoTxCanSet != null)
|
||||
{
|
||||
OnAutoTxCanSet(false);
|
||||
}
|
||||
|
||||
if ((fwdata != null) && (fwdata.Length > 0))
|
||||
{
|
||||
UpdateStartTime = DateTime.Now;
|
||||
PACKET_DN packet = csCanFwUpdateFunction.FwUpdateStartPacket(SystemId, fwver, (UInt32)fwdata.Length);
|
||||
OnSendDataCan(packet.hdr, packet.data);
|
||||
}
|
||||
StopUpdate = false;
|
||||
btnFwUpdate.Text = "Cancel Update";
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
teModuleNo.Enabled = true;
|
||||
|
||||
StopUpdate = true;
|
||||
SectorEraseAddr = 0;
|
||||
SetAddr = 0;
|
||||
SetLength = 0;
|
||||
FirmwareUpdateTimeoutClear();
|
||||
|
||||
pgUpdate.Position = 0;
|
||||
lbUpdateStatus.Text = "Update Status : Cancel By User";
|
||||
btnFwUpdate.Text = "Firmware Update";
|
||||
|
||||
if (OnAutoTxCanSet != null)
|
||||
{
|
||||
OnAutoTxCanSet(true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void btnFind_Click(object sender, EventArgs e)
|
||||
{
|
||||
OpenFileDialog oDialog;
|
||||
|
||||
oDialog = new OpenFileDialog();
|
||||
oDialog.DefaultExt = "*.*";
|
||||
oDialog.Filter = "bin files (*.bin)|*.bin|All files (*.*)|*.*";
|
||||
|
||||
if (oDialog.ShowDialog() == DialogResult.OK)
|
||||
{
|
||||
edFilename.Text = oDialog.FileName;
|
||||
|
||||
FileStream fwFile = new FileStream(edFilename.Text, FileMode.Open, FileAccess.Read);
|
||||
long fsize = fwFile.Length;
|
||||
|
||||
if (fsize > 0)
|
||||
{
|
||||
fwdata = new byte[fsize];
|
||||
fwFile.Seek(0, SeekOrigin.Begin);
|
||||
fwFile.Read(fwdata, 0, (int)fsize);
|
||||
}
|
||||
fwFile.Close();
|
||||
|
||||
byte[] bName = csUtils.StringToByte(Path.GetFileName(edFilename.Text));
|
||||
|
||||
if (bName.Length > 8)
|
||||
{
|
||||
fwver = new byte[4];
|
||||
|
||||
for (int i = 0; i < 4; i++)
|
||||
fwver[i] = (byte)(bName[bName.Length - 1 - 3 - 4 + i] - 0x30);
|
||||
|
||||
UInt32 nPC = (UInt32)((fwdata[0] << 0) | (fwdata[1] << 8) | (fwdata[2] << 16) | (fwdata[3] << 24));
|
||||
UInt32 nSP = (UInt32)((fwdata[4] << 0) | (fwdata[5] << 8) | (fwdata[6] << 16) | (fwdata[7] << 24));
|
||||
|
||||
if ((nPC >= 0x20000000) && (nPC <= 0x20100000)
|
||||
&& (nSP >= 0x08000000) && (nSP <= 0x08100000))
|
||||
{
|
||||
btnFwUpdate.Enabled = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
nPC = (UInt32)((fwdata[0 + 64] << 0) | (fwdata[1 + 64] << 8) | (fwdata[2 + 64] << 16) | (fwdata[3 + 64] << 24));
|
||||
nSP = (UInt32)((fwdata[4 + 64] << 0) | (fwdata[5 + 64] << 8) | (fwdata[6 + 64] << 16) | (fwdata[7 + 64] << 24));
|
||||
|
||||
if ((nPC >= 0x20000000) && (nPC <= 0x20100000)
|
||||
&& (nSP >= 0x08000000) && (nSP <= 0x08100000))
|
||||
{
|
||||
fsize -= 64;
|
||||
byte[] fwdataB = new byte[fsize];
|
||||
|
||||
for (int i = 0; i < fsize; i++)
|
||||
{
|
||||
fwdataB[i] = fwdata[i + 64];
|
||||
}
|
||||
fwdata = new byte[fsize];
|
||||
for (int i = 0; i < fsize; i++)
|
||||
{
|
||||
fwdata[i] = fwdataB[i];
|
||||
}
|
||||
btnFwUpdate.Enabled = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
btnFwUpdate.Enabled = false;
|
||||
}
|
||||
}
|
||||
lbFileInfo.Text = String.Format("File Information");
|
||||
lbFileInfo.Text += String.Format("\r\n - Filename: {0}", Path.GetFileName(edFilename.Text));
|
||||
lbFileInfo.Text += String.Format("\r\n - File Version: V{0}.{1}.{2}.{3}", fwver[0], fwver[1], fwver[2], fwver[3]);
|
||||
lbFileInfo.Text += String.Format("\r\n - File Size: {0:#,##0} bytes", fsize);
|
||||
lbFileInfo.Text += String.Format("\r\n - File Size: {0:#,##0} bytes", fsize);
|
||||
lbFileInfo.Text += String.Format("\r\n - Packet Size: {0:#,##0} packets", fsize / 2048);
|
||||
lbFileInfo.Text += String.Format("\r\n - Last packet: {0:#,##0}", fsize % 2048);
|
||||
|
||||
lbFileInfo.Text += String.Format("\r\n - PC: 0x{0:X8}", nPC);
|
||||
lbFileInfo.Text += String.Format("\r\n - SP: 0x{0:X8}", nSP);
|
||||
|
||||
lbUpdateProgress.Text = String.Format("{0:#,##0}/{1:#,##0} bytes", 0, fsize);
|
||||
pgUpdate.Properties.Maximum = (int)fsize;
|
||||
}
|
||||
}
|
||||
}
|
||||
private void btnRestart_Click(object sender, EventArgs e)
|
||||
{
|
||||
PACKET_DN packet = csCanFwUpdateFunction.UpdateRestartPacket(SystemId, 1);
|
||||
OnSendDataCan?.Invoke(packet.hdr, packet.data);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region FORM EVENT
|
||||
|
||||
private void fmxFwUpdate_Activated(object sender, EventArgs e)
|
||||
{
|
||||
if (OnAutoTxCanSet != null)
|
||||
{
|
||||
OnAutoTxCanSet(false);
|
||||
}
|
||||
}
|
||||
|
||||
private void fmxFwUpdate_FormClosed(object sender, FormClosedEventArgs e)
|
||||
{
|
||||
if (OnAutoTxCanSet != null)
|
||||
{
|
||||
OnAutoTxCanSet(true);
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region PUBLIC FUNCTION
|
||||
|
||||
public void RecvData(UInt32 rhdr, byte[] rdata)
|
||||
{
|
||||
PACKET_HEADER_DN dnHdr = csCanFwUpdateFunction.CovertPtoH(rhdr);
|
||||
|
||||
lbUpdateStatus.Text = String.Format("Recv Data: 0x{0:X8} {1:X2} {2:X2} {3:X2} {4:X2} {5:X2} {6:X2} {7:X2} {8:X2}"
|
||||
, rhdr, rdata[0], rdata[1], rdata[2], rdata[3], rdata[4], rdata[5], rdata[6], rdata[7]);
|
||||
|
||||
if (StopUpdate == false)
|
||||
{
|
||||
if (dnHdr.SID == SystemId)
|
||||
{
|
||||
FirmwareUpdateTimeoutClear();
|
||||
switch (dnHdr.FC)
|
||||
{
|
||||
case csCanFwUpdateFunction.DL_START_CODE:
|
||||
FwUpdateStartProcess(dnHdr, rdata);
|
||||
break;
|
||||
case csCanFwUpdateFunction.DL_SECTOR_ERASE_CODE:
|
||||
SectorEraseProcess(dnHdr, rdata);
|
||||
break;
|
||||
case csCanFwUpdateFunction.DL_SET_ADDRESS_CODE:
|
||||
SeAddrProcess(dnHdr, rdata);
|
||||
break;
|
||||
case csCanFwUpdateFunction.DL_WRITE_DATA_CSUM_CODE:
|
||||
WritedataChkSumProcess(dnHdr, rdata);
|
||||
break;
|
||||
case csCanFwUpdateFunction.DL_IMAGE_CSUM_CODE:
|
||||
FwImageChkSumProcess(dnHdr, rdata);
|
||||
break;
|
||||
case csCanFwUpdateFunction.DL_RESTART_CODE:
|
||||
FirmwareUpdateStop();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region FW UPDATE PROCESS FUNCTIONS
|
||||
private void FwUpdateStartProcess(PACKET_HEADER_DN hdr, byte[] data)
|
||||
{
|
||||
byte rResult = data[7];
|
||||
|
||||
if (rResult == 0)
|
||||
{
|
||||
if (OnSendDataCan != null)
|
||||
{
|
||||
if ((fwdata != null) && (fwdata.Length > 0))
|
||||
{
|
||||
UpdateStartTime = DateTime.Now;
|
||||
|
||||
SectorEraseAddr = FW_UPDATE_START_ADDR;
|
||||
PACKET_DN packet = csCanFwUpdateFunction.SectorErasePacket(SystemId, FW_UPDATE_START_ADDR);
|
||||
|
||||
OnSendDataCan?.Invoke(packet.hdr, packet.data);
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
MessageBox.Show(String.Format("FwUpdateStartProcess Fail - {0}", rResult));
|
||||
}
|
||||
}
|
||||
|
||||
private void SectorEraseProcess(PACKET_HEADER_DN hdr, byte[] data)
|
||||
{
|
||||
UInt32 rAddr = (UInt32)((data[0] << 24)
|
||||
| (data[1] << 16)
|
||||
| (data[2] << 8)
|
||||
| (data[3] << 0));
|
||||
byte rResult = data[7];
|
||||
UInt32 eSize = rAddr - FW_UPDATE_START_ADDR + FW_UPDATE_SECTOR_SIZE;
|
||||
|
||||
if (rResult == 0)
|
||||
{
|
||||
if (eSize < fwdata.Length)
|
||||
{
|
||||
SectorEraseAddr += FW_UPDATE_SECTOR_SIZE;
|
||||
PACKET_DN packet = csCanFwUpdateFunction.SectorErasePacket(SystemId, SectorEraseAddr);
|
||||
|
||||
OnSendDataCan?.Invoke(packet.hdr, packet.data);
|
||||
}
|
||||
else
|
||||
{
|
||||
SetAddr = FW_UPDATE_START_ADDR;
|
||||
SetLength = 2048 / 8;
|
||||
PACKET_DN packet = csCanFwUpdateFunction.SetAddrPacket(SystemId, SetAddr, SetLength);
|
||||
|
||||
OnSendDataCan?.Invoke(packet.hdr, packet.data);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
MessageBox.Show(String.Format("SectorEraseProcess Fail - {0}", rResult));
|
||||
}
|
||||
}
|
||||
|
||||
private void SeAddrProcess(PACKET_HEADER_DN hdr, byte[] data)
|
||||
{
|
||||
byte rResult = data[7];
|
||||
|
||||
if (rResult == 0)
|
||||
{
|
||||
UInt32 csum32 = 0;
|
||||
UInt32 CurrentAddr = SetAddr - FW_UPDATE_START_ADDR;
|
||||
UInt32 CurrentLen = SetLength;
|
||||
byte[][] pData;
|
||||
PACKET_DN packet;
|
||||
|
||||
pData = new byte[CurrentLen][];
|
||||
|
||||
for (int i = 0; i < CurrentLen; i++)
|
||||
{
|
||||
pData[i] = new byte[8];
|
||||
for (int j = 0; j < 8; j++)
|
||||
{
|
||||
if ((CurrentAddr + (i * 8) + j) < fwdata.Length)
|
||||
pData[i][j] = fwdata[CurrentAddr + (i * 8) + j];
|
||||
else
|
||||
pData[i][j] = 0x00;
|
||||
csum32 += (UInt32)pData[i][j];
|
||||
}
|
||||
packet = csCanFwUpdateFunction.WritePacket(SystemId, (byte)i, pData[i]);
|
||||
OnSendDataCan?.Invoke(packet.hdr, packet.data);
|
||||
|
||||
pgUpdate.Position += 8;
|
||||
UpdateTime = DateTime.Now - UpdateStartTime;
|
||||
lbUpdateTime.Text = String.Format("{0:mm}:{1:ss}", UpdateTime, UpdateTime);
|
||||
lbUpdateProgress.Text = String.Format("{0:#,##0}/{1:#,##0} bytes", pgUpdate.Position, fwdata.Length);
|
||||
Thread.Sleep(WR_PACKET_DELAY);
|
||||
|
||||
Application.DoEvents();
|
||||
if (StopUpdate) { return; }
|
||||
}
|
||||
packet = csCanFwUpdateFunction.WriteChkSumPacket(SystemId, SetAddr, csum32);
|
||||
|
||||
OnSendDataCan?.Invoke(packet.hdr, packet.data);
|
||||
}
|
||||
else
|
||||
{
|
||||
MessageBox.Show(String.Format("SeAddrProcess Fail - {0}", rResult));
|
||||
}
|
||||
}
|
||||
|
||||
//private void WritedataChkSumProcess(PACKET_HEADER_DN hdr, byte[] data)
|
||||
//{
|
||||
// byte rResult = data[7];
|
||||
|
||||
// if (rResult == 0)
|
||||
// {
|
||||
// UInt32 csum32 = 0;
|
||||
// CurrentAddr += 1;
|
||||
// byte[][] pData;
|
||||
// PACKET_DN packet;
|
||||
// int plen = 256;
|
||||
|
||||
// int blen = (int)(fwdata.Length - (CurrentAddr * 2048));
|
||||
|
||||
// if (blen < 2048)
|
||||
// plen = ((blen % 8) > 0) ? (blen / 8) + 1 : blen / 8;
|
||||
|
||||
// pData = new byte[plen][];
|
||||
|
||||
// for (int i = 0; i < plen; i++)
|
||||
// {
|
||||
// pData[i] = new byte[8];
|
||||
// for (int j = 0; j < 8; j++)
|
||||
// {
|
||||
// pData[i][j] = fwdata[(CurrentAddr * 2048) + (i * 8) + j];
|
||||
// csum32 += (UInt32)pData[i][j];
|
||||
// }
|
||||
// packet = csCanFwUpdateFunction.WritePacket(1, (byte)i, pData[i]);
|
||||
// OnSendDataCan?.Invoke(packet.hdr, packet.data);
|
||||
|
||||
// Thread.Sleep(1);
|
||||
// }
|
||||
// packet = csCanFwUpdateFunction.WriteChkSumPacket(1, csum32);
|
||||
|
||||
// OnSendDataCan?.Invoke(packet.hdr, packet.data);
|
||||
// }
|
||||
//}
|
||||
|
||||
private void WritedataChkSumProcess(PACKET_HEADER_DN hdr, byte[] data)
|
||||
{
|
||||
byte rResult = data[7];
|
||||
|
||||
if (rResult == 0)
|
||||
{
|
||||
UInt32 rAddr;
|
||||
UInt32 rlen, tlen;
|
||||
|
||||
rAddr = (UInt32)((data[0] << 24)
|
||||
| (data[1] << 16)
|
||||
| (data[2] << 8)
|
||||
| (data[3] << 0)
|
||||
);
|
||||
rlen = rAddr - SetAddr;
|
||||
tlen = rAddr - FW_UPDATE_START_ADDR;
|
||||
|
||||
UpdateTime = DateTime.Now - UpdateStartTime;
|
||||
lbUpdateTime.Text = String.Format("{0:mm}:{0:ss}", UpdateTime);
|
||||
lbUpdateProgress.Text = String.Format("{0:#,##0}/{1:#,##0} bytes", tlen, fwdata.Length);
|
||||
pgUpdate.Position = (int)tlen;
|
||||
|
||||
if (tlen < fwdata.Length)
|
||||
{
|
||||
// remain write data
|
||||
if (rlen == FW_UPDATE_PACKET_SIZE)
|
||||
{
|
||||
SetAddr = rAddr;
|
||||
UInt32 alen = (UInt32)(fwdata.Length - tlen);
|
||||
if (alen > FW_UPDATE_PACKET_SIZE)
|
||||
{
|
||||
SetLength = FW_UPDATE_PACKET_SIZE / 8;
|
||||
}
|
||||
else
|
||||
{
|
||||
if ((alen % 8) > 0)
|
||||
SetLength = alen / 8 + 1;
|
||||
else
|
||||
SetLength = alen / 8;
|
||||
}
|
||||
PACKET_DN packet = csCanFwUpdateFunction.SetAddrPacket(SystemId, SetAddr, SetLength);
|
||||
|
||||
OnSendDataCan?.Invoke(packet.hdr, packet.data);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// finished write data
|
||||
//string text = String.Format("Finished Write data - {0};{1}", tlen, fwdata.Length);
|
||||
//MessageBox.Show(text);
|
||||
UInt32 fwChkSum = 0;
|
||||
|
||||
for (int i = 0; i < fwdata.Length; i++)
|
||||
{
|
||||
fwChkSum += (UInt32)(fwdata[i]);
|
||||
}
|
||||
PACKET_DN packet = csCanFwUpdateFunction.FwImageChkSumPacket(SystemId, (UInt32)fwdata.Length, fwChkSum);
|
||||
|
||||
OnSendDataCan?.Invoke(packet.hdr, packet.data);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
MessageBox.Show(String.Format("WritedataChkSumProcess Fail - {0}", rResult));
|
||||
}
|
||||
}
|
||||
|
||||
private void FwImageChkSumProcess(PACKET_HEADER_DN hdr, byte[] data)
|
||||
{
|
||||
byte rResult = data[7];
|
||||
|
||||
if (rResult == 0)
|
||||
{
|
||||
PACKET_DN packet = csCanFwUpdateFunction.UpdateRestartPacket(SystemId, 3);
|
||||
|
||||
OnSendDataCan?.Invoke(packet.hdr, packet.data);
|
||||
|
||||
MessageBox.Show("Firmware Update Complete !!", "FwUpdate", MessageBoxButtons.OK, MessageBoxIcon.Information);
|
||||
lbUpdateStatus.Text = "Update Status : Complete";
|
||||
}
|
||||
else
|
||||
{
|
||||
MessageBox.Show(String.Format("FwImageChkSumProcess Fail - {0}", rResult));
|
||||
lbUpdateStatus.Text = "Update Status : Update failure (Image Checksum fail)";
|
||||
}
|
||||
btnFwUpdate.Text = "Firmware Update";
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region UPDATE FUNCTIONS
|
||||
private const int FirmwareUpdateTimeoutMax = 30; // 3 Sec
|
||||
private int FirmwareUpdateTimeout = 0; // 10 ms
|
||||
|
||||
private void FirmwareUpdateStop()
|
||||
{
|
||||
StopUpdate = true;
|
||||
FirmwareUpdateTimeoutClear();
|
||||
teModuleNo.Enabled = true;
|
||||
|
||||
lbUpdateStatus.Text = "Update Status : Restart";
|
||||
if (OnAutoTxCanSet != null)
|
||||
{
|
||||
OnAutoTxCanSet(true);
|
||||
}
|
||||
}
|
||||
|
||||
private void FirmwareUpdateTimeoutClear()
|
||||
{
|
||||
FirmwareUpdateTimeout = 0;
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region TIMER EVENT
|
||||
private void tmrFirmwareUpdate_Tick(object sender, EventArgs e)
|
||||
{
|
||||
if (StopUpdate == false)
|
||||
{
|
||||
FirmwareUpdateTimeout++;
|
||||
if (FirmwareUpdateTimeout > FirmwareUpdateTimeoutMax)
|
||||
{
|
||||
FirmwareUpdateStop();
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
151
LFP_Manager_PRM/Forms/fmxFwUpdate.resx
Normal file
151
LFP_Manager_PRM/Forms/fmxFwUpdate.resx
Normal file
@@ -0,0 +1,151 @@
|
||||
<?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="tmrFirmwareUpdate.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
|
||||
<data name="fmxFwUpdate.IconOptions.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
|
||||
wgAADsIBFShKgAAABMxJREFUWEflVWtsFVUQPrdtSvilMRIVY8T4h1/aoDGKqIWCIBXR+IgaAmriD/CR
|
||||
SIyVYjSSPmhLrVVTBa6tQNGIBSqYCEEera34KCqFEmgLNa34qPRaeqHv23G+2Z3tXrp3u/iHGCeZnN09
|
||||
M2e++WbOrKFLLP8dACMjI87qp2oTVAIBcB8Y8zncvRcUxEUxoIdGon3UdbbX0TPdvdR9vl/23HZBZFwA
|
||||
euDQcEzedze00aSF79Ckx9+nKx8rc3Tyo2V0+GSn2AyzbVAgvgD0gFgsRsOsfQNDNPXZCjLpq8nc9xaZ
|
||||
ucWW4vmuPJqZ9Rm8xDZIcEggBjT7VR8fJHNnLiUveNsKOr/EUn5Ovp+/MYhNe5vEFj5BWEgIQJ1BJ5qr
|
||||
5dcITcwsoZBmzIFDeBcA9jq7iK554gOK9PQJC8KEfVYiGbcEmv0Db1aTuTufkjKt7CXgvWu4BKw2C0lg
|
||||
YUYevbTugPgM2iz4iScAzX5waFjePz/YSmZWgUWzBuJSLF+7nx7J3SlB5Rv2GMwEXrUhxyvFGABqiMaD
|
||||
87neAbrxqTCF5hRx9hbVoTlr6CrufDRly+kIpc4rpiQO6oCbWUDpWVvsJPxZGAsAyg5KffZHdXGNJ+s9
|
||||
+bRhz1HZh7xa8bU0oGMDEPxeufeY7PuxEAdAjfQeH2/vsrJj9coOB6PRengITVmyXpjRxgzZDfk3Dy3Y
|
||||
gFGN4RbPEgAAZP7r26zGc+rL2fEt+Kn1TweA9smWmuNim8pDCgxgxfsKZgeiLFwoDgBs6qGQ7fUtdtcn
|
||||
6HAOjMxgj17AikFk0t7gkuWRmZ5L5o4cMrfnUE1jB9uOMusGIgD0g0w8NoqeH6Api9eTySi06LQpvW7R
|
||||
Ojp7rl8Cs5P4uAX/hWwGmF1RJ5mv3FBHr5Tto+pvWmXfi4U4BpTOrPLa+KuFldn4lGmGACSGTUPzH7Tn
|
||||
0C9UsfsIlWxtoPCXjfTF96dox7etcnWhO787SZ981UT1TactXwbvZsHoi9JztO0vuceotwTH4OGun51d
|
||||
JVmrHcB2MxsdnT104HA7vcYZX79orVUCph2ApRQzuBTTc+jyh96l385ExzQkA7AecDAkY0UVB1w9mj0r
|
||||
bsKRtk4ZyQrAS/C9fFcjXc1/RsNzI3VhKaXwORMetBpycfEusXOXgksw2nib9x3j+5vvTDy511wK3HMI
|
||||
slZHrKrICnua2YmOCE19+kOrh7SJsc4qpP0/t4uNgjB4wAGo6bVPMoUZRaONx1ncsCRMUZ6GsIFCFARE
|
||||
QejzwOCQPDfzz+syvopJ87SUDCC9gG5etpFt+AZxXAA2vf2Ww3LuXtTMoR4OXPtt9c2yr9m7g7tF9uy1
|
||||
3wZRWv3j2Gbm95Lth2Qf11duQeOpTmm8FM4agVMWlErN5q7cKoZe18dL1AaZwQd609KNMj1RTpydzP10
|
||||
xcPv0e9dUbbjEuBeT3u+0upcrhmMETyFJ96Jjq64xgsKAmqBJqrlISQ3gumXs3memNtWUSZPWYjJCtdS
|
||||
2nObaNoLlQLk1hc3Uxo3UGHVD2Lg1/V+Ah/tmZfDNZT2TLmcjRi3sCLmDvzmUYdEguw1+MWAcPv4+aH/
|
||||
nFGMYKryzvVR8TskkaiPnuUVA+JMQi+F6Ppv5MLzvNT5F1wq+b8DIPoHjJf5qaq9hPwAAAAASUVORK5C
|
||||
YII=
|
||||
</value>
|
||||
</data>
|
||||
</root>
|
||||
139
LFP_Manager_PRM/Forms/fmxHistory.Designer.cs
generated
Normal file
139
LFP_Manager_PRM/Forms/fmxHistory.Designer.cs
generated
Normal file
@@ -0,0 +1,139 @@
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
partial class fmxHistory
|
||||
{
|
||||
/// <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(fmxHistory));
|
||||
this.layoutControl1 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.btnClose = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.layoutControlGroup1 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem2 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.ucHistroy1 = new LFP_Manager.Controls.ucHistroy();
|
||||
this.layoutControlItem1 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).BeginInit();
|
||||
this.layoutControl1.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// layoutControl1
|
||||
//
|
||||
this.layoutControl1.Controls.Add(this.btnClose);
|
||||
this.layoutControl1.Controls.Add(this.ucHistroy1);
|
||||
this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControl1.Name = "layoutControl1";
|
||||
this.layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(1215, 341, 650, 400);
|
||||
this.layoutControl1.Root = this.layoutControlGroup1;
|
||||
this.layoutControl1.Size = new System.Drawing.Size(911, 602);
|
||||
this.layoutControl1.TabIndex = 0;
|
||||
this.layoutControl1.Text = "layoutControl1";
|
||||
//
|
||||
// btnClose
|
||||
//
|
||||
this.btnClose.Location = new System.Drawing.Point(3, 562);
|
||||
this.btnClose.Name = "btnClose";
|
||||
this.btnClose.Size = new System.Drawing.Size(905, 37);
|
||||
this.btnClose.StyleController = this.layoutControl1;
|
||||
this.btnClose.TabIndex = 5;
|
||||
this.btnClose.Text = "Close";
|
||||
this.btnClose.Click += new System.EventHandler(this.btnClose_Click);
|
||||
//
|
||||
// layoutControlGroup1
|
||||
//
|
||||
this.layoutControlGroup1.CustomizationFormText = "layoutControlGroup1";
|
||||
this.layoutControlGroup1.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.layoutControlGroup1.GroupBordersVisible = false;
|
||||
this.layoutControlGroup1.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem1,
|
||||
this.layoutControlItem2});
|
||||
this.layoutControlGroup1.Name = "Root";
|
||||
this.layoutControlGroup1.Padding = new DevExpress.XtraLayout.Utils.Padding(1, 1, 1, 1);
|
||||
this.layoutControlGroup1.Size = new System.Drawing.Size(911, 602);
|
||||
this.layoutControlGroup1.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem2
|
||||
//
|
||||
this.layoutControlItem2.Control = this.btnClose;
|
||||
this.layoutControlItem2.Location = new System.Drawing.Point(0, 559);
|
||||
this.layoutControlItem2.MinSize = new System.Drawing.Size(89, 26);
|
||||
this.layoutControlItem2.Name = "layoutControlItem2";
|
||||
this.layoutControlItem2.Size = new System.Drawing.Size(909, 41);
|
||||
this.layoutControlItem2.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem2.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem2.TextVisible = false;
|
||||
//
|
||||
// ucHistroy1
|
||||
//
|
||||
this.ucHistroy1.Location = new System.Drawing.Point(3, 3);
|
||||
this.ucHistroy1.Name = "ucHistroy1";
|
||||
this.ucHistroy1.Size = new System.Drawing.Size(905, 555);
|
||||
this.ucHistroy1.TabIndex = 4;
|
||||
//
|
||||
// layoutControlItem1
|
||||
//
|
||||
this.layoutControlItem1.Control = this.ucHistroy1;
|
||||
this.layoutControlItem1.CustomizationFormText = "layoutControlItem1";
|
||||
this.layoutControlItem1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem1.MinSize = new System.Drawing.Size(276, 117);
|
||||
this.layoutControlItem1.Name = "layoutControlItem1";
|
||||
this.layoutControlItem1.Size = new System.Drawing.Size(909, 559);
|
||||
this.layoutControlItem1.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem1.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem1.TextVisible = false;
|
||||
//
|
||||
// fmxHistory
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(911, 602);
|
||||
this.Controls.Add(this.layoutControl1);
|
||||
this.IconOptions.Image = ((System.Drawing.Image)(resources.GetObject("fmxHistory.IconOptions.Image")));
|
||||
this.Name = "fmxHistory";
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
|
||||
this.Text = "History";
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).EndInit();
|
||||
this.layoutControl1.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl1;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup1;
|
||||
private Controls.ucHistroy ucHistroy1;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem1;
|
||||
private DevExpress.XtraEditors.SimpleButton btnClose;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem2;
|
||||
}
|
||||
}
|
||||
42
LFP_Manager_PRM/Forms/fmxHistory.cs
Normal file
42
LFP_Manager_PRM/Forms/fmxHistory.cs
Normal file
@@ -0,0 +1,42 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Text;
|
||||
using System.Linq;
|
||||
using System.Windows.Forms;
|
||||
using DevExpress.XtraEditors;
|
||||
|
||||
using LFP_Manager.DataStructure;
|
||||
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
public partial class fmxHistory : DevExpress.XtraEditors.XtraForm
|
||||
{
|
||||
#region VARIABLES
|
||||
|
||||
#endregion
|
||||
|
||||
//public fmxHistory()
|
||||
//{
|
||||
// InitializeComponent();
|
||||
//}
|
||||
|
||||
public fmxHistory(CommConfig aConfig)
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
ucHistroy1.SetCommCofig(aConfig);
|
||||
}
|
||||
|
||||
#region BUTTON EVENT
|
||||
|
||||
private void btnClose_Click(object sender, EventArgs e)
|
||||
{
|
||||
Close();
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
148
LFP_Manager_PRM/Forms/fmxHistory.resx
Normal file
148
LFP_Manager_PRM/Forms/fmxHistory.resx
Normal file
@@ -0,0 +1,148 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
|
||||
<data name="fmxHistory.IconOptions.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
|
||||
wwAADsMBx2+oZAAABMxJREFUWEflVWtsFVUQPrdtSvilMRIVY8T4h1/aoDGKqIWCIBXR+IgaAmriD/CR
|
||||
SIyVYjSSPmhLrVVTBa6tQNGIBSqYCEEera34KCqFEmgLNa34qPRaeqHv23G+2Z3tXrp3u/iHGCeZnN09
|
||||
M2e++WbOrKFLLP8dACMjI87qp2oTVAIBcB8Y8zncvRcUxEUxoIdGon3UdbbX0TPdvdR9vl/23HZBZFwA
|
||||
euDQcEzedze00aSF79Ckx9+nKx8rc3Tyo2V0+GSn2AyzbVAgvgD0gFgsRsOsfQNDNPXZCjLpq8nc9xaZ
|
||||
ucWW4vmuPJqZ9Rm8xDZIcEggBjT7VR8fJHNnLiUveNsKOr/EUn5Ovp+/MYhNe5vEFj5BWEgIQJ1BJ5qr
|
||||
5dcITcwsoZBmzIFDeBcA9jq7iK554gOK9PQJC8KEfVYiGbcEmv0Db1aTuTufkjKt7CXgvWu4BKw2C0lg
|
||||
YUYevbTugPgM2iz4iScAzX5waFjePz/YSmZWgUWzBuJSLF+7nx7J3SlB5Rv2GMwEXrUhxyvFGABqiMaD
|
||||
87neAbrxqTCF5hRx9hbVoTlr6CrufDRly+kIpc4rpiQO6oCbWUDpWVvsJPxZGAsAyg5KffZHdXGNJ+s9
|
||||
+bRhz1HZh7xa8bU0oGMDEPxeufeY7PuxEAdAjfQeH2/vsrJj9coOB6PRengITVmyXpjRxgzZDfk3Dy3Y
|
||||
gFGN4RbPEgAAZP7r26zGc+rL2fEt+Kn1TweA9smWmuNim8pDCgxgxfsKZgeiLFwoDgBs6qGQ7fUtdtcn
|
||||
6HAOjMxgj17AikFk0t7gkuWRmZ5L5o4cMrfnUE1jB9uOMusGIgD0g0w8NoqeH6Api9eTySi06LQpvW7R
|
||||
Ojp7rl8Cs5P4uAX/hWwGmF1RJ5mv3FBHr5Tto+pvWmXfi4U4BpTOrPLa+KuFldn4lGmGACSGTUPzH7Tn
|
||||
0C9UsfsIlWxtoPCXjfTF96dox7etcnWhO787SZ981UT1TactXwbvZsHoi9JztO0vuceotwTH4OGun51d
|
||||
JVmrHcB2MxsdnT104HA7vcYZX79orVUCph2ApRQzuBTTc+jyh96l385ExzQkA7AecDAkY0UVB1w9mj0r
|
||||
bsKRtk4ZyQrAS/C9fFcjXc1/RsNzI3VhKaXwORMetBpycfEusXOXgksw2nib9x3j+5vvTDy511wK3HMI
|
||||
slZHrKrICnua2YmOCE19+kOrh7SJsc4qpP0/t4uNgjB4wAGo6bVPMoUZRaONx1ncsCRMUZ6GsIFCFARE
|
||||
QejzwOCQPDfzz+syvopJ87SUDCC9gG5etpFt+AZxXAA2vf2Ww3LuXtTMoR4OXPtt9c2yr9m7g7tF9uy1
|
||||
3wZRWv3j2Gbm95Lth2Qf11duQeOpTmm8FM4agVMWlErN5q7cKoZe18dL1AaZwQd609KNMj1RTpydzP10
|
||||
xcPv0e9dUbbjEuBeT3u+0upcrhmMETyFJ96Jjq64xgsKAmqBJqrlISQ3gumXs3memNtWUSZPWYjJCtdS
|
||||
2nObaNoLlQLk1hc3Uxo3UGHVD2Lg1/V+Ah/tmZfDNZT2TLmcjRi3sCLmDvzmUYdEguw1+MWAcPv4+aH/
|
||||
nFGMYKryzvVR8TskkaiPnuUVA+JMQi+F6Ppv5MLzvNT5F1wq+b8DIPoHjJf5qaq9hPwAAAAASUVORK5C
|
||||
YII=
|
||||
</value>
|
||||
</data>
|
||||
</root>
|
||||
103
LFP_Manager_PRM/Forms/fmxHistorycs.Designer.cs
generated
Normal file
103
LFP_Manager_PRM/Forms/fmxHistorycs.Designer.cs
generated
Normal file
@@ -0,0 +1,103 @@
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
partial class fmxHistorycs
|
||||
{
|
||||
/// <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.layoutControl1 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.layoutControlGroup1 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.ucHistroy1 = new LFP_Manager.Controls.ucHistroy();
|
||||
this.layoutControlItem1 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).BeginInit();
|
||||
this.layoutControl1.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// layoutControl1
|
||||
//
|
||||
this.layoutControl1.Controls.Add(this.ucHistroy1);
|
||||
this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControl1.Name = "layoutControl1";
|
||||
this.layoutControl1.Root = this.layoutControlGroup1;
|
||||
this.layoutControl1.Size = new System.Drawing.Size(911, 602);
|
||||
this.layoutControl1.TabIndex = 0;
|
||||
this.layoutControl1.Text = "layoutControl1";
|
||||
//
|
||||
// layoutControlGroup1
|
||||
//
|
||||
this.layoutControlGroup1.CustomizationFormText = "layoutControlGroup1";
|
||||
this.layoutControlGroup1.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.layoutControlGroup1.GroupBordersVisible = false;
|
||||
this.layoutControlGroup1.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem1});
|
||||
this.layoutControlGroup1.Name = "layoutControlGroup1";
|
||||
this.layoutControlGroup1.Size = new System.Drawing.Size(911, 602);
|
||||
this.layoutControlGroup1.TextVisible = false;
|
||||
//
|
||||
// ucHistroy1
|
||||
//
|
||||
this.ucHistroy1.Location = new System.Drawing.Point(12, 12);
|
||||
this.ucHistroy1.Name = "ucHistroy1";
|
||||
this.ucHistroy1.Size = new System.Drawing.Size(887, 578);
|
||||
this.ucHistroy1.TabIndex = 4;
|
||||
//
|
||||
// layoutControlItem1
|
||||
//
|
||||
this.layoutControlItem1.Control = this.ucHistroy1;
|
||||
this.layoutControlItem1.CustomizationFormText = "layoutControlItem1";
|
||||
this.layoutControlItem1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem1.Name = "layoutControlItem1";
|
||||
this.layoutControlItem1.Size = new System.Drawing.Size(891, 582);
|
||||
this.layoutControlItem1.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem1.TextVisible = false;
|
||||
//
|
||||
// fmxHistorycs
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(911, 602);
|
||||
this.Controls.Add(this.layoutControl1);
|
||||
this.Name = "fmxHistorycs";
|
||||
this.Text = "fmxHistorycs";
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).EndInit();
|
||||
this.layoutControl1.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl1;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup1;
|
||||
private Controls.ucHistroy ucHistroy1;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem1;
|
||||
}
|
||||
}
|
||||
20
LFP_Manager_PRM/Forms/fmxHistorycs.cs
Normal file
20
LFP_Manager_PRM/Forms/fmxHistorycs.cs
Normal file
@@ -0,0 +1,20 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Text;
|
||||
using System.Linq;
|
||||
using System.Windows.Forms;
|
||||
using DevExpress.XtraEditors;
|
||||
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
public partial class fmxHistorycs : DevExpress.XtraEditors.XtraForm
|
||||
{
|
||||
public fmxHistorycs()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
}
|
||||
}
|
||||
120
LFP_Manager_PRM/Forms/fmxHistorycs.resx
Normal file
120
LFP_Manager_PRM/Forms/fmxHistorycs.resx
Normal file
@@ -0,0 +1,120 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=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>
|
||||
388
LFP_Manager_PRM/Forms/fmxInventoryConfig.Designer.cs
generated
Normal file
388
LFP_Manager_PRM/Forms/fmxInventoryConfig.Designer.cs
generated
Normal file
@@ -0,0 +1,388 @@
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
partial class fmxInventoryConfig
|
||||
{
|
||||
/// <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.components = new System.ComponentModel.Container();
|
||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(fmxInventoryConfig));
|
||||
this.layoutControl1 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.btnClose = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.btnInvWrite = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.gbSerialNo = new DevExpress.XtraEditors.GroupControl();
|
||||
this.layoutControl2 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.nSerialNo = new DevExpress.XtraEditors.TextEdit();
|
||||
this.lbSerialNo = new DevExpress.XtraEditors.LabelControl();
|
||||
this.layoutControlGroup1 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem3 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem4 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.gbMDate = new DevExpress.XtraEditors.GroupControl();
|
||||
this.layoutControl3 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.lbMDate = new DevExpress.XtraEditors.LabelControl();
|
||||
this.layoutControlGroup2 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem9 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.Root = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem1 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem2 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem5 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem6 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.emptySpaceItem1 = new DevExpress.XtraLayout.EmptySpaceItem();
|
||||
this.tmrDisplay = new System.Windows.Forms.Timer(this.components);
|
||||
this.tmrCmd = new System.Windows.Forms.Timer(this.components);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).BeginInit();
|
||||
this.layoutControl1.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.gbSerialNo)).BeginInit();
|
||||
this.gbSerialNo.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl2)).BeginInit();
|
||||
this.layoutControl2.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nSerialNo.Properties)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.gbMDate)).BeginInit();
|
||||
this.gbMDate.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl3)).BeginInit();
|
||||
this.layoutControl3.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup2)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.Root)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem1)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// layoutControl1
|
||||
//
|
||||
this.layoutControl1.Controls.Add(this.btnClose);
|
||||
this.layoutControl1.Controls.Add(this.btnInvWrite);
|
||||
this.layoutControl1.Controls.Add(this.gbSerialNo);
|
||||
this.layoutControl1.Controls.Add(this.gbMDate);
|
||||
this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControl1.Name = "layoutControl1";
|
||||
this.layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(999, 164, 650, 400);
|
||||
this.layoutControl1.Root = this.Root;
|
||||
this.layoutControl1.Size = new System.Drawing.Size(720, 425);
|
||||
this.layoutControl1.TabIndex = 0;
|
||||
this.layoutControl1.Text = "layoutControl1";
|
||||
//
|
||||
// btnClose
|
||||
//
|
||||
this.btnClose.Appearance.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.btnClose.Appearance.Options.UseFont = true;
|
||||
this.btnClose.Location = new System.Drawing.Point(362, 373);
|
||||
this.btnClose.Name = "btnClose";
|
||||
this.btnClose.Size = new System.Drawing.Size(354, 48);
|
||||
this.btnClose.StyleController = this.layoutControl1;
|
||||
this.btnClose.TabIndex = 7;
|
||||
this.btnClose.Text = "Close";
|
||||
this.btnClose.Click += new System.EventHandler(this.btnClose_Click);
|
||||
//
|
||||
// btnInvWrite
|
||||
//
|
||||
this.btnInvWrite.Appearance.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.btnInvWrite.Appearance.Options.UseFont = true;
|
||||
this.btnInvWrite.Location = new System.Drawing.Point(4, 373);
|
||||
this.btnInvWrite.Name = "btnInvWrite";
|
||||
this.btnInvWrite.Size = new System.Drawing.Size(354, 48);
|
||||
this.btnInvWrite.StyleController = this.layoutControl1;
|
||||
this.btnInvWrite.TabIndex = 6;
|
||||
this.btnInvWrite.Text = "Apply";
|
||||
this.btnInvWrite.Click += new System.EventHandler(this.btnInvWrite_Click);
|
||||
//
|
||||
// gbSerialNo
|
||||
//
|
||||
this.gbSerialNo.Controls.Add(this.layoutControl2);
|
||||
this.gbSerialNo.Location = new System.Drawing.Point(4, 139);
|
||||
this.gbSerialNo.Name = "gbSerialNo";
|
||||
this.gbSerialNo.Size = new System.Drawing.Size(712, 200);
|
||||
this.gbSerialNo.TabIndex = 5;
|
||||
this.gbSerialNo.Text = "Serial Number";
|
||||
//
|
||||
// layoutControl2
|
||||
//
|
||||
this.layoutControl2.Controls.Add(this.nSerialNo);
|
||||
this.layoutControl2.Controls.Add(this.lbSerialNo);
|
||||
this.layoutControl2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl2.Location = new System.Drawing.Point(2, 23);
|
||||
this.layoutControl2.Name = "layoutControl2";
|
||||
this.layoutControl2.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(993, 64, 650, 400);
|
||||
this.layoutControl2.Root = this.layoutControlGroup1;
|
||||
this.layoutControl2.Size = new System.Drawing.Size(708, 175);
|
||||
this.layoutControl2.TabIndex = 0;
|
||||
this.layoutControl2.Text = "layoutControl2";
|
||||
//
|
||||
// nSerialNo
|
||||
//
|
||||
this.nSerialNo.Location = new System.Drawing.Point(7, 105);
|
||||
this.nSerialNo.Name = "nSerialNo";
|
||||
this.nSerialNo.Properties.Appearance.Font = new System.Drawing.Font("Tahoma", 36F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.nSerialNo.Properties.Appearance.Options.UseFont = true;
|
||||
this.nSerialNo.Properties.Appearance.Options.UseTextOptions = true;
|
||||
this.nSerialNo.Properties.Appearance.TextOptions.HAlignment = DevExpress.Utils.HorzAlignment.Center;
|
||||
this.nSerialNo.Size = new System.Drawing.Size(694, 64);
|
||||
this.nSerialNo.StyleController = this.layoutControl2;
|
||||
this.nSerialNo.TabIndex = 5;
|
||||
//
|
||||
// lbSerialNo
|
||||
//
|
||||
this.lbSerialNo.Appearance.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.lbSerialNo.Appearance.Options.UseFont = true;
|
||||
this.lbSerialNo.Location = new System.Drawing.Point(7, 7);
|
||||
this.lbSerialNo.Name = "lbSerialNo";
|
||||
this.lbSerialNo.Size = new System.Drawing.Size(694, 94);
|
||||
this.lbSerialNo.StyleController = this.layoutControl2;
|
||||
this.lbSerialNo.TabIndex = 4;
|
||||
this.lbSerialNo.Text = "Serial No:";
|
||||
//
|
||||
// layoutControlGroup1
|
||||
//
|
||||
this.layoutControlGroup1.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.layoutControlGroup1.GroupBordersVisible = false;
|
||||
this.layoutControlGroup1.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem3,
|
||||
this.layoutControlItem4});
|
||||
this.layoutControlGroup1.Name = "Root";
|
||||
this.layoutControlGroup1.Padding = new DevExpress.XtraLayout.Utils.Padding(5, 5, 5, 5);
|
||||
this.layoutControlGroup1.Size = new System.Drawing.Size(708, 175);
|
||||
this.layoutControlGroup1.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem3
|
||||
//
|
||||
this.layoutControlItem3.Control = this.lbSerialNo;
|
||||
this.layoutControlItem3.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem3.MinSize = new System.Drawing.Size(74, 18);
|
||||
this.layoutControlItem3.Name = "layoutControlItem3";
|
||||
this.layoutControlItem3.Size = new System.Drawing.Size(698, 98);
|
||||
this.layoutControlItem3.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem3.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem3.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem4
|
||||
//
|
||||
this.layoutControlItem4.Control = this.nSerialNo;
|
||||
this.layoutControlItem4.Location = new System.Drawing.Point(0, 98);
|
||||
this.layoutControlItem4.MaxSize = new System.Drawing.Size(0, 67);
|
||||
this.layoutControlItem4.MinSize = new System.Drawing.Size(171, 67);
|
||||
this.layoutControlItem4.Name = "layoutControlItem4";
|
||||
this.layoutControlItem4.Size = new System.Drawing.Size(698, 67);
|
||||
this.layoutControlItem4.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem4.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem4.TextVisible = false;
|
||||
//
|
||||
// gbMDate
|
||||
//
|
||||
this.gbMDate.Controls.Add(this.layoutControl3);
|
||||
this.gbMDate.Location = new System.Drawing.Point(4, 4);
|
||||
this.gbMDate.Name = "gbMDate";
|
||||
this.gbMDate.Size = new System.Drawing.Size(712, 131);
|
||||
this.gbMDate.TabIndex = 4;
|
||||
this.gbMDate.Text = "Manufacture Date";
|
||||
//
|
||||
// layoutControl3
|
||||
//
|
||||
this.layoutControl3.Controls.Add(this.lbMDate);
|
||||
this.layoutControl3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl3.Location = new System.Drawing.Point(2, 23);
|
||||
this.layoutControl3.Name = "layoutControl3";
|
||||
this.layoutControl3.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(993, 0, 650, 400);
|
||||
this.layoutControl3.Root = this.layoutControlGroup2;
|
||||
this.layoutControl3.Size = new System.Drawing.Size(708, 106);
|
||||
this.layoutControl3.TabIndex = 0;
|
||||
this.layoutControl3.Text = "layoutControl3";
|
||||
//
|
||||
// lbMDate
|
||||
//
|
||||
this.lbMDate.Appearance.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.lbMDate.Appearance.Options.UseFont = true;
|
||||
this.lbMDate.Location = new System.Drawing.Point(7, 7);
|
||||
this.lbMDate.Name = "lbMDate";
|
||||
this.lbMDate.Size = new System.Drawing.Size(694, 92);
|
||||
this.lbMDate.StyleController = this.layoutControl3;
|
||||
this.lbMDate.TabIndex = 6;
|
||||
this.lbMDate.Text = "Manufacture Date:";
|
||||
//
|
||||
// layoutControlGroup2
|
||||
//
|
||||
this.layoutControlGroup2.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.layoutControlGroup2.GroupBordersVisible = false;
|
||||
this.layoutControlGroup2.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem9});
|
||||
this.layoutControlGroup2.Name = "Root";
|
||||
this.layoutControlGroup2.Padding = new DevExpress.XtraLayout.Utils.Padding(5, 5, 5, 5);
|
||||
this.layoutControlGroup2.Size = new System.Drawing.Size(708, 106);
|
||||
this.layoutControlGroup2.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem9
|
||||
//
|
||||
this.layoutControlItem9.Control = this.lbMDate;
|
||||
this.layoutControlItem9.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem9.MinSize = new System.Drawing.Size(74, 18);
|
||||
this.layoutControlItem9.Name = "layoutControlItem9";
|
||||
this.layoutControlItem9.Size = new System.Drawing.Size(698, 96);
|
||||
this.layoutControlItem9.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem9.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem9.TextVisible = false;
|
||||
//
|
||||
// Root
|
||||
//
|
||||
this.Root.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.Root.GroupBordersVisible = false;
|
||||
this.Root.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem1,
|
||||
this.layoutControlItem2,
|
||||
this.layoutControlItem5,
|
||||
this.layoutControlItem6,
|
||||
this.emptySpaceItem1});
|
||||
this.Root.Name = "Root";
|
||||
this.Root.Padding = new DevExpress.XtraLayout.Utils.Padding(2, 2, 2, 2);
|
||||
this.Root.Size = new System.Drawing.Size(720, 425);
|
||||
this.Root.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem1
|
||||
//
|
||||
this.layoutControlItem1.Control = this.gbMDate;
|
||||
this.layoutControlItem1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem1.Name = "layoutControlItem1";
|
||||
this.layoutControlItem1.Size = new System.Drawing.Size(716, 135);
|
||||
this.layoutControlItem1.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem1.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem2
|
||||
//
|
||||
this.layoutControlItem2.Control = this.gbSerialNo;
|
||||
this.layoutControlItem2.Location = new System.Drawing.Point(0, 135);
|
||||
this.layoutControlItem2.Name = "layoutControlItem2";
|
||||
this.layoutControlItem2.Size = new System.Drawing.Size(716, 204);
|
||||
this.layoutControlItem2.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem2.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem5
|
||||
//
|
||||
this.layoutControlItem5.Control = this.btnInvWrite;
|
||||
this.layoutControlItem5.Location = new System.Drawing.Point(0, 369);
|
||||
this.layoutControlItem5.MinSize = new System.Drawing.Size(89, 26);
|
||||
this.layoutControlItem5.Name = "layoutControlItem5";
|
||||
this.layoutControlItem5.Size = new System.Drawing.Size(358, 52);
|
||||
this.layoutControlItem5.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem5.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem5.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem6
|
||||
//
|
||||
this.layoutControlItem6.Control = this.btnClose;
|
||||
this.layoutControlItem6.Location = new System.Drawing.Point(358, 369);
|
||||
this.layoutControlItem6.MinSize = new System.Drawing.Size(89, 26);
|
||||
this.layoutControlItem6.Name = "layoutControlItem6";
|
||||
this.layoutControlItem6.Size = new System.Drawing.Size(358, 52);
|
||||
this.layoutControlItem6.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem6.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem6.TextVisible = false;
|
||||
//
|
||||
// emptySpaceItem1
|
||||
//
|
||||
this.emptySpaceItem1.AllowHotTrack = false;
|
||||
this.emptySpaceItem1.Location = new System.Drawing.Point(0, 339);
|
||||
this.emptySpaceItem1.Name = "emptySpaceItem1";
|
||||
this.emptySpaceItem1.Size = new System.Drawing.Size(716, 30);
|
||||
this.emptySpaceItem1.TextSize = new System.Drawing.Size(0, 0);
|
||||
//
|
||||
// tmrDisplay
|
||||
//
|
||||
this.tmrDisplay.Tick += new System.EventHandler(this.tmrDisplay_Tick);
|
||||
//
|
||||
// tmrCmd
|
||||
//
|
||||
this.tmrCmd.Interval = 500;
|
||||
this.tmrCmd.Tick += new System.EventHandler(this.tmrCmd_Tick);
|
||||
//
|
||||
// fmxInventoryConfig
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(720, 425);
|
||||
this.Controls.Add(this.layoutControl1);
|
||||
this.IconOptions.Image = ((System.Drawing.Image)(resources.GetObject("fmxInventoryConfig.IconOptions.Image")));
|
||||
this.IconOptions.SvgImageColorizationMode = DevExpress.Utils.SvgImageColorizationMode.Full;
|
||||
this.Name = "fmxInventoryConfig";
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
|
||||
this.Text = "Inventory Config";
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).EndInit();
|
||||
this.layoutControl1.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.gbSerialNo)).EndInit();
|
||||
this.gbSerialNo.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl2)).EndInit();
|
||||
this.layoutControl2.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.nSerialNo.Properties)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.gbMDate)).EndInit();
|
||||
this.gbMDate.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl3)).EndInit();
|
||||
this.layoutControl3.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup2)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.Root)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem1)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl1;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup Root;
|
||||
private DevExpress.XtraEditors.GroupControl gbMDate;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem1;
|
||||
private DevExpress.XtraEditors.GroupControl gbSerialNo;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem2;
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl2;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup1;
|
||||
private DevExpress.XtraEditors.TextEdit nSerialNo;
|
||||
private DevExpress.XtraEditors.LabelControl lbSerialNo;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem3;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem4;
|
||||
private DevExpress.XtraEditors.SimpleButton btnClose;
|
||||
private DevExpress.XtraEditors.SimpleButton btnInvWrite;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem5;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem6;
|
||||
private DevExpress.XtraLayout.EmptySpaceItem emptySpaceItem1;
|
||||
private System.Windows.Forms.Timer tmrDisplay;
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl3;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup2;
|
||||
private DevExpress.XtraEditors.LabelControl lbMDate;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem9;
|
||||
private System.Windows.Forms.Timer tmrCmd;
|
||||
}
|
||||
}
|
||||
245
LFP_Manager_PRM/Forms/fmxInventoryConfig.cs
Normal file
245
LFP_Manager_PRM/Forms/fmxInventoryConfig.cs
Normal file
@@ -0,0 +1,245 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Text;
|
||||
using System.Linq;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
using DevExpress.XtraEditors;
|
||||
|
||||
using LFP_Manager.DataStructure;
|
||||
using LFP_Manager.Function;
|
||||
using LFP_Manager.Controls;
|
||||
using LFP_Manager.Utils;
|
||||
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
public delegate void InvDataUpdateEvent(object sendor);
|
||||
public delegate void InvDateCmdEvent(int sId, int mode, int flag, ref DeviceInforation wData);
|
||||
|
||||
public partial class fmxInventoryConfig : XtraForm
|
||||
{
|
||||
#region VARIABLES
|
||||
|
||||
CommConfig Config;
|
||||
|
||||
int SystemId = 0;
|
||||
int CmdResult = 0;
|
||||
DeviceSystemData SystemData;
|
||||
DeviceInforation wInvDate;
|
||||
|
||||
public event InvDataUpdateEvent OnUpdate = null;
|
||||
public event InvDateCmdEvent OnCommand = null;
|
||||
|
||||
#endregion
|
||||
public fmxInventoryConfig()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
public fmxInventoryConfig(CommConfig aConfig, int sId, ref DeviceSystemData aSystemData)
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
InitData();
|
||||
|
||||
Config = aConfig;
|
||||
SystemId = sId;
|
||||
SystemData = aSystemData;
|
||||
|
||||
tmrDisplay.Enabled = true;
|
||||
tmrCmd.Enabled = true;
|
||||
}
|
||||
|
||||
void InitData()
|
||||
{
|
||||
wInvDate = new DeviceInforation
|
||||
{
|
||||
pcb_sn = new byte[16]
|
||||
};
|
||||
}
|
||||
|
||||
#region DISPLAY DATA
|
||||
|
||||
private void DisplayValue()
|
||||
{
|
||||
// Manufacture Date
|
||||
lbMDate.Text = String.Format("Manufacture Date: {0} ({0:X8})", SystemData.Information.ManufactureDate)
|
||||
+ "\r\n"
|
||||
+ DisplayManufactureDate(SystemData.Information.ManufactureDate)
|
||||
;
|
||||
|
||||
// Device Serial Number
|
||||
byte[] tmp = new byte[SystemData.Information.pcb_sn.Length + 1];
|
||||
for (int i = 0; i < SystemData.Information.pcb_sn.Length; i++)
|
||||
tmp[i] = SystemData.Information.pcb_sn[i];
|
||||
tmp[SystemData.Information.pcb_sn.Length] = 0;
|
||||
|
||||
string strSerial = Encoding.Default.GetString(tmp).Trim('\0');
|
||||
lbSerialNo.Text = String.Format("Serial No: {0}", strSerial);
|
||||
}
|
||||
|
||||
private string DisplayManufactureDate(UInt32 mDate)
|
||||
{
|
||||
DateTime dtDate = csUtils.ConvertTimeStampToDateTime(mDate);
|
||||
|
||||
return String.Format("{0:yyyy-MM-dd hh:mm:ss}", dtDate);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region TIMER ENVENT
|
||||
private void tmrDisplay_Tick(object sender, EventArgs e)
|
||||
{
|
||||
DisplayValue();
|
||||
OnUpdate?.Invoke(this);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region PUBLIC FUCTIONS
|
||||
public void UpdateData(ref DeviceSystemData aSystemData)
|
||||
{
|
||||
SystemData = aSystemData;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region BUTTON EVENT
|
||||
private void btnMDateRead_Click(object sender, EventArgs e)
|
||||
{
|
||||
OnCommand?.Invoke(SystemId, 900, 0, ref wInvDate);
|
||||
OnCommand?.Invoke(SystemId, 901, 0, ref wInvDate);
|
||||
OnCommand?.Invoke(SystemId, 902, 0, ref wInvDate);
|
||||
}
|
||||
|
||||
private void btnWrite_Click(object sender, EventArgs e)
|
||||
{
|
||||
}
|
||||
private void btnInvWrite_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (nSerialNo.Text.Length == 15)
|
||||
{
|
||||
csDbUtils.MdDbCreate(Config, nSerialNo.Text);
|
||||
|
||||
if (CheckBmsSerialNo(nSerialNo.Text) == false)
|
||||
{
|
||||
byte[] bSN = Encoding.UTF8.GetBytes(nSerialNo.Text);
|
||||
|
||||
if (wInvDate.pcb_sn == null) wInvDate.pcb_sn = new byte[16];
|
||||
for (int i = 0; i < 16; i++) wInvDate.pcb_sn[i] = 0;
|
||||
for (int i = 0; i < bSN.Length; i++)
|
||||
{
|
||||
wInvDate.pcb_sn[i] = bSN[i];
|
||||
}
|
||||
OnCommand?.Invoke(SystemId, 901, 1, ref wInvDate);
|
||||
OnCommand?.Invoke(SystemId, 902, 1, ref wInvDate);
|
||||
|
||||
CmdMDateWrite();
|
||||
|
||||
CmdResult = 1;
|
||||
}
|
||||
else
|
||||
{
|
||||
MessageBox.Show(String.Format("Already used BMS serial number - [{0}]", nSerialNo.Text)
|
||||
, "Warning"
|
||||
, MessageBoxButtons.OK
|
||||
, MessageBoxIcon.Warning
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region PROCESSING DATA
|
||||
|
||||
private bool CheckBmsSerialNo(string bSN)
|
||||
{
|
||||
bool result = false;
|
||||
DataTable dtBmsData = new DataTable();
|
||||
DataTable dtBmsMatch = new DataTable();
|
||||
DataTable dtErrorLog = new DataTable();
|
||||
|
||||
//string sql = String.Format("SELECT * FROM TInventoryData WHERE pcb_sn = {0}", bSN);
|
||||
string sql = String.Format("SELECT * FROM TInventoryData");
|
||||
dtBmsData = csDbUtils.GetDataTableBySelect(Config, bSN, sql, "TInventoryData");
|
||||
|
||||
if (dtBmsData != null)
|
||||
{
|
||||
if (dtBmsData.Rows.Count > 1)
|
||||
{
|
||||
DataRow[] arrRows = null;
|
||||
arrRows = dtBmsData.Select(String.Format("pcb_sn = '{0}'", bSN));
|
||||
if (arrRows.Length > 0)
|
||||
result = true;
|
||||
}
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
private void CmdMDateWrite()
|
||||
{
|
||||
UInt32 mTimeStamp = csUtils.CalcKKTimeStamp(DateTime.Now);
|
||||
wInvDate.ManufactureDate = mTimeStamp;
|
||||
|
||||
OnCommand?.Invoke(SystemId, 900, 1, ref wInvDate);
|
||||
}
|
||||
|
||||
private void CheckResult()
|
||||
{
|
||||
if (CmdResult == 1)
|
||||
{
|
||||
bool result = false;
|
||||
|
||||
byte[] a = Encoding.UTF8.GetBytes(nSerialNo.Text);
|
||||
byte[] b = SystemData.Information.pcb_sn;
|
||||
|
||||
for (int i = 0; i < a.Length; i++)
|
||||
{
|
||||
if (a[i] == b[i]) continue;
|
||||
result = true;
|
||||
}
|
||||
|
||||
if ((result == false) && (wInvDate.ManufactureDate == SystemData.Information.ManufactureDate))
|
||||
{
|
||||
CmdResult = 0;
|
||||
|
||||
try
|
||||
{
|
||||
csDbUtils.BmsDataInsert(Config, SystemData, nSerialNo.Text);
|
||||
|
||||
MessageBox.Show(String.Format("BMS data insert complete - [{0}]", nSerialNo.Text)
|
||||
, "Information"
|
||||
, MessageBoxButtons.OK
|
||||
, MessageBoxIcon.Information
|
||||
);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
MessageBox.Show(String.Format("BMS data insert fail - [{0}] \r\n{1}", nSerialNo.Text, ex.Message)
|
||||
, "Warning"
|
||||
, MessageBoxButtons.OK
|
||||
, MessageBoxIcon.Warning
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
private void tmrCmd_Tick(object sender, EventArgs e)
|
||||
{
|
||||
OnCommand?.Invoke(SystemId, 900, 0, ref wInvDate);
|
||||
OnCommand?.Invoke(SystemId, 901, 0, ref wInvDate);
|
||||
OnCommand?.Invoke(SystemId, 902, 0, ref wInvDate);
|
||||
|
||||
CheckResult();
|
||||
}
|
||||
|
||||
private void btnClose_Click(object sender, EventArgs e)
|
||||
{
|
||||
Close();
|
||||
}
|
||||
}
|
||||
}
|
||||
154
LFP_Manager_PRM/Forms/fmxInventoryConfig.resx
Normal file
154
LFP_Manager_PRM/Forms/fmxInventoryConfig.resx
Normal file
@@ -0,0 +1,154 @@
|
||||
<?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="tmrDisplay.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
<metadata name="tmrCmd.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>128, 17</value>
|
||||
</metadata>
|
||||
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
|
||||
<data name="fmxInventoryConfig.IconOptions.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
|
||||
wwAADsMBx2+oZAAABMxJREFUWEflVWtsFVUQPrdtSvilMRIVY8T4h1/aoDGKqIWCIBXR+IgaAmriD/CR
|
||||
SIyVYjSSPmhLrVVTBa6tQNGIBSqYCEEera34KCqFEmgLNa34qPRaeqHv23G+2Z3tXrp3u/iHGCeZnN09
|
||||
M2e++WbOrKFLLP8dACMjI87qp2oTVAIBcB8Y8zncvRcUxEUxoIdGon3UdbbX0TPdvdR9vl/23HZBZFwA
|
||||
euDQcEzedze00aSF79Ckx9+nKx8rc3Tyo2V0+GSn2AyzbVAgvgD0gFgsRsOsfQNDNPXZCjLpq8nc9xaZ
|
||||
ucWW4vmuPJqZ9Rm8xDZIcEggBjT7VR8fJHNnLiUveNsKOr/EUn5Ovp+/MYhNe5vEFj5BWEgIQJ1BJ5qr
|
||||
5dcITcwsoZBmzIFDeBcA9jq7iK554gOK9PQJC8KEfVYiGbcEmv0Db1aTuTufkjKt7CXgvWu4BKw2C0lg
|
||||
YUYevbTugPgM2iz4iScAzX5waFjePz/YSmZWgUWzBuJSLF+7nx7J3SlB5Rv2GMwEXrUhxyvFGABqiMaD
|
||||
87neAbrxqTCF5hRx9hbVoTlr6CrufDRly+kIpc4rpiQO6oCbWUDpWVvsJPxZGAsAyg5KffZHdXGNJ+s9
|
||||
+bRhz1HZh7xa8bU0oGMDEPxeufeY7PuxEAdAjfQeH2/vsrJj9coOB6PRengITVmyXpjRxgzZDfk3Dy3Y
|
||||
gFGN4RbPEgAAZP7r26zGc+rL2fEt+Kn1TweA9smWmuNim8pDCgxgxfsKZgeiLFwoDgBs6qGQ7fUtdtcn
|
||||
6HAOjMxgj17AikFk0t7gkuWRmZ5L5o4cMrfnUE1jB9uOMusGIgD0g0w8NoqeH6Api9eTySi06LQpvW7R
|
||||
Ojp7rl8Cs5P4uAX/hWwGmF1RJ5mv3FBHr5Tto+pvWmXfi4U4BpTOrPLa+KuFldn4lGmGACSGTUPzH7Tn
|
||||
0C9UsfsIlWxtoPCXjfTF96dox7etcnWhO787SZ981UT1TactXwbvZsHoi9JztO0vuceotwTH4OGun51d
|
||||
JVmrHcB2MxsdnT104HA7vcYZX79orVUCph2ApRQzuBTTc+jyh96l385ExzQkA7AecDAkY0UVB1w9mj0r
|
||||
bsKRtk4ZyQrAS/C9fFcjXc1/RsNzI3VhKaXwORMetBpycfEusXOXgksw2nib9x3j+5vvTDy511wK3HMI
|
||||
slZHrKrICnua2YmOCE19+kOrh7SJsc4qpP0/t4uNgjB4wAGo6bVPMoUZRaONx1ncsCRMUZ6GsIFCFARE
|
||||
QejzwOCQPDfzz+syvopJ87SUDCC9gG5etpFt+AZxXAA2vf2Ww3LuXtTMoR4OXPtt9c2yr9m7g7tF9uy1
|
||||
3wZRWv3j2Gbm95Lth2Qf11duQeOpTmm8FM4agVMWlErN5q7cKoZe18dL1AaZwQd609KNMj1RTpydzP10
|
||||
xcPv0e9dUbbjEuBeT3u+0upcrhmMETyFJ96Jjq64xgsKAmqBJqrlISQ3gumXs3memNtWUSZPWYjJCtdS
|
||||
2nObaNoLlQLk1hc3Uxo3UGHVD2Lg1/V+Ah/tmZfDNZT2TLmcjRi3sCLmDvzmUYdEguw1+MWAcPv4+aH/
|
||||
nFGMYKryzvVR8TskkaiPnuUVA+JMQi+F6Ppv5MLzvNT5F1wq+b8DIPoHjJf5qaq9hPwAAAAASUVORK5C
|
||||
YII=
|
||||
</value>
|
||||
</data>
|
||||
</root>
|
||||
591
LFP_Manager_PRM/Forms/fmxInventoryConfig2.Designer.cs
generated
Normal file
591
LFP_Manager_PRM/Forms/fmxInventoryConfig2.Designer.cs
generated
Normal file
@@ -0,0 +1,591 @@
|
||||
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
partial class fmxInventoryConfig2
|
||||
{
|
||||
/// <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.components = new System.ComponentModel.Container();
|
||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(fmxInventoryConfig2));
|
||||
this.layoutControl1 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.btnRefresh = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.btnExportExcel = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.mnView = new System.Windows.Forms.DataGridView();
|
||||
this.groupControl2 = new DevExpress.XtraEditors.GroupControl();
|
||||
this.layoutControl4 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.lbResult = new DevExpress.XtraEditors.LabelControl();
|
||||
this.layoutControlGroup3 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem7 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.groupControl1 = new DevExpress.XtraEditors.GroupControl();
|
||||
this.layoutControl3 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.lbPcbSerial = new DevExpress.XtraEditors.LabelControl();
|
||||
this.layoutControlGroup2 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem6 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.btnClose = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.btnInvWrite = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.gbSerialNo = new DevExpress.XtraEditors.GroupControl();
|
||||
this.layoutControl2 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.nMdNo = new DevExpress.XtraEditors.TextEdit();
|
||||
this.lbMdSerial = new DevExpress.XtraEditors.LabelControl();
|
||||
this.layoutControlGroup1 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem3 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem4 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.Root = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem1 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem5 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem2 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem8 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem10 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.gbDvResult = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem11 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.emptySpaceItem1 = new DevExpress.XtraLayout.EmptySpaceItem();
|
||||
this.layoutControlItem9 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem12 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.tmrDisplay = new System.Windows.Forms.Timer(this.components);
|
||||
this.tmrCmd = new System.Windows.Forms.Timer(this.components);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).BeginInit();
|
||||
this.layoutControl1.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.mnView)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.groupControl2)).BeginInit();
|
||||
this.groupControl2.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl4)).BeginInit();
|
||||
this.layoutControl4.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup3)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.groupControl1)).BeginInit();
|
||||
this.groupControl1.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl3)).BeginInit();
|
||||
this.layoutControl3.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup2)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.gbSerialNo)).BeginInit();
|
||||
this.gbSerialNo.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl2)).BeginInit();
|
||||
this.layoutControl2.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.nMdNo.Properties)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.Root)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem10)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.gbDvResult)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem11)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem12)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// layoutControl1
|
||||
//
|
||||
this.layoutControl1.Controls.Add(this.btnRefresh);
|
||||
this.layoutControl1.Controls.Add(this.btnExportExcel);
|
||||
this.layoutControl1.Controls.Add(this.mnView);
|
||||
this.layoutControl1.Controls.Add(this.groupControl2);
|
||||
this.layoutControl1.Controls.Add(this.groupControl1);
|
||||
this.layoutControl1.Controls.Add(this.btnClose);
|
||||
this.layoutControl1.Controls.Add(this.btnInvWrite);
|
||||
this.layoutControl1.Controls.Add(this.gbSerialNo);
|
||||
this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl1.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControl1.Name = "layoutControl1";
|
||||
this.layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(999, 164, 650, 400);
|
||||
this.layoutControl1.Root = this.Root;
|
||||
this.layoutControl1.Size = new System.Drawing.Size(798, 538);
|
||||
this.layoutControl1.TabIndex = 0;
|
||||
this.layoutControl1.Text = "layoutControl1";
|
||||
//
|
||||
// btnRefresh
|
||||
//
|
||||
this.btnRefresh.Location = new System.Drawing.Point(8, 472);
|
||||
this.btnRefresh.Name = "btnRefresh";
|
||||
this.btnRefresh.Size = new System.Drawing.Size(98, 22);
|
||||
this.btnRefresh.StyleController = this.layoutControl1;
|
||||
this.btnRefresh.TabIndex = 13;
|
||||
this.btnRefresh.Text = "Refresh";
|
||||
this.btnRefresh.Click += new System.EventHandler(this.btnRefresh_Click);
|
||||
//
|
||||
// btnExportExcel
|
||||
//
|
||||
this.btnExportExcel.Location = new System.Drawing.Point(703, 472);
|
||||
this.btnExportExcel.Name = "btnExportExcel";
|
||||
this.btnExportExcel.Size = new System.Drawing.Size(87, 22);
|
||||
this.btnExportExcel.StyleController = this.layoutControl1;
|
||||
this.btnExportExcel.TabIndex = 12;
|
||||
this.btnExportExcel.Text = "Export";
|
||||
this.btnExportExcel.Click += new System.EventHandler(this.btnExportExcel_Click);
|
||||
//
|
||||
// mnView
|
||||
//
|
||||
this.mnView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
||||
this.mnView.Location = new System.Drawing.Point(8, 344);
|
||||
this.mnView.Name = "mnView";
|
||||
this.mnView.ReadOnly = true;
|
||||
this.mnView.RowTemplate.Height = 23;
|
||||
this.mnView.Size = new System.Drawing.Size(782, 124);
|
||||
this.mnView.TabIndex = 11;
|
||||
//
|
||||
// groupControl2
|
||||
//
|
||||
this.groupControl2.Controls.Add(this.layoutControl4);
|
||||
this.groupControl2.Location = new System.Drawing.Point(4, 234);
|
||||
this.groupControl2.Name = "groupControl2";
|
||||
this.groupControl2.Size = new System.Drawing.Size(790, 81);
|
||||
this.groupControl2.TabIndex = 10;
|
||||
this.groupControl2.Text = "Status";
|
||||
//
|
||||
// layoutControl4
|
||||
//
|
||||
this.layoutControl4.Controls.Add(this.lbResult);
|
||||
this.layoutControl4.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl4.Location = new System.Drawing.Point(2, 23);
|
||||
this.layoutControl4.Name = "layoutControl4";
|
||||
this.layoutControl4.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(993, 64, 650, 400);
|
||||
this.layoutControl4.Root = this.layoutControlGroup3;
|
||||
this.layoutControl4.Size = new System.Drawing.Size(786, 56);
|
||||
this.layoutControl4.TabIndex = 0;
|
||||
this.layoutControl4.Text = "layoutControl4";
|
||||
//
|
||||
// lbResult
|
||||
//
|
||||
this.lbResult.Appearance.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.lbResult.Appearance.Options.UseFont = true;
|
||||
this.lbResult.Appearance.Options.UseTextOptions = true;
|
||||
this.lbResult.Appearance.TextOptions.HAlignment = DevExpress.Utils.HorzAlignment.Center;
|
||||
this.lbResult.Location = new System.Drawing.Point(7, 7);
|
||||
this.lbResult.Name = "lbResult";
|
||||
this.lbResult.Size = new System.Drawing.Size(772, 42);
|
||||
this.lbResult.StyleController = this.layoutControl4;
|
||||
this.lbResult.TabIndex = 4;
|
||||
this.lbResult.Text = "Ready";
|
||||
//
|
||||
// layoutControlGroup3
|
||||
//
|
||||
this.layoutControlGroup3.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.layoutControlGroup3.GroupBordersVisible = false;
|
||||
this.layoutControlGroup3.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem7});
|
||||
this.layoutControlGroup3.Name = "Root";
|
||||
this.layoutControlGroup3.Padding = new DevExpress.XtraLayout.Utils.Padding(5, 5, 5, 5);
|
||||
this.layoutControlGroup3.Size = new System.Drawing.Size(786, 56);
|
||||
this.layoutControlGroup3.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem7
|
||||
//
|
||||
this.layoutControlItem7.Control = this.lbResult;
|
||||
this.layoutControlItem7.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem7.MinSize = new System.Drawing.Size(74, 18);
|
||||
this.layoutControlItem7.Name = "layoutControlItem3";
|
||||
this.layoutControlItem7.Size = new System.Drawing.Size(776, 46);
|
||||
this.layoutControlItem7.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem7.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem7.TextVisible = false;
|
||||
//
|
||||
// groupControl1
|
||||
//
|
||||
this.groupControl1.Controls.Add(this.layoutControl3);
|
||||
this.groupControl1.Location = new System.Drawing.Point(4, 4);
|
||||
this.groupControl1.Name = "groupControl1";
|
||||
this.groupControl1.Size = new System.Drawing.Size(790, 77);
|
||||
this.groupControl1.TabIndex = 7;
|
||||
this.groupControl1.Text = "BMS Serial Number";
|
||||
//
|
||||
// layoutControl3
|
||||
//
|
||||
this.layoutControl3.Controls.Add(this.lbPcbSerial);
|
||||
this.layoutControl3.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl3.Location = new System.Drawing.Point(2, 23);
|
||||
this.layoutControl3.Name = "layoutControl3";
|
||||
this.layoutControl3.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(993, 64, 650, 400);
|
||||
this.layoutControl3.Root = this.layoutControlGroup2;
|
||||
this.layoutControl3.Size = new System.Drawing.Size(786, 52);
|
||||
this.layoutControl3.TabIndex = 0;
|
||||
this.layoutControl3.Text = "layoutControl3";
|
||||
//
|
||||
// lbPcbSerial
|
||||
//
|
||||
this.lbPcbSerial.Appearance.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.lbPcbSerial.Appearance.Options.UseFont = true;
|
||||
this.lbPcbSerial.Location = new System.Drawing.Point(7, 7);
|
||||
this.lbPcbSerial.Name = "lbPcbSerial";
|
||||
this.lbPcbSerial.Size = new System.Drawing.Size(772, 38);
|
||||
this.lbPcbSerial.StyleController = this.layoutControl3;
|
||||
this.lbPcbSerial.TabIndex = 4;
|
||||
this.lbPcbSerial.Text = "BMS S/N:";
|
||||
//
|
||||
// layoutControlGroup2
|
||||
//
|
||||
this.layoutControlGroup2.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.layoutControlGroup2.GroupBordersVisible = false;
|
||||
this.layoutControlGroup2.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem6});
|
||||
this.layoutControlGroup2.Name = "Root";
|
||||
this.layoutControlGroup2.Padding = new DevExpress.XtraLayout.Utils.Padding(5, 5, 5, 5);
|
||||
this.layoutControlGroup2.Size = new System.Drawing.Size(786, 52);
|
||||
this.layoutControlGroup2.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem6
|
||||
//
|
||||
this.layoutControlItem6.Control = this.lbPcbSerial;
|
||||
this.layoutControlItem6.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem6.MinSize = new System.Drawing.Size(74, 18);
|
||||
this.layoutControlItem6.Name = "layoutControlItem3";
|
||||
this.layoutControlItem6.Size = new System.Drawing.Size(776, 42);
|
||||
this.layoutControlItem6.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem6.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem6.TextVisible = false;
|
||||
//
|
||||
// btnClose
|
||||
//
|
||||
this.btnClose.Appearance.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.btnClose.Appearance.Options.UseFont = true;
|
||||
this.btnClose.Location = new System.Drawing.Point(401, 502);
|
||||
this.btnClose.Name = "btnClose";
|
||||
this.btnClose.Size = new System.Drawing.Size(393, 32);
|
||||
this.btnClose.StyleController = this.layoutControl1;
|
||||
this.btnClose.TabIndex = 9;
|
||||
this.btnClose.Text = "Close";
|
||||
this.btnClose.Click += new System.EventHandler(this.btnClose_Click);
|
||||
//
|
||||
// btnInvWrite
|
||||
//
|
||||
this.btnInvWrite.Appearance.Font = new System.Drawing.Font("Tahoma", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.btnInvWrite.Appearance.Options.UseFont = true;
|
||||
this.btnInvWrite.Location = new System.Drawing.Point(4, 502);
|
||||
this.btnInvWrite.Name = "btnInvWrite";
|
||||
this.btnInvWrite.Size = new System.Drawing.Size(393, 32);
|
||||
this.btnInvWrite.StyleController = this.layoutControl1;
|
||||
this.btnInvWrite.TabIndex = 8;
|
||||
this.btnInvWrite.Text = "Apply";
|
||||
//
|
||||
// gbSerialNo
|
||||
//
|
||||
this.gbSerialNo.Controls.Add(this.layoutControl2);
|
||||
this.gbSerialNo.Location = new System.Drawing.Point(4, 85);
|
||||
this.gbSerialNo.Name = "gbSerialNo";
|
||||
this.gbSerialNo.Size = new System.Drawing.Size(790, 145);
|
||||
this.gbSerialNo.TabIndex = 6;
|
||||
this.gbSerialNo.Text = "Module Number";
|
||||
//
|
||||
// layoutControl2
|
||||
//
|
||||
this.layoutControl2.Controls.Add(this.nMdNo);
|
||||
this.layoutControl2.Controls.Add(this.lbMdSerial);
|
||||
this.layoutControl2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl2.Location = new System.Drawing.Point(2, 23);
|
||||
this.layoutControl2.Name = "layoutControl2";
|
||||
this.layoutControl2.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(993, 64, 650, 400);
|
||||
this.layoutControl2.Root = this.layoutControlGroup1;
|
||||
this.layoutControl2.Size = new System.Drawing.Size(786, 120);
|
||||
this.layoutControl2.TabIndex = 0;
|
||||
this.layoutControl2.Text = "layoutControl2";
|
||||
//
|
||||
// nMdNo
|
||||
//
|
||||
this.nMdNo.Location = new System.Drawing.Point(7, 50);
|
||||
this.nMdNo.Name = "nMdNo";
|
||||
this.nMdNo.Properties.Appearance.Font = new System.Drawing.Font("Tahoma", 36F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.nMdNo.Properties.Appearance.Options.UseFont = true;
|
||||
this.nMdNo.Properties.Appearance.Options.UseTextOptions = true;
|
||||
this.nMdNo.Properties.Appearance.TextOptions.HAlignment = DevExpress.Utils.HorzAlignment.Center;
|
||||
this.nMdNo.Properties.ReadOnly = true;
|
||||
this.nMdNo.Size = new System.Drawing.Size(772, 64);
|
||||
this.nMdNo.StyleController = this.layoutControl2;
|
||||
this.nMdNo.TabIndex = 5;
|
||||
//
|
||||
// lbMdSerial
|
||||
//
|
||||
this.lbMdSerial.Appearance.Font = new System.Drawing.Font("Tahoma", 15.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.lbMdSerial.Appearance.Options.UseFont = true;
|
||||
this.lbMdSerial.Location = new System.Drawing.Point(7, 7);
|
||||
this.lbMdSerial.Name = "lbMdSerial";
|
||||
this.lbMdSerial.Size = new System.Drawing.Size(772, 39);
|
||||
this.lbMdSerial.StyleController = this.layoutControl2;
|
||||
this.lbMdSerial.TabIndex = 4;
|
||||
this.lbMdSerial.Text = "Module S/N:";
|
||||
//
|
||||
// layoutControlGroup1
|
||||
//
|
||||
this.layoutControlGroup1.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.layoutControlGroup1.GroupBordersVisible = false;
|
||||
this.layoutControlGroup1.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem3,
|
||||
this.layoutControlItem4});
|
||||
this.layoutControlGroup1.Name = "Root";
|
||||
this.layoutControlGroup1.Padding = new DevExpress.XtraLayout.Utils.Padding(5, 5, 5, 5);
|
||||
this.layoutControlGroup1.Size = new System.Drawing.Size(786, 120);
|
||||
this.layoutControlGroup1.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem3
|
||||
//
|
||||
this.layoutControlItem3.Control = this.lbMdSerial;
|
||||
this.layoutControlItem3.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem3.MinSize = new System.Drawing.Size(74, 18);
|
||||
this.layoutControlItem3.Name = "layoutControlItem3";
|
||||
this.layoutControlItem3.Size = new System.Drawing.Size(776, 43);
|
||||
this.layoutControlItem3.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem3.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem3.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem4
|
||||
//
|
||||
this.layoutControlItem4.Control = this.nMdNo;
|
||||
this.layoutControlItem4.Location = new System.Drawing.Point(0, 43);
|
||||
this.layoutControlItem4.MaxSize = new System.Drawing.Size(0, 67);
|
||||
this.layoutControlItem4.MinSize = new System.Drawing.Size(171, 67);
|
||||
this.layoutControlItem4.Name = "layoutControlItem4";
|
||||
this.layoutControlItem4.Size = new System.Drawing.Size(776, 67);
|
||||
this.layoutControlItem4.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem4.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem4.TextVisible = false;
|
||||
//
|
||||
// Root
|
||||
//
|
||||
this.Root.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.Root.GroupBordersVisible = false;
|
||||
this.Root.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem1,
|
||||
this.layoutControlItem5,
|
||||
this.layoutControlItem2,
|
||||
this.layoutControlItem8,
|
||||
this.layoutControlItem10,
|
||||
this.gbDvResult});
|
||||
this.Root.Name = "Root";
|
||||
this.Root.Padding = new DevExpress.XtraLayout.Utils.Padding(2, 2, 2, 2);
|
||||
this.Root.Size = new System.Drawing.Size(798, 538);
|
||||
this.Root.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem1
|
||||
//
|
||||
this.layoutControlItem1.Control = this.gbSerialNo;
|
||||
this.layoutControlItem1.Location = new System.Drawing.Point(0, 81);
|
||||
this.layoutControlItem1.MaxSize = new System.Drawing.Size(0, 149);
|
||||
this.layoutControlItem1.MinSize = new System.Drawing.Size(189, 149);
|
||||
this.layoutControlItem1.Name = "layoutControlItem1";
|
||||
this.layoutControlItem1.Size = new System.Drawing.Size(794, 149);
|
||||
this.layoutControlItem1.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem1.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem1.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem5
|
||||
//
|
||||
this.layoutControlItem5.Control = this.btnInvWrite;
|
||||
this.layoutControlItem5.Location = new System.Drawing.Point(0, 498);
|
||||
this.layoutControlItem5.MaxSize = new System.Drawing.Size(0, 36);
|
||||
this.layoutControlItem5.MinSize = new System.Drawing.Size(57, 36);
|
||||
this.layoutControlItem5.Name = "layoutControlItem5";
|
||||
this.layoutControlItem5.Size = new System.Drawing.Size(397, 36);
|
||||
this.layoutControlItem5.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem5.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem5.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem2
|
||||
//
|
||||
this.layoutControlItem2.Control = this.btnClose;
|
||||
this.layoutControlItem2.Location = new System.Drawing.Point(397, 498);
|
||||
this.layoutControlItem2.MaxSize = new System.Drawing.Size(0, 36);
|
||||
this.layoutControlItem2.MinSize = new System.Drawing.Size(55, 36);
|
||||
this.layoutControlItem2.Name = "layoutControlItem2";
|
||||
this.layoutControlItem2.Size = new System.Drawing.Size(397, 36);
|
||||
this.layoutControlItem2.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem2.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem2.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem8
|
||||
//
|
||||
this.layoutControlItem8.Control = this.groupControl1;
|
||||
this.layoutControlItem8.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem8.MaxSize = new System.Drawing.Size(0, 81);
|
||||
this.layoutControlItem8.MinSize = new System.Drawing.Size(92, 81);
|
||||
this.layoutControlItem8.Name = "layoutControlItem8";
|
||||
this.layoutControlItem8.Size = new System.Drawing.Size(794, 81);
|
||||
this.layoutControlItem8.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem8.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem8.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem10
|
||||
//
|
||||
this.layoutControlItem10.Control = this.groupControl2;
|
||||
this.layoutControlItem10.Location = new System.Drawing.Point(0, 230);
|
||||
this.layoutControlItem10.MaxSize = new System.Drawing.Size(0, 85);
|
||||
this.layoutControlItem10.MinSize = new System.Drawing.Size(92, 85);
|
||||
this.layoutControlItem10.Name = "layoutControlItem10";
|
||||
this.layoutControlItem10.Size = new System.Drawing.Size(794, 85);
|
||||
this.layoutControlItem10.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem10.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem10.TextVisible = false;
|
||||
//
|
||||
// gbDvResult
|
||||
//
|
||||
this.gbDvResult.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem11,
|
||||
this.emptySpaceItem1,
|
||||
this.layoutControlItem9,
|
||||
this.layoutControlItem12});
|
||||
this.gbDvResult.Location = new System.Drawing.Point(0, 315);
|
||||
this.gbDvResult.Name = "gbDvResult";
|
||||
this.gbDvResult.Padding = new DevExpress.XtraLayout.Utils.Padding(1, 1, 1, 1);
|
||||
this.gbDvResult.Size = new System.Drawing.Size(794, 183);
|
||||
this.gbDvResult.Text = "Module Number List";
|
||||
//
|
||||
// layoutControlItem11
|
||||
//
|
||||
this.layoutControlItem11.Control = this.btnExportExcel;
|
||||
this.layoutControlItem11.Location = new System.Drawing.Point(695, 128);
|
||||
this.layoutControlItem11.MinSize = new System.Drawing.Size(89, 26);
|
||||
this.layoutControlItem11.Name = "layoutControlItem11";
|
||||
this.layoutControlItem11.Size = new System.Drawing.Size(91, 26);
|
||||
this.layoutControlItem11.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem11.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem11.TextVisible = false;
|
||||
//
|
||||
// emptySpaceItem1
|
||||
//
|
||||
this.emptySpaceItem1.AllowHotTrack = false;
|
||||
this.emptySpaceItem1.Location = new System.Drawing.Point(102, 128);
|
||||
this.emptySpaceItem1.MinSize = new System.Drawing.Size(104, 24);
|
||||
this.emptySpaceItem1.Name = "emptySpaceItem1";
|
||||
this.emptySpaceItem1.Size = new System.Drawing.Size(593, 26);
|
||||
this.emptySpaceItem1.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.emptySpaceItem1.TextSize = new System.Drawing.Size(0, 0);
|
||||
//
|
||||
// layoutControlItem9
|
||||
//
|
||||
this.layoutControlItem9.Control = this.mnView;
|
||||
this.layoutControlItem9.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem9.Name = "layoutControlItem9";
|
||||
this.layoutControlItem9.Size = new System.Drawing.Size(786, 128);
|
||||
this.layoutControlItem9.Text = "Module Number List";
|
||||
this.layoutControlItem9.TextLocation = DevExpress.Utils.Locations.Top;
|
||||
this.layoutControlItem9.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem9.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem12
|
||||
//
|
||||
this.layoutControlItem12.Control = this.btnRefresh;
|
||||
this.layoutControlItem12.Location = new System.Drawing.Point(0, 128);
|
||||
this.layoutControlItem12.Name = "layoutControlItem12";
|
||||
this.layoutControlItem12.Size = new System.Drawing.Size(102, 26);
|
||||
this.layoutControlItem12.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem12.TextVisible = false;
|
||||
//
|
||||
// tmrDisplay
|
||||
//
|
||||
this.tmrDisplay.Tick += new System.EventHandler(this.tmrDisplay_Tick);
|
||||
//
|
||||
// fmxInventoryConfig2
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(798, 538);
|
||||
this.Controls.Add(this.layoutControl1);
|
||||
this.IconOptions.Image = ((System.Drawing.Image)(resources.GetObject("fmxInventoryConfig2.IconOptions.Image")));
|
||||
this.Name = "fmxInventoryConfig2";
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
|
||||
this.Text = "Module Number Config";
|
||||
this.Load += new System.EventHandler(this.fmxInventoryConfig2_Load);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).EndInit();
|
||||
this.layoutControl1.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.mnView)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.groupControl2)).EndInit();
|
||||
this.groupControl2.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl4)).EndInit();
|
||||
this.layoutControl4.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup3)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.groupControl1)).EndInit();
|
||||
this.groupControl1.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl3)).EndInit();
|
||||
this.layoutControl3.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup2)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.gbSerialNo)).EndInit();
|
||||
this.gbSerialNo.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl2)).EndInit();
|
||||
this.layoutControl2.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.nMdNo.Properties)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.Root)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem10)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.gbDvResult)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem11)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.emptySpaceItem1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem12)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl1;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup Root;
|
||||
private DevExpress.XtraEditors.GroupControl gbSerialNo;
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl2;
|
||||
private DevExpress.XtraEditors.TextEdit nMdNo;
|
||||
private DevExpress.XtraEditors.LabelControl lbMdSerial;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup1;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem3;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem4;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem1;
|
||||
private DevExpress.XtraEditors.SimpleButton btnClose;
|
||||
private DevExpress.XtraEditors.SimpleButton btnInvWrite;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem5;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem2;
|
||||
private DevExpress.XtraLayout.EmptySpaceItem emptySpaceItem1;
|
||||
private System.Windows.Forms.Timer tmrDisplay;
|
||||
private System.Windows.Forms.Timer tmrCmd;
|
||||
private DevExpress.XtraEditors.GroupControl groupControl1;
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl3;
|
||||
private DevExpress.XtraEditors.LabelControl lbPcbSerial;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup2;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem6;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem8;
|
||||
private DevExpress.XtraEditors.GroupControl groupControl2;
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl4;
|
||||
private DevExpress.XtraEditors.LabelControl lbResult;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup3;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem7;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem10;
|
||||
private DevExpress.XtraEditors.SimpleButton btnExportExcel;
|
||||
private System.Windows.Forms.DataGridView mnView;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup gbDvResult;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem11;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem9;
|
||||
private DevExpress.XtraEditors.SimpleButton btnRefresh;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem12;
|
||||
}
|
||||
}
|
||||
406
LFP_Manager_PRM/Forms/fmxInventoryConfig2.cs
Normal file
406
LFP_Manager_PRM/Forms/fmxInventoryConfig2.cs
Normal file
@@ -0,0 +1,406 @@
|
||||
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;
|
||||
|
||||
using LFP_Manager.DataStructure;
|
||||
using LFP_Manager.Function;
|
||||
using LFP_Manager.Controls;
|
||||
using LFP_Manager.Utils;
|
||||
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
public partial class fmxInventoryConfig2 : DevExpress.XtraEditors.XtraForm
|
||||
{
|
||||
#region VARIABLES
|
||||
|
||||
private bool fBarCode = false;
|
||||
private bool ctrlKey = false;
|
||||
|
||||
private CommConfig Config;
|
||||
private int SystemId = 0;
|
||||
private int CmdResult = 0;
|
||||
private int CellDivUnit = 0;
|
||||
private DeviceSystemData SystemData;
|
||||
private DeviceInforation wInvDate;
|
||||
|
||||
private string oldMdSn;
|
||||
|
||||
public event InvDataUpdateEvent OnUpdate = null;
|
||||
public event InvDateCmdEvent OnCommand = null;
|
||||
|
||||
#endregion
|
||||
|
||||
#region CONSTRUCTORS
|
||||
public fmxInventoryConfig2()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
public fmxInventoryConfig2(CommConfig aConfig, int sId, ref DeviceSystemData aSystemData, int aCellDivUnit)
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
oldMdSn = "";
|
||||
Config = aConfig;
|
||||
SystemId = sId;
|
||||
SystemData = aSystemData;
|
||||
SystemData.mNo = SystemId;
|
||||
|
||||
CellDivUnit = aCellDivUnit;
|
||||
|
||||
tmrDisplay.Enabled = true;
|
||||
tmrCmd.Enabled = true;
|
||||
|
||||
KeyPreview = true;
|
||||
KeyDown += new KeyEventHandler(teBarCode_KeyDown);
|
||||
KeyPress += new KeyPressEventHandler(teBarCode_KeyPress);
|
||||
}
|
||||
#endregion
|
||||
|
||||
void InitData()
|
||||
{
|
||||
wInvDate = new DeviceInforation
|
||||
{
|
||||
module_sn = new byte[32]
|
||||
};
|
||||
}
|
||||
|
||||
#region TIMER ENVENT
|
||||
|
||||
private void tmrDisplay_Tick(object sender, EventArgs e)
|
||||
{
|
||||
DisplayValue();
|
||||
OnUpdate?.Invoke(this);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region PUBLIC FUCTIONS
|
||||
public void UpdateData(ref DeviceSystemData aSystemData)
|
||||
{
|
||||
SystemData = aSystemData;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region PROCESSING DATA
|
||||
|
||||
private bool CheckMdSerialNo(string mSN)
|
||||
{
|
||||
bool result = false;
|
||||
|
||||
csDbUtils.MdDbCreate(Config, mSN);
|
||||
|
||||
DataTable dtMdData = new DataTable();
|
||||
DataTable dtMdMatch = new DataTable();
|
||||
DataTable dtErrorLog = new DataTable();
|
||||
|
||||
//string sql = String.Format("SELECT * FROM TInventoryData WHERE pcb_sn = {0}", bSN);
|
||||
string sql = String.Format("SELECT * FROM TInventoryData");
|
||||
dtMdData = csDbUtils.GetDataTableBySelect(Config, mSN, sql, "TInventoryData");
|
||||
|
||||
if (dtMdData != null)
|
||||
{
|
||||
if (dtMdData.Rows.Count > 1)
|
||||
{
|
||||
DataRow[] arrRows = null;
|
||||
arrRows = dtMdData.Select(String.Format("module_sn = '{0}'", mSN));
|
||||
if (arrRows.Length > 0) { result = true; }
|
||||
}
|
||||
}
|
||||
return result;
|
||||
}
|
||||
private void CmdMDateWrite()
|
||||
{
|
||||
UInt32 mTimeStamp = csUtils.CalcKKTimeStamp(DateTime.Now);
|
||||
wInvDate.ManufactureDate = mTimeStamp;
|
||||
|
||||
OnCommand?.Invoke(SystemId, 999, 1, ref wInvDate);
|
||||
}
|
||||
|
||||
private void CheckResult()
|
||||
{
|
||||
byte[] a = Encoding.UTF8.GetBytes(nMdNo.Text);
|
||||
byte[] b = SystemData.Information.pcb_sn;
|
||||
|
||||
try
|
||||
{
|
||||
csDbUtils.MdLogDataInsert(ref Config, nMdNo.Text, ref SystemData, DateTime.Now, CellDivUnit);
|
||||
csDbUtils.MdSnDataInsert(Config, SystemData, nMdNo.Text);
|
||||
|
||||
oldMdSn = nMdNo.Text;
|
||||
|
||||
//MessageBox.Show(String.Format("Module data insert complete - [{0}]", nMdNo.Text)
|
||||
// , "Information"
|
||||
// , MessageBoxButtons.OK
|
||||
// , MessageBoxIcon.Information
|
||||
// );
|
||||
lbResult.Text = String.Format("PASS: {0}", String.Format("Module data insert complete - [{0}]", nMdNo.Text));
|
||||
lbResult.ForeColor = Color.Blue;
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
throw new Exception(String.Format("Module data insert fail - [{0}] \r\n{1}", nMdNo.Text, ex.Message));
|
||||
//MessageBox.Show(String.Format("Module data insert fail - [{0}] \r\n{1}", nMdNo.Text, ex.Message)
|
||||
// , "Warning"
|
||||
// , MessageBoxButtons.OK
|
||||
// , MessageBoxIcon.Warning
|
||||
// );
|
||||
}
|
||||
}
|
||||
|
||||
private bool SelectModuleSN(string mSN)
|
||||
{
|
||||
bool result = false;
|
||||
|
||||
//string sql = String.Format("SELECT * FROM TInventoryData WHERE pcb_sn = {0}", bSN);
|
||||
string sql = String.Format("SELECT * FROM TModuleValue");
|
||||
DataTable dtMdData = csDbUtils.GetDataTableBySelect(Config, mSN, sql, "TModuleValue");
|
||||
|
||||
if (dtMdData != null)
|
||||
{
|
||||
if (dtMdData.Rows.Count > 0)
|
||||
{
|
||||
mnView.DataSource = dtMdData;
|
||||
//DataRow[] arrRows = null;
|
||||
//arrRows = dtMdData.Select(String.Format("module_sn = '{0}'", mSN));
|
||||
//if (arrRows.Length > 0) { result = true; }
|
||||
}
|
||||
gbDvResult.Text = string.Format("Module Number List ({0})", dtMdData.Rows.Count);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region BUTTON EVENT
|
||||
|
||||
private void btnInvWrite_Click(object sender, EventArgs e)
|
||||
{
|
||||
string result = "";
|
||||
try
|
||||
{
|
||||
if (nMdNo.Text.Length == 24)
|
||||
{
|
||||
csDbUtils.MdDbCreate(Config, nMdNo.Text);
|
||||
if ((SystemData.Information.pcb_sn == null) || (SystemData.Information.pcb_sn == null) || (SystemData.Information.pcb_sn[0] == 0))
|
||||
{
|
||||
result = "No BMS Serial Number - Please check CAN communication";
|
||||
return;
|
||||
}
|
||||
|
||||
if (CheckMdSerialNo(nMdNo.Text) == false)
|
||||
{
|
||||
CheckResult();
|
||||
|
||||
//byte[] mSN = Encoding.UTF8.GetBytes(nMdNo.Text);
|
||||
|
||||
//if (wInvDate.module_sn == null) wInvDate.module_sn = new byte[32];
|
||||
//for (int i = 0; i < wInvDate.module_sn.Length; i++)
|
||||
//{
|
||||
// wInvDate.module_sn[i] = 0;
|
||||
//}
|
||||
//for (int i = 0; i < mSN.Length; i++)
|
||||
//{
|
||||
// wInvDate.module_sn[i] = mSN[i];
|
||||
//}
|
||||
//CmdMDateWrite();
|
||||
|
||||
//CmdResult = 1;
|
||||
}
|
||||
else
|
||||
{
|
||||
result = "Already used Module serial number";
|
||||
}
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
result = ex.Message;
|
||||
}
|
||||
finally
|
||||
{
|
||||
if (result != "")
|
||||
{
|
||||
//_ = MessageBox.Show(string.Format("{0} - [{1}]", result, nMdNo.Text)
|
||||
// , "Warning"
|
||||
// , MessageBoxButtons.OK
|
||||
// , MessageBoxIcon.Warning
|
||||
// );
|
||||
lbResult.Text = String.Format("Fail: {0}", result);
|
||||
lbResult.ForeColor = Color.Red;
|
||||
|
||||
csLog.SystemErrorLog(Config, result, DateTime.Now, Application.ExecutablePath);
|
||||
}
|
||||
oldMdSn = nMdNo.Text;
|
||||
nMdNo.Text = "";
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region DISPLAY DATA
|
||||
|
||||
private void DisplayValue()
|
||||
{
|
||||
// Device PCB S/N
|
||||
byte[] tmpPcbNo = new byte[SystemData.Information.pcb_sn.Length + 1];
|
||||
for (int i = 0; i < SystemData.Information.pcb_sn.Length; i++)
|
||||
{
|
||||
tmpPcbNo[i] = SystemData.Information.pcb_sn[i];
|
||||
}
|
||||
tmpPcbNo[SystemData.Information.pcb_sn.Length] = 0;
|
||||
|
||||
string strPcbSerial = Encoding.Default.GetString(tmpPcbNo).Trim('\0');
|
||||
lbPcbSerial.Text = String.Format("BMS S/N: {0}", strPcbSerial);
|
||||
|
||||
// Device Module S/N
|
||||
byte[] tmpMdNo = new byte[SystemData.Information.module_sn.Length + 1];
|
||||
for (int i = 0; i < SystemData.Information.module_sn.Length; i++)
|
||||
{
|
||||
tmpMdNo[i] = SystemData.Information.module_sn[i];
|
||||
}
|
||||
tmpMdNo[SystemData.Information.module_sn.Length] = 0;
|
||||
|
||||
string strMdSerial = Encoding.Default.GetString(tmpMdNo).Trim('\0');
|
||||
lbMdSerial.Text = String.Format("Module S/N: {0}", strMdSerial);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region GLOBAL KEYBOARD HOOK
|
||||
private void fmxInventoryConfig2_Load(object sender, EventArgs e)
|
||||
{
|
||||
}
|
||||
|
||||
private void teBarCode_KeyPress(object sender, KeyPressEventArgs e)
|
||||
{
|
||||
if (fBarCode == false)
|
||||
{
|
||||
if (e.KeyChar == 0x0D)
|
||||
{
|
||||
fBarCode = true;
|
||||
|
||||
btnInvWrite_Click(sender, e);
|
||||
//checkBarCode1(nMdNo.Text);
|
||||
}
|
||||
else if (e.KeyChar == 22)
|
||||
{
|
||||
//ctrlKey = true;
|
||||
IDataObject ido = Clipboard.GetDataObject();
|
||||
if (ido.GetDataPresent(typeof(string)))
|
||||
{
|
||||
nMdNo.Text = (string)ido.GetData(typeof(string));
|
||||
}
|
||||
}
|
||||
else if (e.KeyChar > 0x20)
|
||||
{
|
||||
if (e.KeyChar == 'v')
|
||||
{
|
||||
if (ctrlKey)
|
||||
{
|
||||
IDataObject ido = Clipboard.GetDataObject();
|
||||
if (ido.GetDataPresent(typeof(string)))
|
||||
{
|
||||
nMdNo.Text = (string)ido.GetData(typeof(string));
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
nMdNo.Text += e.KeyChar;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void teBarCode_KeyDown(object sender, KeyEventArgs e)
|
||||
{
|
||||
if (fBarCode)
|
||||
{
|
||||
nMdNo.Text = "";
|
||||
fBarCode = false;
|
||||
}
|
||||
}
|
||||
|
||||
public void checkBarCode1(string code)
|
||||
{
|
||||
if (CheckMdSerialNo(code))
|
||||
{
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
//if (dt.Rows.Count > 0)
|
||||
//{
|
||||
// DataRow aRow = dt.Rows[0];
|
||||
|
||||
// MakeCellInformation(aRow);
|
||||
// MakeCellAssyNo(aRow);
|
||||
//}
|
||||
//else
|
||||
//{
|
||||
// MakeBarCodeForm("The data could" + Environment.NewLine + "not be found." + Environment.NewLine + "(无数据)", 1);
|
||||
//}
|
||||
}
|
||||
|
||||
private void MakeBarCodeForm(string result, int flag)
|
||||
{
|
||||
lbResult.Text = result;
|
||||
switch (flag)
|
||||
{
|
||||
case 0:
|
||||
lbResult.ForeColor = Color.Blue;
|
||||
break;
|
||||
case 1:
|
||||
lbResult.ForeColor = Color.Red;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region BUTTON EVENT
|
||||
|
||||
private void btnClose_Click(object sender, EventArgs e)
|
||||
{
|
||||
Close();
|
||||
}
|
||||
|
||||
private void btnRefresh_Click(object sender, EventArgs e)
|
||||
{
|
||||
try
|
||||
{
|
||||
string lotNo;
|
||||
if (oldMdSn == "")
|
||||
{
|
||||
lotNo = "01PPBCNA013006CAW0000019";
|
||||
}
|
||||
else
|
||||
{
|
||||
lotNo = oldMdSn;
|
||||
}
|
||||
SelectModuleSN(lotNo);
|
||||
mnView.AutoResizeColumns();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
MessageBox.Show(ex.Message, "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning);
|
||||
}
|
||||
}
|
||||
|
||||
private void btnExportExcel_Click(object sender, EventArgs e)
|
||||
{
|
||||
//
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
154
LFP_Manager_PRM/Forms/fmxInventoryConfig2.resx
Normal file
154
LFP_Manager_PRM/Forms/fmxInventoryConfig2.resx
Normal file
@@ -0,0 +1,154 @@
|
||||
<?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="tmrDisplay.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
<metadata name="tmrCmd.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>128, 17</value>
|
||||
</metadata>
|
||||
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
|
||||
<data name="fmxInventoryConfig2.IconOptions.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAAAlwSFlzAAAO
|
||||
wwAADsMBx2+oZAAABMxJREFUWEflVWtsFVUQPrdtSvilMRIVY8T4h1/aoDGKqIWCIBXR+IgaAmriD/CR
|
||||
SIyVYjSSPmhLrVVTBa6tQNGIBSqYCEEera34KCqFEmgLNa34qPRaeqHv23G+2Z3tXrp3u/iHGCeZnN09
|
||||
M2e++WbOrKFLLP8dACMjI87qp2oTVAIBcB8Y8zncvRcUxEUxoIdGon3UdbbX0TPdvdR9vl/23HZBZFwA
|
||||
euDQcEzedze00aSF79Ckx9+nKx8rc3Tyo2V0+GSn2AyzbVAgvgD0gFgsRsOsfQNDNPXZCjLpq8nc9xaZ
|
||||
ucWW4vmuPJqZ9Rm8xDZIcEggBjT7VR8fJHNnLiUveNsKOr/EUn5Ovp+/MYhNe5vEFj5BWEgIQJ1BJ5qr
|
||||
5dcITcwsoZBmzIFDeBcA9jq7iK554gOK9PQJC8KEfVYiGbcEmv0Db1aTuTufkjKt7CXgvWu4BKw2C0lg
|
||||
YUYevbTugPgM2iz4iScAzX5waFjePz/YSmZWgUWzBuJSLF+7nx7J3SlB5Rv2GMwEXrUhxyvFGABqiMaD
|
||||
87neAbrxqTCF5hRx9hbVoTlr6CrufDRly+kIpc4rpiQO6oCbWUDpWVvsJPxZGAsAyg5KffZHdXGNJ+s9
|
||||
+bRhz1HZh7xa8bU0oGMDEPxeufeY7PuxEAdAjfQeH2/vsrJj9coOB6PRengITVmyXpjRxgzZDfk3Dy3Y
|
||||
gFGN4RbPEgAAZP7r26zGc+rL2fEt+Kn1TweA9smWmuNim8pDCgxgxfsKZgeiLFwoDgBs6qGQ7fUtdtcn
|
||||
6HAOjMxgj17AikFk0t7gkuWRmZ5L5o4cMrfnUE1jB9uOMusGIgD0g0w8NoqeH6Api9eTySi06LQpvW7R
|
||||
Ojp7rl8Cs5P4uAX/hWwGmF1RJ5mv3FBHr5Tto+pvWmXfi4U4BpTOrPLa+KuFldn4lGmGACSGTUPzH7Tn
|
||||
0C9UsfsIlWxtoPCXjfTF96dox7etcnWhO787SZ981UT1TactXwbvZsHoi9JztO0vuceotwTH4OGun51d
|
||||
JVmrHcB2MxsdnT104HA7vcYZX79orVUCph2ApRQzuBTTc+jyh96l385ExzQkA7AecDAkY0UVB1w9mj0r
|
||||
bsKRtk4ZyQrAS/C9fFcjXc1/RsNzI3VhKaXwORMetBpycfEusXOXgksw2nib9x3j+5vvTDy511wK3HMI
|
||||
slZHrKrICnua2YmOCE19+kOrh7SJsc4qpP0/t4uNgjB4wAGo6bVPMoUZRaONx1ncsCRMUZ6GsIFCFARE
|
||||
QejzwOCQPDfzz+syvopJ87SUDCC9gG5etpFt+AZxXAA2vf2Ww3LuXtTMoR4OXPtt9c2yr9m7g7tF9uy1
|
||||
3wZRWv3j2Gbm95Lth2Qf11duQeOpTmm8FM4agVMWlErN5q7cKoZe18dL1AaZwQd609KNMj1RTpydzP10
|
||||
xcPv0e9dUbbjEuBeT3u+0upcrhmMETyFJ96Jjq64xgsKAmqBJqrlISQ3gumXs3memNtWUSZPWYjJCtdS
|
||||
2nObaNoLlQLk1hc3Uxo3UGHVD2Lg1/V+Ah/tmZfDNZT2TLmcjRi3sCLmDvzmUYdEguw1+MWAcPv4+aH/
|
||||
nFGMYKryzvVR8TskkaiPnuUVA+JMQi+F6Ppv5MLzvNT5F1wq+b8DIPoHjJf5qaq9hPwAAAAASUVORK5C
|
||||
YII=
|
||||
</value>
|
||||
</data>
|
||||
</root>
|
||||
696
LFP_Manager_PRM/Forms/fmxMain.Designer.cs
generated
Normal file
696
LFP_Manager_PRM/Forms/fmxMain.Designer.cs
generated
Normal file
@@ -0,0 +1,696 @@
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
partial class fmxMain
|
||||
{
|
||||
/// <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.components = new System.ComponentModel.Container();
|
||||
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(fmxMain));
|
||||
this.menuStrip1 = new System.Windows.Forms.MenuStrip();
|
||||
this.fileToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.exitToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.configToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.commConfigToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.updateToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.firmwareUpdateCANToolStripMenuItem1 = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.firmwareImageConveterToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.historyToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.historyViewToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.databaseToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.checkDBToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.layoutControl1 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.edMaxModule = new DevExpress.XtraEditors.TextEdit();
|
||||
this.btnPrevID = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.ModuleIdSet = new LFP_Manager.Controls.ucModuleIdSet();
|
||||
this.btnNextID = new DevExpress.XtraEditors.SimpleButton();
|
||||
this.ucCommConfig = new LFP_Manager.Controls.ucCommConfig2();
|
||||
this.chbPolling = new DevExpress.XtraEditors.CheckEdit();
|
||||
this.edSystemId = new DevExpress.XtraEditors.TextEdit();
|
||||
this.statusStrip1 = new System.Windows.Forms.StatusStrip();
|
||||
this.CommStausBar = new System.Windows.Forms.ToolStripStatusLabel();
|
||||
this.HeatBeatStatusBar = new System.Windows.Forms.ToolStripStatusLabel();
|
||||
this.LogStatusBar = new System.Windows.Forms.ToolStripStatusLabel();
|
||||
this.uDataLog = new LFP_Manager.Controls.ucDataLog();
|
||||
this.uEventLog = new LFP_Manager.Controls.ucEventLog();
|
||||
this.tabStatus = new DevExpress.XtraTab.XtraTabControl();
|
||||
this.pgSystem = new DevExpress.XtraTab.XtraTabPage();
|
||||
this.layoutControl2 = new DevExpress.XtraLayout.LayoutControl();
|
||||
this.ucSystem = new LFP_Manager.Controls.ucShelfStatus();
|
||||
this.layoutControlGroup2 = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem3 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlMain = new DevExpress.XtraLayout.LayoutControlGroup();
|
||||
this.layoutControlItem2 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem6 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem7 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem8 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.lcitemSystemId = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem16 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem1 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem4 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem5 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem9 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.layoutControlItem10 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.tmrCheckThreadMsg = new System.Windows.Forms.Timer(this.components);
|
||||
this.tmrTest = new System.Windows.Forms.Timer(this.components);
|
||||
this.chkDcp = new DevExpress.XtraEditors.CheckEdit();
|
||||
this.layoutControlItem11 = new DevExpress.XtraLayout.LayoutControlItem();
|
||||
this.menuStrip1.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).BeginInit();
|
||||
this.layoutControl1.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.edMaxModule.Properties)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.chbPolling.Properties)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.edSystemId.Properties)).BeginInit();
|
||||
this.statusStrip1.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.tabStatus)).BeginInit();
|
||||
this.tabStatus.SuspendLayout();
|
||||
this.pgSystem.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl2)).BeginInit();
|
||||
this.layoutControl2.SuspendLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup2)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlMain)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.lcitemSystemId)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem16)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem10)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.chkDcp.Properties)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem11)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// menuStrip1
|
||||
//
|
||||
this.menuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
||||
this.fileToolStripMenuItem,
|
||||
this.configToolStripMenuItem,
|
||||
this.updateToolStripMenuItem,
|
||||
this.historyToolStripMenuItem,
|
||||
this.databaseToolStripMenuItem});
|
||||
this.menuStrip1.Location = new System.Drawing.Point(0, 0);
|
||||
this.menuStrip1.Name = "menuStrip1";
|
||||
this.menuStrip1.Size = new System.Drawing.Size(1334, 24);
|
||||
this.menuStrip1.TabIndex = 0;
|
||||
this.menuStrip1.Text = "menuStrip1";
|
||||
//
|
||||
// fileToolStripMenuItem
|
||||
//
|
||||
this.fileToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
||||
this.exitToolStripMenuItem});
|
||||
this.fileToolStripMenuItem.Name = "fileToolStripMenuItem";
|
||||
this.fileToolStripMenuItem.Size = new System.Drawing.Size(37, 20);
|
||||
this.fileToolStripMenuItem.Text = "File";
|
||||
//
|
||||
// exitToolStripMenuItem
|
||||
//
|
||||
this.exitToolStripMenuItem.Name = "exitToolStripMenuItem";
|
||||
this.exitToolStripMenuItem.Size = new System.Drawing.Size(93, 22);
|
||||
this.exitToolStripMenuItem.Text = "Exit";
|
||||
this.exitToolStripMenuItem.Click += new System.EventHandler(this.exitToolStripMenuItem_Click);
|
||||
//
|
||||
// configToolStripMenuItem
|
||||
//
|
||||
this.configToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
||||
this.commConfigToolStripMenuItem});
|
||||
this.configToolStripMenuItem.Name = "configToolStripMenuItem";
|
||||
this.configToolStripMenuItem.Size = new System.Drawing.Size(55, 20);
|
||||
this.configToolStripMenuItem.Text = "Config";
|
||||
//
|
||||
// commConfigToolStripMenuItem
|
||||
//
|
||||
this.commConfigToolStripMenuItem.Name = "commConfigToolStripMenuItem";
|
||||
this.commConfigToolStripMenuItem.Size = new System.Drawing.Size(150, 22);
|
||||
this.commConfigToolStripMenuItem.Text = "Comm.Config";
|
||||
this.commConfigToolStripMenuItem.Click += new System.EventHandler(this.commConfigToolStripMenuItem_Click);
|
||||
//
|
||||
// updateToolStripMenuItem
|
||||
//
|
||||
this.updateToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
||||
this.firmwareUpdateCANToolStripMenuItem1,
|
||||
this.firmwareImageConveterToolStripMenuItem});
|
||||
this.updateToolStripMenuItem.Name = "updateToolStripMenuItem";
|
||||
this.updateToolStripMenuItem.Size = new System.Drawing.Size(57, 20);
|
||||
this.updateToolStripMenuItem.Text = "Update";
|
||||
//
|
||||
// firmwareUpdateCANToolStripMenuItem1
|
||||
//
|
||||
this.firmwareUpdateCANToolStripMenuItem1.Name = "firmwareUpdateCANToolStripMenuItem1";
|
||||
this.firmwareUpdateCANToolStripMenuItem1.Size = new System.Drawing.Size(212, 22);
|
||||
this.firmwareUpdateCANToolStripMenuItem1.Text = "Firmware Update (CAN)";
|
||||
this.firmwareUpdateCANToolStripMenuItem1.Click += new System.EventHandler(this.firmwareUpdateCANToolStripMenuItem_Click);
|
||||
//
|
||||
// firmwareImageConveterToolStripMenuItem
|
||||
//
|
||||
this.firmwareImageConveterToolStripMenuItem.Name = "firmwareImageConveterToolStripMenuItem";
|
||||
this.firmwareImageConveterToolStripMenuItem.Size = new System.Drawing.Size(212, 22);
|
||||
this.firmwareImageConveterToolStripMenuItem.Text = "Firmware Image Conveter";
|
||||
this.firmwareImageConveterToolStripMenuItem.Click += new System.EventHandler(this.firmwareImageConveterToolStripMenuItem_Click);
|
||||
//
|
||||
// historyToolStripMenuItem
|
||||
//
|
||||
this.historyToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
||||
this.historyViewToolStripMenuItem});
|
||||
this.historyToolStripMenuItem.Name = "historyToolStripMenuItem";
|
||||
this.historyToolStripMenuItem.Size = new System.Drawing.Size(57, 20);
|
||||
this.historyToolStripMenuItem.Text = "History";
|
||||
//
|
||||
// historyViewToolStripMenuItem
|
||||
//
|
||||
this.historyViewToolStripMenuItem.Name = "historyViewToolStripMenuItem";
|
||||
this.historyViewToolStripMenuItem.Size = new System.Drawing.Size(142, 22);
|
||||
this.historyViewToolStripMenuItem.Text = "History View";
|
||||
this.historyViewToolStripMenuItem.Click += new System.EventHandler(this.historyViewToolStripMenuItem_Click);
|
||||
//
|
||||
// databaseToolStripMenuItem
|
||||
//
|
||||
this.databaseToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
||||
this.checkDBToolStripMenuItem});
|
||||
this.databaseToolStripMenuItem.Name = "databaseToolStripMenuItem";
|
||||
this.databaseToolStripMenuItem.Size = new System.Drawing.Size(68, 20);
|
||||
this.databaseToolStripMenuItem.Text = "Database";
|
||||
//
|
||||
// checkDBToolStripMenuItem
|
||||
//
|
||||
this.checkDBToolStripMenuItem.Name = "checkDBToolStripMenuItem";
|
||||
this.checkDBToolStripMenuItem.Size = new System.Drawing.Size(127, 22);
|
||||
this.checkDBToolStripMenuItem.Text = "Check DB";
|
||||
this.checkDBToolStripMenuItem.Click += new System.EventHandler(this.checkDBToolStripMenuItem_Click);
|
||||
//
|
||||
// layoutControl1
|
||||
//
|
||||
this.layoutControl1.Controls.Add(this.chkDcp);
|
||||
this.layoutControl1.Controls.Add(this.edMaxModule);
|
||||
this.layoutControl1.Controls.Add(this.btnPrevID);
|
||||
this.layoutControl1.Controls.Add(this.ModuleIdSet);
|
||||
this.layoutControl1.Controls.Add(this.btnNextID);
|
||||
this.layoutControl1.Controls.Add(this.ucCommConfig);
|
||||
this.layoutControl1.Controls.Add(this.chbPolling);
|
||||
this.layoutControl1.Controls.Add(this.edSystemId);
|
||||
this.layoutControl1.Controls.Add(this.statusStrip1);
|
||||
this.layoutControl1.Controls.Add(this.uDataLog);
|
||||
this.layoutControl1.Controls.Add(this.uEventLog);
|
||||
this.layoutControl1.Controls.Add(this.tabStatus);
|
||||
this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl1.Location = new System.Drawing.Point(0, 24);
|
||||
this.layoutControl1.Name = "layoutControl1";
|
||||
this.layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(305, 211, 613, 350);
|
||||
this.layoutControl1.Root = this.layoutControlMain;
|
||||
this.layoutControl1.Size = new System.Drawing.Size(1334, 744);
|
||||
this.layoutControl1.TabIndex = 1;
|
||||
this.layoutControl1.Text = "layoutControl1";
|
||||
//
|
||||
// edMaxModule
|
||||
//
|
||||
this.edMaxModule.EditValue = "1";
|
||||
this.edMaxModule.Location = new System.Drawing.Point(961, 555);
|
||||
this.edMaxModule.Name = "edMaxModule";
|
||||
this.edMaxModule.Properties.Appearance.Font = new System.Drawing.Font("Tahoma", 10F);
|
||||
this.edMaxModule.Properties.Appearance.Options.UseFont = true;
|
||||
this.edMaxModule.Properties.Appearance.Options.UseTextOptions = true;
|
||||
this.edMaxModule.Properties.Appearance.TextOptions.HAlignment = DevExpress.Utils.HorzAlignment.Far;
|
||||
this.edMaxModule.Size = new System.Drawing.Size(82, 22);
|
||||
this.edMaxModule.StyleController = this.layoutControl1;
|
||||
this.edMaxModule.TabIndex = 10;
|
||||
this.edMaxModule.EditValueChanged += new System.EventHandler(this.edMaxModule_EditValueChanged);
|
||||
//
|
||||
// btnPrevID
|
||||
//
|
||||
this.btnPrevID.Location = new System.Drawing.Point(1213, 555);
|
||||
this.btnPrevID.Name = "btnPrevID";
|
||||
this.btnPrevID.Size = new System.Drawing.Size(57, 22);
|
||||
this.btnPrevID.StyleController = this.layoutControl1;
|
||||
this.btnPrevID.TabIndex = 9;
|
||||
this.btnPrevID.Text = "Prev";
|
||||
this.btnPrevID.Click += new System.EventHandler(this.btnPrevID_Click);
|
||||
//
|
||||
// ModuleIdSet
|
||||
//
|
||||
this.ModuleIdSet.Location = new System.Drawing.Point(823, 581);
|
||||
this.ModuleIdSet.Name = "ModuleIdSet";
|
||||
this.ModuleIdSet.Size = new System.Drawing.Size(220, 136);
|
||||
this.ModuleIdSet.TabIndex = 8;
|
||||
//
|
||||
// btnNextID
|
||||
//
|
||||
this.btnNextID.Location = new System.Drawing.Point(1274, 555);
|
||||
this.btnNextID.Name = "btnNextID";
|
||||
this.btnNextID.Size = new System.Drawing.Size(57, 22);
|
||||
this.btnNextID.StyleController = this.layoutControl1;
|
||||
this.btnNextID.TabIndex = 7;
|
||||
this.btnNextID.Text = "Next";
|
||||
this.btnNextID.Click += new System.EventHandler(this.btnNextID_Click);
|
||||
//
|
||||
// ucCommConfig
|
||||
//
|
||||
this.ucCommConfig.Location = new System.Drawing.Point(1213, 605);
|
||||
this.ucCommConfig.Name = "ucCommConfig";
|
||||
this.ucCommConfig.Size = new System.Drawing.Size(118, 112);
|
||||
this.ucCommConfig.TabIndex = 6;
|
||||
//
|
||||
// chbPolling
|
||||
//
|
||||
this.chbPolling.Location = new System.Drawing.Point(1140, 555);
|
||||
this.chbPolling.Name = "chbPolling";
|
||||
this.chbPolling.Properties.Caption = "Polling";
|
||||
this.chbPolling.Size = new System.Drawing.Size(69, 20);
|
||||
this.chbPolling.StyleController = this.layoutControl1;
|
||||
this.chbPolling.TabIndex = 4;
|
||||
this.chbPolling.CheckedChanged += new System.EventHandler(this.chbPolling_CheckedChanged);
|
||||
//
|
||||
// edSystemId
|
||||
//
|
||||
this.edSystemId.EditValue = "1";
|
||||
this.edSystemId.Location = new System.Drawing.Point(1082, 555);
|
||||
this.edSystemId.Name = "edSystemId";
|
||||
this.edSystemId.Properties.Appearance.Font = new System.Drawing.Font("Tahoma", 10F);
|
||||
this.edSystemId.Properties.Appearance.Options.UseFont = true;
|
||||
this.edSystemId.Properties.Appearance.Options.UseTextOptions = true;
|
||||
this.edSystemId.Properties.Appearance.TextOptions.HAlignment = DevExpress.Utils.HorzAlignment.Far;
|
||||
this.edSystemId.Size = new System.Drawing.Size(54, 22);
|
||||
this.edSystemId.StyleController = this.layoutControl1;
|
||||
this.edSystemId.TabIndex = 3;
|
||||
this.edSystemId.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.edSystemId_KeyPress);
|
||||
//
|
||||
// statusStrip1
|
||||
//
|
||||
this.statusStrip1.AutoSize = false;
|
||||
this.statusStrip1.Dock = System.Windows.Forms.DockStyle.None;
|
||||
this.statusStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
||||
this.CommStausBar,
|
||||
this.HeatBeatStatusBar,
|
||||
this.LogStatusBar});
|
||||
this.statusStrip1.Location = new System.Drawing.Point(3, 721);
|
||||
this.statusStrip1.Name = "statusStrip1";
|
||||
this.statusStrip1.Size = new System.Drawing.Size(1328, 20);
|
||||
this.statusStrip1.TabIndex = 1;
|
||||
this.statusStrip1.Text = "statusStrip1";
|
||||
//
|
||||
// CommStausBar
|
||||
//
|
||||
this.CommStausBar.AutoSize = false;
|
||||
this.CommStausBar.ForeColor = System.Drawing.Color.Black;
|
||||
this.CommStausBar.Name = "CommStausBar";
|
||||
this.CommStausBar.Size = new System.Drawing.Size(200, 15);
|
||||
this.CommStausBar.Text = "Comm: OFF";
|
||||
this.CommStausBar.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
|
||||
//
|
||||
// HeatBeatStatusBar
|
||||
//
|
||||
this.HeatBeatStatusBar.AutoSize = false;
|
||||
this.HeatBeatStatusBar.ForeColor = System.Drawing.Color.Black;
|
||||
this.HeatBeatStatusBar.Name = "HeatBeatStatusBar";
|
||||
this.HeatBeatStatusBar.Size = new System.Drawing.Size(200, 15);
|
||||
this.HeatBeatStatusBar.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
|
||||
//
|
||||
// LogStatusBar
|
||||
//
|
||||
this.LogStatusBar.AutoSize = false;
|
||||
this.LogStatusBar.Name = "LogStatusBar";
|
||||
this.LogStatusBar.Size = new System.Drawing.Size(650, 15);
|
||||
this.LogStatusBar.Text = "Log Stop";
|
||||
this.LogStatusBar.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
|
||||
//
|
||||
// uDataLog
|
||||
//
|
||||
this.uDataLog.Location = new System.Drawing.Point(1047, 581);
|
||||
this.uDataLog.Name = "uDataLog";
|
||||
this.uDataLog.Size = new System.Drawing.Size(162, 136);
|
||||
this.uDataLog.TabIndex = 5;
|
||||
//
|
||||
// uEventLog
|
||||
//
|
||||
this.uEventLog.Location = new System.Drawing.Point(3, 555);
|
||||
this.uEventLog.Name = "uEventLog";
|
||||
this.uEventLog.Size = new System.Drawing.Size(816, 162);
|
||||
this.uEventLog.TabIndex = 2;
|
||||
//
|
||||
// tabStatus
|
||||
//
|
||||
this.tabStatus.Location = new System.Drawing.Point(3, 3);
|
||||
this.tabStatus.Name = "tabStatus";
|
||||
this.tabStatus.SelectedTabPage = this.pgSystem;
|
||||
this.tabStatus.Size = new System.Drawing.Size(1328, 548);
|
||||
this.tabStatus.TabIndex = 0;
|
||||
this.tabStatus.TabPages.AddRange(new DevExpress.XtraTab.XtraTabPage[] {
|
||||
this.pgSystem});
|
||||
//
|
||||
// pgSystem
|
||||
//
|
||||
this.pgSystem.Controls.Add(this.layoutControl2);
|
||||
this.pgSystem.Name = "pgSystem";
|
||||
this.pgSystem.Size = new System.Drawing.Size(1326, 522);
|
||||
this.pgSystem.Text = "SYSTEM";
|
||||
//
|
||||
// layoutControl2
|
||||
//
|
||||
this.layoutControl2.Controls.Add(this.ucSystem);
|
||||
this.layoutControl2.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.layoutControl2.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControl2.Name = "layoutControl2";
|
||||
this.layoutControl2.Root = this.layoutControlGroup2;
|
||||
this.layoutControl2.Size = new System.Drawing.Size(1326, 522);
|
||||
this.layoutControl2.TabIndex = 0;
|
||||
this.layoutControl2.Text = "layoutControl2";
|
||||
//
|
||||
// ucSystem
|
||||
//
|
||||
this.ucSystem.Location = new System.Drawing.Point(3, 3);
|
||||
this.ucSystem.Name = "ucSystem";
|
||||
this.ucSystem.Size = new System.Drawing.Size(1320, 516);
|
||||
this.ucSystem.TabIndex = 4;
|
||||
//
|
||||
// layoutControlGroup2
|
||||
//
|
||||
this.layoutControlGroup2.CustomizationFormText = "layoutControlGroup2";
|
||||
this.layoutControlGroup2.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.layoutControlGroup2.GroupBordersVisible = false;
|
||||
this.layoutControlGroup2.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem3});
|
||||
this.layoutControlGroup2.Name = "layoutControlGroup2";
|
||||
this.layoutControlGroup2.Padding = new DevExpress.XtraLayout.Utils.Padding(1, 1, 1, 1);
|
||||
this.layoutControlGroup2.Size = new System.Drawing.Size(1326, 522);
|
||||
this.layoutControlGroup2.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem3
|
||||
//
|
||||
this.layoutControlItem3.Control = this.ucSystem;
|
||||
this.layoutControlItem3.CustomizationFormText = "layoutControlItem3";
|
||||
this.layoutControlItem3.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem3.Name = "layoutControlItem3";
|
||||
this.layoutControlItem3.Size = new System.Drawing.Size(1324, 520);
|
||||
this.layoutControlItem3.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem3.TextVisible = false;
|
||||
//
|
||||
// layoutControlMain
|
||||
//
|
||||
this.layoutControlMain.CustomizationFormText = "layoutControlGroup1";
|
||||
this.layoutControlMain.EnableIndentsWithoutBorders = DevExpress.Utils.DefaultBoolean.True;
|
||||
this.layoutControlMain.GroupBordersVisible = false;
|
||||
this.layoutControlMain.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
|
||||
this.layoutControlItem2,
|
||||
this.layoutControlItem6,
|
||||
this.layoutControlItem7,
|
||||
this.layoutControlItem8,
|
||||
this.lcitemSystemId,
|
||||
this.layoutControlItem16,
|
||||
this.layoutControlItem1,
|
||||
this.layoutControlItem4,
|
||||
this.layoutControlItem5,
|
||||
this.layoutControlItem9,
|
||||
this.layoutControlItem10,
|
||||
this.layoutControlItem11});
|
||||
this.layoutControlMain.Name = "Root";
|
||||
this.layoutControlMain.Padding = new DevExpress.XtraLayout.Utils.Padding(1, 1, 1, 1);
|
||||
this.layoutControlMain.Size = new System.Drawing.Size(1334, 744);
|
||||
this.layoutControlMain.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem2
|
||||
//
|
||||
this.layoutControlItem2.Control = this.tabStatus;
|
||||
this.layoutControlItem2.CustomizationFormText = "layoutControlItem2";
|
||||
this.layoutControlItem2.Location = new System.Drawing.Point(0, 0);
|
||||
this.layoutControlItem2.Name = "layoutControlItem2";
|
||||
this.layoutControlItem2.Size = new System.Drawing.Size(1332, 552);
|
||||
this.layoutControlItem2.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem2.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem6
|
||||
//
|
||||
this.layoutControlItem6.Control = this.uEventLog;
|
||||
this.layoutControlItem6.CustomizationFormText = "layoutControlItem6";
|
||||
this.layoutControlItem6.Location = new System.Drawing.Point(0, 552);
|
||||
this.layoutControlItem6.MaxSize = new System.Drawing.Size(0, 166);
|
||||
this.layoutControlItem6.MinSize = new System.Drawing.Size(209, 166);
|
||||
this.layoutControlItem6.Name = "layoutControlItem6";
|
||||
this.layoutControlItem6.Size = new System.Drawing.Size(820, 166);
|
||||
this.layoutControlItem6.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem6.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem6.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem7
|
||||
//
|
||||
this.layoutControlItem7.Control = this.uDataLog;
|
||||
this.layoutControlItem7.CustomizationFormText = "layoutControlItem7";
|
||||
this.layoutControlItem7.Location = new System.Drawing.Point(1044, 578);
|
||||
this.layoutControlItem7.MaxSize = new System.Drawing.Size(166, 0);
|
||||
this.layoutControlItem7.MinSize = new System.Drawing.Size(166, 24);
|
||||
this.layoutControlItem7.Name = "layoutControlItem7";
|
||||
this.layoutControlItem7.Size = new System.Drawing.Size(166, 140);
|
||||
this.layoutControlItem7.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem7.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem7.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem8
|
||||
//
|
||||
this.layoutControlItem8.Control = this.statusStrip1;
|
||||
this.layoutControlItem8.CustomizationFormText = "layoutControlItem8";
|
||||
this.layoutControlItem8.Location = new System.Drawing.Point(0, 718);
|
||||
this.layoutControlItem8.MaxSize = new System.Drawing.Size(0, 24);
|
||||
this.layoutControlItem8.MinSize = new System.Drawing.Size(104, 24);
|
||||
this.layoutControlItem8.Name = "layoutControlItem8";
|
||||
this.layoutControlItem8.Size = new System.Drawing.Size(1332, 24);
|
||||
this.layoutControlItem8.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem8.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem8.TextVisible = false;
|
||||
//
|
||||
// lcitemSystemId
|
||||
//
|
||||
this.lcitemSystemId.Control = this.edSystemId;
|
||||
this.lcitemSystemId.CustomizationFormText = "System Id";
|
||||
this.lcitemSystemId.Location = new System.Drawing.Point(1044, 552);
|
||||
this.lcitemSystemId.MinSize = new System.Drawing.Size(57, 26);
|
||||
this.lcitemSystemId.Name = "lcitemSystemId";
|
||||
this.lcitemSystemId.Size = new System.Drawing.Size(93, 26);
|
||||
this.lcitemSystemId.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.lcitemSystemId.Text = " ID ";
|
||||
this.lcitemSystemId.TextAlignMode = DevExpress.XtraLayout.TextAlignModeItem.CustomSize;
|
||||
this.lcitemSystemId.TextSize = new System.Drawing.Size(30, 14);
|
||||
this.lcitemSystemId.TextToControlDistance = 5;
|
||||
//
|
||||
// layoutControlItem16
|
||||
//
|
||||
this.layoutControlItem16.Control = this.chbPolling;
|
||||
this.layoutControlItem16.CustomizationFormText = "layoutControlItem16";
|
||||
this.layoutControlItem16.Location = new System.Drawing.Point(1137, 552);
|
||||
this.layoutControlItem16.Name = "layoutControlItem16";
|
||||
this.layoutControlItem16.Size = new System.Drawing.Size(73, 26);
|
||||
this.layoutControlItem16.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem16.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem1
|
||||
//
|
||||
this.layoutControlItem1.Control = this.ucCommConfig;
|
||||
this.layoutControlItem1.CustomizationFormText = "layoutControlItem1";
|
||||
this.layoutControlItem1.Location = new System.Drawing.Point(1210, 602);
|
||||
this.layoutControlItem1.MaxSize = new System.Drawing.Size(122, 0);
|
||||
this.layoutControlItem1.MinSize = new System.Drawing.Size(122, 50);
|
||||
this.layoutControlItem1.Name = "layoutControlItem1";
|
||||
this.layoutControlItem1.Size = new System.Drawing.Size(122, 116);
|
||||
this.layoutControlItem1.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem1.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem1.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem4
|
||||
//
|
||||
this.layoutControlItem4.Control = this.btnNextID;
|
||||
this.layoutControlItem4.Location = new System.Drawing.Point(1271, 552);
|
||||
this.layoutControlItem4.MinSize = new System.Drawing.Size(60, 26);
|
||||
this.layoutControlItem4.Name = "layoutControlItem4";
|
||||
this.layoutControlItem4.Size = new System.Drawing.Size(61, 26);
|
||||
this.layoutControlItem4.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem4.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem4.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem5
|
||||
//
|
||||
this.layoutControlItem5.Control = this.ModuleIdSet;
|
||||
this.layoutControlItem5.Location = new System.Drawing.Point(820, 578);
|
||||
this.layoutControlItem5.MaxSize = new System.Drawing.Size(224, 0);
|
||||
this.layoutControlItem5.MinSize = new System.Drawing.Size(224, 140);
|
||||
this.layoutControlItem5.Name = "layoutControlItem5";
|
||||
this.layoutControlItem5.Size = new System.Drawing.Size(224, 140);
|
||||
this.layoutControlItem5.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem5.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem5.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem9
|
||||
//
|
||||
this.layoutControlItem9.Control = this.btnPrevID;
|
||||
this.layoutControlItem9.Location = new System.Drawing.Point(1210, 552);
|
||||
this.layoutControlItem9.MinSize = new System.Drawing.Size(40, 26);
|
||||
this.layoutControlItem9.Name = "layoutControlItem9";
|
||||
this.layoutControlItem9.Size = new System.Drawing.Size(61, 26);
|
||||
this.layoutControlItem9.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem9.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem9.TextVisible = false;
|
||||
//
|
||||
// layoutControlItem10
|
||||
//
|
||||
this.layoutControlItem10.Control = this.edMaxModule;
|
||||
this.layoutControlItem10.Location = new System.Drawing.Point(820, 552);
|
||||
this.layoutControlItem10.MinSize = new System.Drawing.Size(121, 26);
|
||||
this.layoutControlItem10.Name = "layoutControlItem10";
|
||||
this.layoutControlItem10.Size = new System.Drawing.Size(224, 26);
|
||||
this.layoutControlItem10.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
|
||||
this.layoutControlItem10.Text = " Max Module per String";
|
||||
this.layoutControlItem10.TextSize = new System.Drawing.Size(126, 14);
|
||||
//
|
||||
// tmrCheckThreadMsg
|
||||
//
|
||||
this.tmrCheckThreadMsg.Tick += new System.EventHandler(this.tmrCheckThreadMsg_Tick);
|
||||
//
|
||||
// tmrTest
|
||||
//
|
||||
this.tmrTest.Enabled = true;
|
||||
this.tmrTest.Interval = 2000;
|
||||
this.tmrTest.Tick += new System.EventHandler(this.tmrTest_Tick);
|
||||
//
|
||||
// chkDcp
|
||||
//
|
||||
this.chkDcp.Location = new System.Drawing.Point(1213, 581);
|
||||
this.chkDcp.Name = "chkDcp";
|
||||
this.chkDcp.Properties.Caption = " DCP";
|
||||
this.chkDcp.Size = new System.Drawing.Size(118, 20);
|
||||
this.chkDcp.StyleController = this.layoutControl1;
|
||||
this.chkDcp.TabIndex = 11;
|
||||
this.chkDcp.CheckedChanged += new System.EventHandler(this.chkDcp_CheckedChanged);
|
||||
//
|
||||
// layoutControlItem11
|
||||
//
|
||||
this.layoutControlItem11.Control = this.chkDcp;
|
||||
this.layoutControlItem11.Location = new System.Drawing.Point(1210, 578);
|
||||
this.layoutControlItem11.Name = "layoutControlItem11";
|
||||
this.layoutControlItem11.Size = new System.Drawing.Size(122, 24);
|
||||
this.layoutControlItem11.TextSize = new System.Drawing.Size(0, 0);
|
||||
this.layoutControlItem11.TextVisible = false;
|
||||
//
|
||||
// fmxMain
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 14F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(1334, 768);
|
||||
this.Controls.Add(this.layoutControl1);
|
||||
this.Controls.Add(this.menuStrip1);
|
||||
this.IconOptions.Icon = ((System.Drawing.Icon)(resources.GetObject("fmxMain.IconOptions.Icon")));
|
||||
this.MainMenuStrip = this.menuStrip1;
|
||||
this.Name = "fmxMain";
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
|
||||
this.Text = "LFP SYSTEM";
|
||||
this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.fmxMain_FormClosing);
|
||||
this.Load += new System.EventHandler(this.fmxMain_Load);
|
||||
this.menuStrip1.ResumeLayout(false);
|
||||
this.menuStrip1.PerformLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl1)).EndInit();
|
||||
this.layoutControl1.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.edMaxModule.Properties)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.chbPolling.Properties)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.edSystemId.Properties)).EndInit();
|
||||
this.statusStrip1.ResumeLayout(false);
|
||||
this.statusStrip1.PerformLayout();
|
||||
((System.ComponentModel.ISupportInitialize)(this.tabStatus)).EndInit();
|
||||
this.tabStatus.ResumeLayout(false);
|
||||
this.pgSystem.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControl2)).EndInit();
|
||||
this.layoutControl2.ResumeLayout(false);
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlGroup2)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem3)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlMain)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem6)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem8)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.lcitemSystemId)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem16)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem4)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem5)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem9)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem10)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.chkDcp.Properties)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem11)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.MenuStrip menuStrip1;
|
||||
private System.Windows.Forms.ToolStripMenuItem fileToolStripMenuItem;
|
||||
private System.Windows.Forms.ToolStripMenuItem configToolStripMenuItem;
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl1;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlMain;
|
||||
private System.Windows.Forms.ToolStripMenuItem commConfigToolStripMenuItem;
|
||||
private DevExpress.XtraTab.XtraTabControl tabStatus;
|
||||
private DevExpress.XtraTab.XtraTabPage pgSystem;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem2;
|
||||
private DevExpress.XtraLayout.LayoutControl layoutControl2;
|
||||
private DevExpress.XtraLayout.LayoutControlGroup layoutControlGroup2;
|
||||
private Controls.ucShelfStatus ucSystem;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem3;
|
||||
private Controls.ucEventLog uEventLog;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem6;
|
||||
private System.Windows.Forms.Timer tmrCheckThreadMsg;
|
||||
private Controls.ucDataLog uDataLog;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem7;
|
||||
private System.Windows.Forms.StatusStrip statusStrip1;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem8;
|
||||
private System.Windows.Forms.ToolStripMenuItem exitToolStripMenuItem;
|
||||
private System.Windows.Forms.ToolStripStatusLabel CommStausBar;
|
||||
private System.Windows.Forms.ToolStripStatusLabel LogStatusBar;
|
||||
private System.Windows.Forms.ToolStripStatusLabel HeatBeatStatusBar;
|
||||
private DevExpress.XtraEditors.TextEdit edSystemId;
|
||||
private DevExpress.XtraLayout.LayoutControlItem lcitemSystemId;
|
||||
private DevExpress.XtraEditors.CheckEdit chbPolling;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem16;
|
||||
private System.Windows.Forms.ToolStripMenuItem updateToolStripMenuItem;
|
||||
private System.Windows.Forms.ToolStripMenuItem firmwareUpdateCANToolStripMenuItem1;
|
||||
private System.Windows.Forms.ToolStripMenuItem firmwareImageConveterToolStripMenuItem;
|
||||
private Controls.ucCommConfig2 ucCommConfig;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem1;
|
||||
private System.Windows.Forms.Timer tmrTest;
|
||||
private System.Windows.Forms.ToolStripMenuItem databaseToolStripMenuItem;
|
||||
private System.Windows.Forms.ToolStripMenuItem checkDBToolStripMenuItem;
|
||||
private System.Windows.Forms.ToolStripMenuItem historyToolStripMenuItem;
|
||||
private System.Windows.Forms.ToolStripMenuItem historyViewToolStripMenuItem;
|
||||
private DevExpress.XtraEditors.SimpleButton btnNextID;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem4;
|
||||
private Controls.ucModuleIdSet ModuleIdSet;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem5;
|
||||
private DevExpress.XtraEditors.SimpleButton btnPrevID;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem9;
|
||||
private DevExpress.XtraEditors.TextEdit edMaxModule;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem10;
|
||||
private DevExpress.XtraEditors.CheckEdit chkDcp;
|
||||
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem11;
|
||||
}
|
||||
}
|
||||
836
LFP_Manager_PRM/Forms/fmxMain.cs
Normal file
836
LFP_Manager_PRM/Forms/fmxMain.cs
Normal file
@@ -0,0 +1,836 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Text;
|
||||
using System.Linq;
|
||||
using System.Windows.Forms;
|
||||
using DevExpress.XtraEditors;
|
||||
|
||||
using LFP_Manager.Forms;
|
||||
using LFP_Manager.Controls;
|
||||
using LFP_Manager.DataStructure;
|
||||
using LFP_Manager.Function;
|
||||
using LFP_Manager.Threads;
|
||||
using LFP_Manager.Utils;
|
||||
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
public partial class fmxMain : DevExpress.XtraEditors.XtraForm
|
||||
{
|
||||
#region VARIABLES
|
||||
|
||||
private fmxFwUpdate FwUpdateForm = null;
|
||||
private fmxExcelFile DbControlFrom = null;
|
||||
|
||||
private CommConfig Config;
|
||||
private DeviceSystemData SystemData;
|
||||
|
||||
private csCanThread canThread = null;
|
||||
private csValueCanThread ValueCanThread = null;
|
||||
|
||||
private csDbThread dbThread = null;
|
||||
|
||||
private ucShelfStatus SystemStatus;
|
||||
|
||||
private bool Active = false;
|
||||
|
||||
#endregion
|
||||
|
||||
#region CONSTRUCTORS
|
||||
|
||||
public fmxMain()
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
ComponentInit();
|
||||
|
||||
StructDataInit();
|
||||
|
||||
IniLoad();
|
||||
|
||||
DataInit();
|
||||
|
||||
ucCommConfig.OnStart += StartButtonClick;
|
||||
|
||||
uDataLog.OnUpdate += LogStatusUpdate;
|
||||
|
||||
edSystemId.Enabled = false;
|
||||
|
||||
SystemStatus.OnCommand += SetCmdToCan;
|
||||
SystemStatus.OnMsgPrint += TestLogMessage;
|
||||
SystemStatus.Start(0, ref Config, ref SystemData);
|
||||
edSystemId.Enabled = true;
|
||||
|
||||
ModuleIdSet.OnCommand += SetCmdToCan;
|
||||
|
||||
//this.Text = String.Format("LFP SYSTEM [{0}] -- PR-LFP MODULE", Application.ProductVersion);
|
||||
this.Text = String.Format("LFP SYSTEM [{0}] -- PR-LFP MODULE - [{1}]"
|
||||
, Application.ProductVersion
|
||||
, csConstData.CommType.CAN_MODEL[Config.TargetModelIndex]
|
||||
);
|
||||
|
||||
tmrCheckThreadMsg.Start();
|
||||
}
|
||||
|
||||
private void ComponentInit()
|
||||
{
|
||||
SystemStatus = ucSystem;
|
||||
}
|
||||
|
||||
private void IniLoad()
|
||||
{
|
||||
Config = csIniControlFunction.IniLoad(Application.ExecutablePath, Config);
|
||||
ucCommConfig.UpdateConfig(ref Config);
|
||||
TypeChangedUpdate(ref Config);
|
||||
}
|
||||
|
||||
private void StructDataInit()
|
||||
{
|
||||
SystemData = new DeviceSystemData();
|
||||
Config = new CommConfig();
|
||||
}
|
||||
|
||||
private void DataInit()
|
||||
{
|
||||
DataFunction.DataInit(ref SystemData, ref Config);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region BUTTON EVENT
|
||||
|
||||
private void ConfigButtonClick(object sender, EventArgs e)
|
||||
{
|
||||
foreach (Form frm in Application.OpenForms)
|
||||
{
|
||||
if (frm.Name == "fmxCommConfig")
|
||||
{
|
||||
frm.Activate();
|
||||
return;
|
||||
}
|
||||
}
|
||||
fmxCommConfig CommConfigForm = new fmxCommConfig();
|
||||
CommConfigForm.Owner = this;
|
||||
|
||||
CommConfigForm.OnUpdate += UpdateConfig;
|
||||
CommConfigForm.Show();
|
||||
}
|
||||
|
||||
private void StopProcess()
|
||||
{
|
||||
if (canThread != null)
|
||||
{
|
||||
canThread.disposeThread();
|
||||
canThread = null;
|
||||
}
|
||||
|
||||
if (ValueCanThread != null)
|
||||
{
|
||||
ValueCanThread.disposeThread();
|
||||
ValueCanThread = null;
|
||||
}
|
||||
|
||||
if (dbThread != null)
|
||||
{
|
||||
dbThread.Stop();
|
||||
dbThread.disposeThread();
|
||||
dbThread = null;
|
||||
}
|
||||
|
||||
Active = false;
|
||||
|
||||
edSystemId.Enabled = true;
|
||||
chbPolling.Enabled = true;
|
||||
|
||||
DataInit();
|
||||
UpdateData(this, ref SystemData);
|
||||
}
|
||||
|
||||
private void StartProcessCAN()
|
||||
{
|
||||
// CAN MODE
|
||||
int sId = 0;
|
||||
|
||||
if (edSystemId.Text != null)
|
||||
sId = Convert.ToInt16(edSystemId.Text);
|
||||
|
||||
ucSystem.SystemIdSet(sId);
|
||||
|
||||
canThread = new csCanThread(sId, Config, ref SystemData);
|
||||
canThread.OnUpdate += UpdateData;
|
||||
canThread.OnDataRecv += CanRecvData;
|
||||
canThread.OnPrint += PrintLogMessage;
|
||||
|
||||
if (canThread.Start(ref Config, sId, chbPolling.Checked))
|
||||
{
|
||||
Active = true;
|
||||
edSystemId.Enabled = false;
|
||||
chbPolling.Enabled = true;
|
||||
|
||||
if (chbPolling.Checked)
|
||||
edSystemId.Enabled = false;
|
||||
else
|
||||
edSystemId.Enabled = true;
|
||||
|
||||
canThread.SetPolling(chbPolling.Checked, Convert.ToInt32(edSystemId.Text), ref SystemData);
|
||||
SystemStatus.UpdateSystemId(Convert.ToInt32(edSystemId.Text));
|
||||
|
||||
dbThread = new csDbThread(ref Config, ref SystemData);
|
||||
dbThread.Start(Config);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (canThread != null)
|
||||
{
|
||||
canThread.disposeThread();
|
||||
canThread = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void StartProcessValueCAN()
|
||||
{
|
||||
int sId = 0;
|
||||
|
||||
if (edSystemId.Text != null)
|
||||
sId = Convert.ToInt16(edSystemId.Text);
|
||||
|
||||
ucSystem.SystemIdSet(sId);
|
||||
|
||||
ValueCanThread = new csValueCanThread(sId, Config, ref SystemData);
|
||||
ValueCanThread.OnUpdate += UpdateData;
|
||||
ValueCanThread.OnDataRecv += CanRecvData;
|
||||
ValueCanThread.OnPrint += PrintLogMessage;
|
||||
|
||||
if (ValueCanThread.Start(Config, sId, chbPolling.Checked))
|
||||
{
|
||||
Active = true;
|
||||
edSystemId.Enabled = false;
|
||||
chbPolling.Enabled = true;
|
||||
|
||||
if (chbPolling.Checked)
|
||||
edSystemId.Enabled = false;
|
||||
else
|
||||
edSystemId.Enabled = true;
|
||||
|
||||
ValueCanThread.SetPolling(chbPolling.Checked, Convert.ToInt32(edSystemId.Text), ref SystemData);
|
||||
SystemStatus.UpdateSystemId(Convert.ToInt32(edSystemId.Text));
|
||||
|
||||
dbThread = new csDbThread(ref Config, ref SystemData);
|
||||
dbThread.Start(Config);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (ValueCanThread != null)
|
||||
{
|
||||
ValueCanThread.disposeThread();
|
||||
ValueCanThread = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void StartButtonClick(object sender, EventArgs e)
|
||||
{
|
||||
if (Active)
|
||||
{
|
||||
StopProcess();
|
||||
}
|
||||
else
|
||||
{
|
||||
switch (Config.CommType)
|
||||
{
|
||||
case csConstData.CommType.COMM_USBCAN:
|
||||
switch (csCanConstData.CanDeviceInfo.DeviceIds[Config.CanDevice])
|
||||
{
|
||||
case csCanConstData.CanDeviceInfo.VCI_VALUE_CAN4_1: // CAN MODE - ValueCAN
|
||||
try
|
||||
{
|
||||
StartProcessValueCAN();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
|
||||
if (ValueCanThread != null)
|
||||
{
|
||||
ValueCanThread.disposeThread();
|
||||
ValueCanThread = null;
|
||||
}
|
||||
}
|
||||
break;
|
||||
default: // CAN MODE - USBCAN
|
||||
try
|
||||
{
|
||||
StartProcessCAN();
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
MessageBox.Show(ex.Message, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
|
||||
if (canThread != null)
|
||||
{
|
||||
canThread.disposeThread();
|
||||
canThread = null;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (canThread != null)
|
||||
{
|
||||
// USBCAN
|
||||
ucCommConfig.UpdateStatus(Active, canThread.GetCommSystemId());
|
||||
}
|
||||
else if (ValueCanThread != null)
|
||||
{
|
||||
// Value CAN
|
||||
ucCommConfig.UpdateStatus(Active, ValueCanThread.GetCommSystemId());
|
||||
}
|
||||
else
|
||||
{ ucCommConfig.UpdateStatus(Active, 0); }
|
||||
|
||||
uDataLog.UpdateActiveStatus(Active, Config, ref SystemData);
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region UPDATE FUNCTIONS
|
||||
|
||||
private void UpdateCommConfigStatus()
|
||||
{
|
||||
if (canThread != null)
|
||||
{
|
||||
// USBCAN
|
||||
ucCommConfig.UpdateStatus(Active, canThread.GetCommSystemId());
|
||||
}
|
||||
else if (ValueCanThread != null)
|
||||
{
|
||||
// Value CAN
|
||||
ucCommConfig.UpdateStatus(Active, ValueCanThread.GetCommSystemId());
|
||||
}
|
||||
else
|
||||
{
|
||||
ucCommConfig.UpdateStatus(Active, 0);
|
||||
}
|
||||
}
|
||||
|
||||
private void TypeChangedUpdate(ref CommConfig aConfig)
|
||||
{
|
||||
this.Text = String.Format("LFP SYSTEM [{0}] -- PR-LFP MODULE - [{1}]"
|
||||
, Application.ProductVersion
|
||||
, csConstData.CommType.CAN_MODEL[aConfig.TargetModelIndex]
|
||||
);
|
||||
|
||||
switch (Config.TargetModelIndex)
|
||||
{
|
||||
case 0: // PR-57150
|
||||
edMaxModule.Text = "18";
|
||||
break;
|
||||
case 1: // PR-64150
|
||||
edMaxModule.Text = "3";
|
||||
break;
|
||||
case 2: // LFPM-57080
|
||||
edMaxModule.Text = "18";
|
||||
break;
|
||||
case 3: // PR-102150
|
||||
edMaxModule.Text = "11";
|
||||
break;
|
||||
case 4: // PR-115300
|
||||
edMaxModule.Text = "10";
|
||||
break;
|
||||
case 5: // PR-67150
|
||||
edMaxModule.Text = "3";
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
DataInit();
|
||||
|
||||
switch (aConfig.CommType)
|
||||
{
|
||||
case csConstData.CommType.COMM_USBCAN:
|
||||
SystemStatus.Start(0, ref Config, ref SystemData);
|
||||
edSystemId.Enabled = true;
|
||||
break;
|
||||
case csConstData.CommType.COMM_UARTCAN:
|
||||
SystemStatus.Start(0, ref Config, ref SystemData);
|
||||
edSystemId.Enabled = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
private void UpdateData(object sender, ref DeviceSystemData rData)
|
||||
{
|
||||
//SystemData = rData;
|
||||
|
||||
//if (SystemStatus != null)
|
||||
// SystemStatus.UpdateData(ref SystemData);
|
||||
//if (uDataLog != null)
|
||||
// uDataLog.UpdateData(ref SystemData);
|
||||
//if (dbThread != null)
|
||||
// dbThread.UpdateData(ref SystemData);
|
||||
|
||||
if (edSystemId.Text != string.Empty)
|
||||
ModuleIdSet.UpdateData(Convert.ToInt32(edSystemId.Text), SystemData.CalibriationData);
|
||||
}
|
||||
|
||||
private void CanRecvData(UInt32 hdr, byte[] data)
|
||||
{
|
||||
if (FwUpdateForm != null)
|
||||
{
|
||||
if (this.InvokeRequired)
|
||||
{
|
||||
this.Invoke(new MethodInvoker(delegate()
|
||||
{
|
||||
FwUpdateForm.RecvData(hdr, data);
|
||||
}));
|
||||
}
|
||||
else
|
||||
{
|
||||
FwUpdateForm.RecvData(hdr, data);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void UpdateConfig(object aConfig)
|
||||
{
|
||||
Config = (CommConfig)aConfig;
|
||||
|
||||
IniLoad();
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region MENU EVENT
|
||||
|
||||
private void commConfigToolStripMenuItem_Click(object sender, EventArgs e)
|
||||
{
|
||||
ConfigButtonClick(sender, e);
|
||||
}
|
||||
|
||||
private void exitToolStripMenuItem_Click(object sender, EventArgs e)
|
||||
{
|
||||
Close();
|
||||
}
|
||||
|
||||
private void testSendToolStripMenuItem_Click(object sender, EventArgs e)
|
||||
{
|
||||
csHistoryFunction.DbCreate(System.IO.Path.GetDirectoryName(Application.ExecutablePath));
|
||||
}
|
||||
|
||||
private void firmwareUpdateCANToolStripMenuItem_Click(object sender, EventArgs e)
|
||||
{
|
||||
foreach (Form frm in Application.OpenForms)
|
||||
{
|
||||
if (frm.Name == "fmxFwUpdate")
|
||||
{
|
||||
frm.Activate();
|
||||
return;
|
||||
}
|
||||
}
|
||||
FwUpdateForm = new fmxFwUpdate(Convert.ToUInt32(edSystemId.Text), Config);
|
||||
|
||||
FwUpdateForm.OnAutoTxCanSet += SetAutoTxCan;
|
||||
FwUpdateForm.OnSendDataCan += SendDataToCan;
|
||||
FwUpdateForm.Show();
|
||||
}
|
||||
|
||||
private void firmwareImageConveterToolStripMenuItem_Click(object sender, EventArgs e)
|
||||
{
|
||||
foreach (Form frm in Application.OpenForms)
|
||||
{
|
||||
if (frm.Name == "fmxFwImageConverter")
|
||||
{
|
||||
frm.Activate();
|
||||
return;
|
||||
}
|
||||
}
|
||||
fmxFwImageConverter FwImageConverter = new fmxFwImageConverter();
|
||||
|
||||
FwImageConverter.Show();
|
||||
}
|
||||
|
||||
private void historyViewToolStripMenuItem_Click(object sender, EventArgs e)
|
||||
{
|
||||
foreach (Form frm in Application.OpenForms)
|
||||
{
|
||||
if (frm.Name == "fmxHistory")
|
||||
{
|
||||
frm.Activate();
|
||||
return;
|
||||
}
|
||||
}
|
||||
fmxHistory HistoryForm = new fmxHistory(Config);
|
||||
|
||||
HistoryForm.Show();
|
||||
}
|
||||
|
||||
private void checkDBToolStripMenuItem_Click(object sender, EventArgs e)
|
||||
{
|
||||
foreach (Form frm in Application.OpenForms)
|
||||
{
|
||||
if (frm.Name == "fmxExcelFile")
|
||||
{
|
||||
frm.Activate();
|
||||
return;
|
||||
}
|
||||
}
|
||||
DbControlFrom = new fmxExcelFile(Config);
|
||||
|
||||
DbControlFrom.Show();
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region FORM EVENT
|
||||
|
||||
private void fmxMain_Load(object sender, EventArgs e)
|
||||
{
|
||||
}
|
||||
|
||||
private void fmxMain_FormClosing(object sender, FormClosingEventArgs e)
|
||||
{
|
||||
if (canThread != null)
|
||||
{
|
||||
canThread.disposeThread();
|
||||
canThread = null;
|
||||
}
|
||||
|
||||
if (ValueCanThread != null)
|
||||
{
|
||||
ValueCanThread.disposeThread();
|
||||
ValueCanThread = null;
|
||||
}
|
||||
|
||||
if (dbThread != null)
|
||||
{
|
||||
dbThread.disposeThread();
|
||||
dbThread = null;
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region TIMER EVENT
|
||||
|
||||
private void tmrCheckThreadMsg_Tick(object sender, EventArgs e)
|
||||
{
|
||||
UpdateCommConfigStatus();
|
||||
|
||||
//if (snmpThread != null)
|
||||
//{
|
||||
// string data = snmpThread.GetResult();
|
||||
|
||||
// if (data != "")
|
||||
// {
|
||||
// uEventLog.EventUpdate(data + "\r\n");
|
||||
// }
|
||||
//}
|
||||
|
||||
//if (uartThread != null)
|
||||
//{
|
||||
// string data = uartThread.GetMsg();
|
||||
|
||||
// if (data != "")
|
||||
// {
|
||||
// uEventLog.EventUpdate(data + "\r\n");
|
||||
// }
|
||||
//}
|
||||
|
||||
//if (canThread != null)
|
||||
//{
|
||||
// string data = canThread.GetMsg();
|
||||
|
||||
// if (data != "")
|
||||
// {
|
||||
// uEventLog.EventUpdate(data + "\r\n");
|
||||
// }
|
||||
//}
|
||||
|
||||
//if (dbThread != null)
|
||||
//{
|
||||
// string data = dbThread.GetMsg();
|
||||
|
||||
// if (data != "")
|
||||
// {
|
||||
// uEventLog.EventUpdate(data + "\r\n");
|
||||
// }
|
||||
//}
|
||||
byte[] sn = new byte[17];
|
||||
|
||||
switch (Config.CommType)
|
||||
{
|
||||
case csConstData.CommType.COMM_SNMP:
|
||||
// SNMP MODE
|
||||
break;
|
||||
case csConstData.CommType.COMM_UARTCAN:
|
||||
// UARTCAN MODE
|
||||
for (int i = 0; i < 16; i++)
|
||||
sn[i] = SystemData.Information.pcb_sn[i];
|
||||
sn[16] = 0;
|
||||
if (sn[0] == 0xFF) sn[0] = 0;
|
||||
pgSystem.Text = String.Format("{0} [{1}.{2}.{3}.{4}] - {5}", "LFP SYSTEM"
|
||||
, SystemData.ValueData.fw_ver[0]
|
||||
, SystemData.ValueData.fw_ver[1]
|
||||
, SystemData.ValueData.fw_ver[2]
|
||||
, SystemData.ValueData.fw_ver[3]
|
||||
, Encoding.Default.GetString(sn)
|
||||
);
|
||||
break;
|
||||
case csConstData.CommType.COMM_USBCAN:
|
||||
// USBCAN MODE
|
||||
for (int i = 0; i < 16; i++)
|
||||
sn[i] = SystemData.Information.pcb_sn[i];
|
||||
sn[16] = 0;
|
||||
if (sn[0] == 0xFF) sn[0] = 0;
|
||||
pgSystem.Text = String.Format("{0} [{1}.{2}.{3}.{4}] - {5}", "LFP SYSTEM"
|
||||
, SystemData.ValueData.fw_ver[0]
|
||||
, SystemData.ValueData.fw_ver[1]
|
||||
, SystemData.ValueData.fw_ver[2]
|
||||
, SystemData.ValueData.fw_ver[3]
|
||||
, Encoding.Default.GetString(sn)
|
||||
);
|
||||
break;
|
||||
}
|
||||
DisplayCommStaus();
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region STATUS BAR EVENT
|
||||
|
||||
void DisplayCommStaus()
|
||||
{
|
||||
if (Active == true)
|
||||
CommStausBar.Text = "Comm: On";
|
||||
else
|
||||
CommStausBar.Text = "Comm: Off";
|
||||
}
|
||||
|
||||
void LogStatusUpdate(object sender, string msg, bool active, int aLogTime)
|
||||
{
|
||||
LogStatusBar.Text = msg;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region LOG PRINT FUCTION
|
||||
|
||||
private void PrintLogMessage(object sender, string msg)
|
||||
{
|
||||
if (this.InvokeRequired)
|
||||
{
|
||||
this.Invoke(new MethodInvoker(delegate ()
|
||||
{
|
||||
uEventLog.EventUpdate(msg + "\r\n");
|
||||
}));
|
||||
}
|
||||
else
|
||||
{
|
||||
uEventLog.EventUpdate(msg + "\r\n");
|
||||
}
|
||||
}
|
||||
|
||||
private void TestLogMessage(object sender, string msg)
|
||||
{
|
||||
if (this.InvokeRequired)
|
||||
{
|
||||
this.Invoke(new MethodInvoker(delegate ()
|
||||
{
|
||||
uEventLog.MsgUpdate(msg + "\r\n");
|
||||
}));
|
||||
}
|
||||
else
|
||||
{
|
||||
uEventLog.MsgUpdate(msg + "\r\n");
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region CAN COMMAND AND SET
|
||||
|
||||
private void SetCmdToCan(int sId, int mode, int flag, ref DeviceParamData aParam, ref DeviceCalibration aCalib)
|
||||
{
|
||||
if (canThread != null)
|
||||
{
|
||||
canThread.SendProcessFromApp(sId, mode, flag, 0, ref aParam, ref aCalib);
|
||||
}
|
||||
else if (ValueCanThread != null)
|
||||
{
|
||||
ValueCanThread.SendProcessFromApp(sId, mode, flag, 0, ref aParam, ref aCalib);
|
||||
}
|
||||
}
|
||||
|
||||
private void chbPolling_CheckedChanged(object sender, EventArgs e)
|
||||
{
|
||||
if (edSystemId.Text != string.Empty)
|
||||
{
|
||||
if (canThread != null)
|
||||
{
|
||||
canThread.SetPolling(chbPolling.Checked, Convert.ToInt32(edSystemId.Text), ref SystemData);
|
||||
}
|
||||
|
||||
if (ValueCanThread != null)
|
||||
{
|
||||
ValueCanThread.SetPolling(chbPolling.Checked, Convert.ToInt32(edSystemId.Text), ref SystemData);
|
||||
}
|
||||
|
||||
SystemStatus.UpdateSystemId(Convert.ToInt32(edSystemId.Text));
|
||||
|
||||
if (chbPolling.Checked)
|
||||
edSystemId.Enabled = false;
|
||||
else
|
||||
edSystemId.Enabled = true;
|
||||
}
|
||||
}
|
||||
|
||||
private void chkDcp_CheckedChanged(object sender, EventArgs e)
|
||||
{
|
||||
if (canThread != null)
|
||||
{
|
||||
if (chkDcp.Checked)
|
||||
canThread.SetDcp(1);
|
||||
else
|
||||
canThread.SetDcp(0);
|
||||
}
|
||||
|
||||
if (ValueCanThread != null)
|
||||
{
|
||||
if (chkDcp.Checked)
|
||||
ValueCanThread.SetDCP(1);
|
||||
else
|
||||
ValueCanThread.SetDCP(0);
|
||||
}
|
||||
}
|
||||
|
||||
private void edSystemId_KeyPress(object sender, KeyPressEventArgs e)
|
||||
{
|
||||
csUtils.TypingOnlyNumber(sender, e, false, false);
|
||||
}
|
||||
|
||||
private void SendDataToCan(UInt32 header, byte[] data)
|
||||
{
|
||||
if (canThread != null)
|
||||
{
|
||||
canThread.SendDataFromApp(header, data, 0);
|
||||
}
|
||||
else if (ValueCanThread != null)
|
||||
{
|
||||
ValueCanThread.SendDataFromApp(header, data);
|
||||
}
|
||||
}
|
||||
|
||||
private void SetAutoTxCan(bool autoTx)
|
||||
{
|
||||
if (canThread != null)
|
||||
{
|
||||
canThread.SetAutoTx(autoTx);
|
||||
}
|
||||
else if (ValueCanThread != null)
|
||||
{
|
||||
ValueCanThread.SetAutoTx(autoTx);
|
||||
}
|
||||
}
|
||||
|
||||
private void tmrTest_Tick(object sender, EventArgs e)
|
||||
{
|
||||
//string data = "";
|
||||
|
||||
//data += String.Format("S[{0}], ", SystemTotalData.AvgData.avgCellVoltage);
|
||||
//data += String.Format("S[{0}], ", SystemTotalData.AvgData.maxCellVoltage);
|
||||
//data += String.Format("S[{0}], ", SystemTotalData.AvgData.minCellVoltage);
|
||||
//data += String.Format("S[{0}], ", SystemTotalData.AvgData.diffCellVoltage);
|
||||
//data += String.Format("S[{0}], ", SystemTotalData.CellBalancingVoltage);
|
||||
//for (int i = 0; i < Config.CanModelIndex + 1; i++)
|
||||
//{
|
||||
// data += String.Format("M-{0:00}[{1}], ", i + 1, SystemData.StatusData.cellBalanceValue);
|
||||
//}
|
||||
|
||||
//if (data != "")
|
||||
//{
|
||||
// uEventLog.EventUpdate(data + "\r\n");
|
||||
//}
|
||||
}
|
||||
|
||||
private void btnNextID_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (edSystemId.Text == "") return;
|
||||
if (edMaxModule.Text == "") return;
|
||||
|
||||
int currID = Convert.ToInt32(edSystemId.Text);
|
||||
int maxModule = Convert.ToInt32(edMaxModule.Text);
|
||||
|
||||
if (currID == maxModule)
|
||||
currID = 1;
|
||||
else
|
||||
currID++;
|
||||
|
||||
edSystemId.Text = currID.ToString();
|
||||
SystemData.mNo = currID;
|
||||
|
||||
if (canThread != null)
|
||||
{
|
||||
DataInit();
|
||||
SystemStatus.UpdateSystemId(Convert.ToInt32(edSystemId.Text));
|
||||
canThread.SetPolling(chbPolling.Checked, Convert.ToInt32(edSystemId.Text), ref SystemData);
|
||||
}
|
||||
else if (ValueCanThread != null)
|
||||
{
|
||||
DataInit();
|
||||
SystemStatus.UpdateSystemId(Convert.ToInt32(edSystemId.Text));
|
||||
ValueCanThread.SetPolling(chbPolling.Checked, Convert.ToInt32(edSystemId.Text), ref SystemData);
|
||||
}
|
||||
}
|
||||
|
||||
private void btnPrevID_Click(object sender, EventArgs e)
|
||||
{
|
||||
if (edSystemId.Text == "") return;
|
||||
if (edMaxModule.Text == "") return;
|
||||
|
||||
int currID = Convert.ToInt32(edSystemId.Text);
|
||||
int maxModule = Convert.ToInt32(edMaxModule.Text);
|
||||
|
||||
if (currID == 1)
|
||||
currID = maxModule;
|
||||
else if (currID > 0)
|
||||
currID--;
|
||||
else
|
||||
currID = 1;
|
||||
|
||||
edSystemId.Text = currID.ToString();
|
||||
SystemData.mNo = currID;
|
||||
|
||||
if (canThread != null)
|
||||
{
|
||||
DataInit();
|
||||
SystemStatus.UpdateSystemId(Convert.ToInt32(edSystemId.Text));
|
||||
canThread.SetPolling(chbPolling.Checked, Convert.ToInt32(edSystemId.Text), ref SystemData);
|
||||
}
|
||||
else if (ValueCanThread != null)
|
||||
{
|
||||
DataInit();
|
||||
SystemStatus.UpdateSystemId(Convert.ToInt32(edSystemId.Text));
|
||||
ValueCanThread.SetPolling(chbPolling.Checked, Convert.ToInt32(edSystemId.Text), ref SystemData);
|
||||
}
|
||||
}
|
||||
|
||||
private void edMaxModule_EditValueChanged(object sender, EventArgs e)
|
||||
{
|
||||
try
|
||||
{
|
||||
int id = Convert.ToInt32(edMaxModule.Text);
|
||||
ModuleIdSet.SetMaxModule(id);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
MessageBox.Show("EditValue change error: " + ex.Message, "Exception", MessageBoxButtons.OK, MessageBoxIcon.Error);
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
4586
LFP_Manager_PRM/Forms/fmxMain.resx
Normal file
4586
LFP_Manager_PRM/Forms/fmxMain.resx
Normal file
File diff suppressed because it is too large
Load Diff
1136
LFP_Manager_PRM/Forms/fmxParamConfig.Designer.cs
generated
Normal file
1136
LFP_Manager_PRM/Forms/fmxParamConfig.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
351
LFP_Manager_PRM/Forms/fmxParamConfig.cs
Normal file
351
LFP_Manager_PRM/Forms/fmxParamConfig.cs
Normal file
@@ -0,0 +1,351 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Text;
|
||||
using System.Linq;
|
||||
using System.Windows.Forms;
|
||||
using DevExpress.XtraEditors;
|
||||
|
||||
using LFP_Manager.DataStructure;
|
||||
using LFP_Manager.Function;
|
||||
using LFP_Manager.Controls;
|
||||
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
public delegate void ParamUpdateEvent(object sendor);
|
||||
public delegate void ParamCmdEvent(int sId, int mode, int flag, ref DeviceParamData aParam, ref DeviceCalibration aCalib);
|
||||
|
||||
public partial class fmxParamConfig : DevExpress.XtraEditors.XtraForm
|
||||
{
|
||||
#region VARIABLES
|
||||
|
||||
int SystemId = 0;
|
||||
DeviceParamData Param;
|
||||
DeviceCalibration Calib;
|
||||
|
||||
public event ParamUpdateEvent OnUpdate = null;
|
||||
public event ParamCmdEvent OnCommand = null;
|
||||
|
||||
#endregion
|
||||
|
||||
#region CONSTRUCTORS
|
||||
|
||||
public fmxParamConfig()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
public fmxParamConfig(int sId, DeviceParamData aParam)
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
SystemId = sId;
|
||||
Param = aParam;
|
||||
|
||||
InitComponent();
|
||||
|
||||
tmrDisplay.Enabled = true;
|
||||
}
|
||||
|
||||
public void InitComponent()
|
||||
{
|
||||
// Cell Voltage Parameter
|
||||
ucCOVParam.SetParamName(0, "Cell Over Voltage");
|
||||
ucCOVParam.SetParamName(1, "mV");
|
||||
ucCOVParam.SetId(0);
|
||||
ucCOVParam.OnCommand += OnCmdEvent;
|
||||
|
||||
ucCUVParam.SetParamName(0, "Cell Under Voltage");
|
||||
ucCUVParam.SetParamName(1, "mV");
|
||||
ucCUVParam.SetId(1);
|
||||
ucCUVParam.OnCommand += OnCmdEvent;
|
||||
//ucCUVParam.EnableItem(0, false);
|
||||
|
||||
// System Voltage Parameter
|
||||
ucSOVParam.SetParamName(0, "System Over Voltage");
|
||||
ucSOVParam.SetParamName(1, "V");
|
||||
ucSOVParam.SetId(2);
|
||||
ucSOVParam.OnCommand += OnCmdEvent;
|
||||
|
||||
ucSUVParam.SetParamName(0, "System Under Voltage");
|
||||
ucSUVParam.SetParamName(1, "V");
|
||||
ucSUVParam.SetId(3);
|
||||
ucSUVParam.OnCommand += OnCmdEvent;
|
||||
//ucSUVParam.EnableItem(0, false);
|
||||
|
||||
// Charge Temperature Parameter
|
||||
ucCHTParam.SetParamName(0, "Charge High Temp");
|
||||
ucCHTParam.SetParamName(1, "C");
|
||||
ucCHTParam.SetId(4);
|
||||
ucCHTParam.OnCommand += OnCmdEvent;
|
||||
|
||||
ucCLTParam.SetParamName(0, "Charge Low Temp");
|
||||
ucCLTParam.SetParamName(1, "C");
|
||||
ucCLTParam.SetId(5);
|
||||
ucCLTParam.OnCommand += OnCmdEvent;
|
||||
|
||||
// Discharge Temperature Parameter
|
||||
ucDHTParam.SetParamName(0, "Discharge High Temp");
|
||||
ucDHTParam.SetParamName(1, "C");
|
||||
ucDHTParam.SetId(6);
|
||||
ucDHTParam.OnCommand += OnCmdEvent;
|
||||
//ucDHTParam.EnableItem(0, false);
|
||||
|
||||
ucDLTParam.SetParamName(0, "Discharge Low Temp");
|
||||
ucDLTParam.SetParamName(1, "C");
|
||||
ucDLTParam.SetId(7);
|
||||
ucDLTParam.OnCommand += OnCmdEvent;
|
||||
//ucDLTParam.EnableItem(0, false);
|
||||
|
||||
// Discharge Temperature Parameter
|
||||
ucCOCParam.SetParamName(0, "Charge Over Current");
|
||||
ucCOCParam.SetParamName(1, "A");
|
||||
ucCOCParam.SetId(8);
|
||||
ucCOCParam.OnCommand += OnCmdEvent;
|
||||
|
||||
ucDOCParam.SetParamName(0, "Discharge Over Current");
|
||||
ucDOCParam.SetParamName(1, "A");
|
||||
ucDOCParam.SetId(9);
|
||||
ucDOCParam.OnCommand += OnCmdEvent;
|
||||
//ucDOCParam.EnableItem(0, false);
|
||||
|
||||
// SOC Parameter
|
||||
ucLowSocParam.SetParamName(0, "Low SOC");
|
||||
ucLowSocParam.SetParamName(1, "%");
|
||||
ucLowSocParam.SetId(10);
|
||||
ucLowSocParam.OnCommand += OnCmdEvent;
|
||||
ucLowSocParam.EnableItem(0, false);
|
||||
|
||||
// SOC Parameter
|
||||
ucCvDiffParam.SetParamName(0, "Cell Voltage Diff");
|
||||
ucCvDiffParam.SetParamName(1, "mV");
|
||||
ucCvDiffParam.SetId(11);
|
||||
ucCvDiffParam.OnCommand += OnCmdEvent;
|
||||
//ucCvDiffParam.EnableItem(0, false);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region COMMAND EVENT
|
||||
|
||||
private void OnCmdEvent(int mode, int flag, ParamData aParam)
|
||||
{
|
||||
int cmd = 0;
|
||||
DeviceParamData wParam = Param;
|
||||
|
||||
switch (mode)
|
||||
{
|
||||
case 0: // Cell Over Voltage
|
||||
cmd = 5;
|
||||
wParam.CellOverVoltageTrip = aParam.Fault;
|
||||
wParam.CellOverVoltageWarning = aParam.Warning;
|
||||
wParam.CellOverVoltageRelease = aParam.Release;
|
||||
break;
|
||||
case 1: // Cell Under Voltage
|
||||
cmd = 5;
|
||||
wParam.CellUnderVoltageTrip = aParam.Fault;
|
||||
wParam.CellUnderVoltageWarning = aParam.Warning;
|
||||
wParam.CellUnderVoltageRelease = aParam.Release;
|
||||
break;
|
||||
case 2: // System Over Voltage
|
||||
cmd = 7;
|
||||
wParam.SysOverVoltageTrip = aParam.Fault;
|
||||
wParam.SysOverVoltageWarning = aParam.Warning;
|
||||
wParam.SysOverVoltageRelease = aParam.Release;
|
||||
break;
|
||||
case 3: // System Under Voltage
|
||||
cmd = 7;
|
||||
wParam.SysUnderVoltageTrip = aParam.Fault;
|
||||
wParam.SysUnderVoltageWarning = aParam.Warning;
|
||||
wParam.SysUnderVoltageRelease = aParam.Release;
|
||||
break;
|
||||
case 4: // Charge High Temperature
|
||||
cmd = 6;
|
||||
wParam.ChaHighTempTrip = aParam.Fault;
|
||||
wParam.ChaHighTempWarning = aParam.Warning;
|
||||
wParam.ChaHighTempRelease = aParam.Release;
|
||||
break;
|
||||
case 5: // Charge Low Temperature
|
||||
cmd = 6;
|
||||
wParam.ChaLowTempTrip = aParam.Fault;
|
||||
wParam.ChaLowTempWarning = aParam.Warning;
|
||||
wParam.ChaLowTempRelease = aParam.Release;
|
||||
break;
|
||||
case 6: // Discharge High Temperature
|
||||
cmd = 6;
|
||||
wParam.DchHighTempTrip = aParam.Fault;
|
||||
wParam.DchHighTempWarning = aParam.Warning;
|
||||
wParam.DchHighTempRelease = aParam.Release;
|
||||
break;
|
||||
case 7: // Discharge Low Temperature
|
||||
cmd = 6;
|
||||
wParam.DchLowTempTrip = aParam.Fault;
|
||||
wParam.DchLowTempWarning = aParam.Warning;
|
||||
wParam.DchLowTempRelease = aParam.Release;
|
||||
break;
|
||||
case 8: // Charge Over Current
|
||||
cmd = 22;
|
||||
wParam.ChaOverCurrentTrip = aParam.Fault;
|
||||
wParam.ChaOverCurrentWarning = aParam.Warning;
|
||||
wParam.ChaOverCurrentRelease = aParam.Release;
|
||||
break;
|
||||
case 9: // Discharge Over Current
|
||||
cmd = 22;
|
||||
wParam.DchOverCurrentTrip = aParam.Fault;
|
||||
wParam.DchOverCurrentWarning = aParam.Warning;
|
||||
wParam.DchOverCurrentRelease = aParam.Release;
|
||||
break;
|
||||
case 10: // Low SOC
|
||||
cmd = 14;
|
||||
wParam.LowSocWarning = aParam.Warning;
|
||||
wParam.LowSocRelease = aParam.Release;
|
||||
break;
|
||||
case 11: // Cell Voltage Difference
|
||||
cmd = 2;
|
||||
wParam.CellVoltageDifferenceTrip = aParam.Fault;
|
||||
wParam.CellVoltageDifferenceWarning = aParam.Warning;
|
||||
wParam.CellVoltageDifferenceRelease = aParam.Release;
|
||||
break;
|
||||
case 16: // Default Parameter
|
||||
cmd = 16;
|
||||
wParam.DefalutParamOption = aParam.Fault;
|
||||
wParam.DefalutParamAll = aParam.Release;
|
||||
break;
|
||||
case 99:
|
||||
cmd = 99; // All parameter read
|
||||
break;
|
||||
}
|
||||
OnCommand?.Invoke(SystemId, cmd, flag, ref wParam, ref Calib);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private void btnCancel_Click(object sender, EventArgs e)
|
||||
{
|
||||
this.Close();
|
||||
}
|
||||
|
||||
public void UpdateData(DeviceParamData aParam, DeviceCalibration aCalib)
|
||||
{
|
||||
Param = aParam;
|
||||
Calib = aCalib;
|
||||
}
|
||||
|
||||
private void tmrDisplay_Tick(object sender, EventArgs e)
|
||||
{
|
||||
DisplayValue();
|
||||
|
||||
OnUpdate?.Invoke(this);
|
||||
}
|
||||
|
||||
private void DisplayValue()
|
||||
{
|
||||
ParamData pData = new ParamData();
|
||||
|
||||
// Cell Voltage Parameter
|
||||
pData.Fault = Param.CellOverVoltageTrip;
|
||||
pData.Warning = Param.CellOverVoltageWarning;
|
||||
pData.Release = Param.CellOverVoltageRelease;
|
||||
|
||||
ucCOVParam.UpdateData(pData);
|
||||
|
||||
pData.Fault = Param.CellUnderVoltageTrip;
|
||||
pData.Warning = Param.CellUnderVoltageWarning;
|
||||
pData.Release = Param.CellUnderVoltageRelease;
|
||||
|
||||
ucCUVParam.UpdateData(pData);
|
||||
|
||||
// System Voltage Parameter
|
||||
pData.Fault = Param.SysOverVoltageTrip;
|
||||
pData.Warning = Param.SysOverVoltageWarning;
|
||||
pData.Release = Param.SysOverVoltageRelease;
|
||||
|
||||
ucSOVParam.UpdateData(pData);
|
||||
|
||||
pData.Fault = Param.SysUnderVoltageTrip;
|
||||
pData.Warning = Param.SysUnderVoltageWarning;
|
||||
pData.Release = Param.SysUnderVoltageRelease;
|
||||
|
||||
ucSUVParam.UpdateData(pData);
|
||||
|
||||
// Charge Temp Parameter
|
||||
pData.Fault = Param.ChaHighTempTrip;
|
||||
pData.Warning = Param.ChaHighTempWarning;
|
||||
pData.Release = Param.ChaHighTempRelease;
|
||||
|
||||
ucCHTParam.UpdateData(pData);
|
||||
|
||||
pData.Fault = Param.ChaLowTempTrip;
|
||||
pData.Warning = Param.ChaLowTempWarning;
|
||||
pData.Release = Param.ChaLowTempRelease;
|
||||
|
||||
ucCLTParam.UpdateData(pData);
|
||||
|
||||
// Discharge Temp Parameter
|
||||
pData.Fault = Param.DchHighTempTrip;
|
||||
pData.Warning = Param.DchHighTempWarning;
|
||||
pData.Release = Param.DchHighTempRelease;
|
||||
|
||||
ucDHTParam.UpdateData(pData);
|
||||
|
||||
pData.Fault = Param.DchLowTempTrip;
|
||||
pData.Warning = Param.DchLowTempWarning;
|
||||
pData.Release = Param.DchLowTempRelease;
|
||||
|
||||
ucDLTParam.UpdateData(pData);
|
||||
|
||||
// Charge Over Current
|
||||
pData.Fault = Param.ChaOverCurrentTrip;
|
||||
pData.Warning = Param.ChaOverCurrentWarning;
|
||||
pData.Release = Param.ChaOverCurrentRelease;
|
||||
|
||||
ucCOCParam.UpdateData(pData);
|
||||
|
||||
// Discharge Over Current
|
||||
pData.Fault = Param.DchOverCurrentTrip;
|
||||
pData.Warning = Param.DchOverCurrentWarning;
|
||||
pData.Release = Param.DchOverCurrentRelease;
|
||||
|
||||
ucDOCParam.UpdateData(pData);
|
||||
|
||||
// Low SOC
|
||||
pData.Fault = Param.LowSocTrip;
|
||||
pData.Warning = Param.LowSocWarning;
|
||||
pData.Release = Param.LowSocRelease;
|
||||
|
||||
ucLowSocParam.UpdateData(pData);
|
||||
|
||||
// Cell Votage Difference
|
||||
pData.Fault = Param.CellVoltageDifferenceTrip;
|
||||
pData.Warning = Param.CellVoltageDifferenceWarning;
|
||||
pData.Release = Param.CellVoltageDifferenceRelease;
|
||||
|
||||
ucCvDiffParam.UpdateData(pData);
|
||||
}
|
||||
|
||||
private void btnGetAll_Click(object sender, EventArgs e)
|
||||
{
|
||||
ParamData aa = new ParamData();
|
||||
OnCmdEvent(99, 0, aa);
|
||||
}
|
||||
|
||||
private void btnDefaultSet_Click(object sender, EventArgs e)
|
||||
{
|
||||
ParamData aa = new ParamData();
|
||||
|
||||
if (cbFactoryDefault.Checked)
|
||||
aa.Fault = 1;
|
||||
else
|
||||
aa.Fault = 0;
|
||||
|
||||
if (chbAll.Checked)
|
||||
aa.Release = 1;
|
||||
else
|
||||
aa.Release = 0;
|
||||
|
||||
OnCmdEvent(16, 1, aa);
|
||||
}
|
||||
}
|
||||
}
|
||||
4574
LFP_Manager_PRM/Forms/fmxParamConfig.resx
Normal file
4574
LFP_Manager_PRM/Forms/fmxParamConfig.resx
Normal file
File diff suppressed because it is too large
Load Diff
92
LFP_Manager_PRM/Forms/fmxWait.Designer.cs
generated
Normal file
92
LFP_Manager_PRM/Forms/fmxWait.Designer.cs
generated
Normal file
@@ -0,0 +1,92 @@
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
partial class fmxWait
|
||||
{
|
||||
/// <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.progressPanel1 = new DevExpress.XtraWaitForm.ProgressPanel();
|
||||
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
|
||||
this.tableLayoutPanel1.SuspendLayout();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// progressPanel1
|
||||
//
|
||||
this.progressPanel1.Appearance.BackColor = System.Drawing.Color.Transparent;
|
||||
this.progressPanel1.Appearance.Options.UseBackColor = true;
|
||||
this.progressPanel1.AppearanceCaption.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F);
|
||||
this.progressPanel1.AppearanceCaption.Options.UseFont = true;
|
||||
this.progressPanel1.AppearanceDescription.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F);
|
||||
this.progressPanel1.AppearanceDescription.Options.UseFont = true;
|
||||
this.progressPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.progressPanel1.ImageHorzOffset = 20;
|
||||
this.progressPanel1.Location = new System.Drawing.Point(0, 17);
|
||||
this.progressPanel1.Margin = new System.Windows.Forms.Padding(0, 3, 0, 3);
|
||||
this.progressPanel1.Name = "progressPanel1";
|
||||
this.progressPanel1.Size = new System.Drawing.Size(246, 39);
|
||||
this.progressPanel1.TabIndex = 0;
|
||||
this.progressPanel1.Text = "progressPanel1";
|
||||
//
|
||||
// tableLayoutPanel1
|
||||
//
|
||||
this.tableLayoutPanel1.AutoSize = true;
|
||||
this.tableLayoutPanel1.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
|
||||
this.tableLayoutPanel1.BackColor = System.Drawing.Color.Transparent;
|
||||
this.tableLayoutPanel1.ColumnCount = 1;
|
||||
this.tableLayoutPanel1.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||
this.tableLayoutPanel1.Controls.Add(this.progressPanel1, 0, 0);
|
||||
this.tableLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.tableLayoutPanel1.Location = new System.Drawing.Point(0, 0);
|
||||
this.tableLayoutPanel1.Name = "tableLayoutPanel1";
|
||||
this.tableLayoutPanel1.Padding = new System.Windows.Forms.Padding(0, 14, 0, 14);
|
||||
this.tableLayoutPanel1.RowCount = 1;
|
||||
this.tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
|
||||
this.tableLayoutPanel1.Size = new System.Drawing.Size(246, 73);
|
||||
this.tableLayoutPanel1.TabIndex = 1;
|
||||
//
|
||||
// Form1
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.AutoSize = true;
|
||||
this.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink;
|
||||
this.ClientSize = new System.Drawing.Size(246, 73);
|
||||
this.Controls.Add(this.tableLayoutPanel1);
|
||||
this.DoubleBuffered = true;
|
||||
this.Name = "Form1";
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.Manual;
|
||||
this.Text = "Form1";
|
||||
this.tableLayoutPanel1.ResumeLayout(false);
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private DevExpress.XtraWaitForm.ProgressPanel progressPanel1;
|
||||
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||
}
|
||||
}
|
||||
43
LFP_Manager_PRM/Forms/fmxWait.cs
Normal file
43
LFP_Manager_PRM/Forms/fmxWait.cs
Normal file
@@ -0,0 +1,43 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Data;
|
||||
using System.Drawing;
|
||||
using System.Text;
|
||||
using System.Windows.Forms;
|
||||
using DevExpress.XtraWaitForm;
|
||||
|
||||
namespace LFP_Manager.Forms
|
||||
{
|
||||
public partial class fmxWait : WaitForm
|
||||
{
|
||||
public fmxWait()
|
||||
{
|
||||
InitializeComponent();
|
||||
this.progressPanel1.AutoHeight = true;
|
||||
}
|
||||
|
||||
#region Overrides
|
||||
|
||||
public override void SetCaption(string caption)
|
||||
{
|
||||
base.SetCaption(caption);
|
||||
this.progressPanel1.Caption = caption;
|
||||
}
|
||||
public override void SetDescription(string description)
|
||||
{
|
||||
base.SetDescription(description);
|
||||
this.progressPanel1.Description = description;
|
||||
}
|
||||
public override void ProcessCommand(Enum cmd, object arg)
|
||||
{
|
||||
base.ProcessCommand(cmd, arg);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
public enum WaitFormCommand
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
120
LFP_Manager_PRM/Forms/fmxWait.resx
Normal file
120
LFP_Manager_PRM/Forms/fmxWait.resx
Normal file
@@ -0,0 +1,120 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
</root>
|
||||
Reference in New Issue
Block a user