diff --git a/Analysis/BaseUnit/Base.cs b/Analysis/BaseUnit/Base.cs index 6f77fd6..914e3e3 100644 --- a/Analysis/BaseUnit/Base.cs +++ b/Analysis/BaseUnit/Base.cs @@ -259,7 +259,17 @@ namespace BaseFunction { if (rleMessage != null) { - rleMessage.Text = str; + //rleMessage.Text = str; + + if (rleMessage != null && rleMessage.ElementTree != null && rleMessage.ElementTree.Control.InvokeRequired) + { + rleMessage.ElementTree.Control.Invoke(new Action(() => rleMessage.Text = str)); + } + else if (rleMessage != null) + { + rleMessage.Text = str; + } + } if (str.Contains("警告") || str.ToUpper().Contains("WARN")) { diff --git a/Analysis/BaseUnit/FileSorter.cs b/Analysis/BaseUnit/FileSorter.cs index 7b025ab..d5a0022 100644 --- a/Analysis/BaseUnit/FileSorter.cs +++ b/Analysis/BaseUnit/FileSorter.cs @@ -2,10 +2,12 @@ using NSAnalysis.DAL; using NSAnalysis.Model; using System; +using System.Collections.Generic; using System.Data; +using System.Globalization; using System.IO; -namespace NSAnalysis.BaseUnit +namespace NSAnalysis { public class FileSorter { @@ -16,10 +18,16 @@ namespace NSAnalysis.BaseUnit public int readColIndex = 1; // 默认读取第2列(从0开始计数) + public event Action OnLog; // 日志事件 + + public event Action OnFileParsed; // 解析完成后通知文件名 + public FileSorter() { + //SQLHelper.connStr = DatabaseDfn.SqlConnectStr(); } + // 主逻辑处理 public void ProcessFiles() { var tasks = GetTaskRecords(); @@ -32,14 +40,14 @@ namespace NSAnalysis.BaseUnit string targetDir = task["targetFile"].ToString(); // 打印信息 - MyBase.TraceWriteLine($"Processing Task - Source: {sourceDir}, Target: {targetDir}, ModelCode: {modelCode} Position: {position}"); + Trace($"Processing Task - Source: {sourceDir}, Target: {targetDir}, ModelCode: {modelCode} Position: {position}"); if (Directory.Exists(sourceDir)) { ProcessDirectory(sourceDir, targetDir, modelCode, modelName, position); } else { - MyBase.TraceWriteLine($"[ProcessFiles] 源文件地址不存在或错误: {sourceDir}"); + Trace($"[ProcessFiles] 源文件地址不存在或错误: {sourceDir}"); //记录到数据库 try @@ -61,36 +69,34 @@ namespace NSAnalysis.BaseUnit } catch (Exception ex) { - MyBase.TraceWriteLine($"[ProcessFiles] 记录错误到数据库失败: {ex.Message}"); - } - finally - { - MyBase.TraceWriteLine($"[ProcessFiles] 源文件地址不存在或错误: {sourceDir}"); + Trace($"[ProcessFiles] 记录错误到数据库失败: {ex.Message}"); } + } } } + // 获取任务记录 private DataTable GetTaskRecords() { - SQLHelper.connStr = DatabaseDfn.SqlConnectStr(); DataTable dt = _dal.SelectTaskByCondition("", "", "start"); //打印 dt PrintDataTable(dt); if (dt == null || dt.Rows.Count == 0) { - MyBase.TraceWriteLine("No tasks found."); + Trace("未发现移动任务."); return null; } return dt; } + // 处理目录中的文件 private void ProcessDirectory(string sourceDir, string targetDir, string modelCode, string modelName, string position) { // 匹配信息 string matchStr = $"{modelCode}_{position}"; - MyBase.TraceWriteLine($"Matching files with: {matchStr}"); + Trace($"匹配文件特征符: {matchStr}"); // 判断目标目录是否存在,如果不存在记录到日志 @@ -98,19 +104,24 @@ namespace NSAnalysis.BaseUnit if (!Directory.Exists(targetDir)) { Directory.CreateDirectory(targetDir); - MyBase.TraceWriteLine($"Created target directory: {targetDir}"); + Trace($"创建目标文件夹: {targetDir}"); } // 遍历源目录中的所有CSV文件 foreach (string file in Directory.GetFiles(sourceDir, "*.csv")) { // 打印正在处理的文件 - MyBase.TraceWriteLine($"Processing file: {file}"); + Trace($"正在处理文件 : {file}"); + + // 解析入库 + AnalysisNxsCSV(file); + + // 分发逻辑 if (MatchCsvValue(file, matchStr, readRowIndex, readColIndex)) { string destFile = Path.Combine(targetDir, Path.GetFileName(file)); File.Move(file, destFile); - MyBase.TraceWriteLine($"Moved: {file} -> {destFile}"); + Trace($"移动完成,: {file} -> {destFile}"); //插入分发详情 CjlrTaskReleaseDetailModel detailModel = new CjlrTaskReleaseDetailModel @@ -129,7 +140,7 @@ namespace NSAnalysis.BaseUnit } else { - MyBase.TraceWriteLine($"No match for file: {file}"); + Trace($"未匹配到文件: {file}"); //记录到数据库 CjlrTaskReleaseDetailModel detailModel = new CjlrTaskReleaseDetailModel @@ -150,7 +161,7 @@ namespace NSAnalysis.BaseUnit } catch (Exception ex) { - MyBase.TraceWriteLine($"记录错误到数据库失败: {ex.Message}"); + Trace($"记录错误到数据库失败: {ex.Message}"); } } } @@ -189,13 +200,12 @@ namespace NSAnalysis.BaseUnit } } - // 编写一个打印 DataTable 对象的方法,输入是对象 public static void PrintDataTable(DataTable dt) { if (dt == null || dt.Rows.Count == 0) { - MyBase.TraceWriteLine("DataTable is empty or null."); + MyBase.TraceWriteLine("[PrintDataTable] DataTable is empty or null."); return; } foreach (DataColumn column in dt.Columns) @@ -213,7 +223,231 @@ namespace NSAnalysis.BaseUnit } } + // 导入CSV文件到数据库 + public void ImportCsv2Sql(string filePath) + { + var records = new List(); + var lineNo = 0; // 行号计数器 + try + { + using (var reader = new StreamReader(filePath)) + { + // Skip header + reader.ReadLine(); + + lineNo = 1; // 初始化行号计数器 + while (!reader.EndOfStream) + { + lineNo++; // 增加行号计数器 + var line = reader.ReadLine(); + var values = line.Split(','); // 假设 CSV 使用制表符分隔 + + // 跳过前两行(如果有标题行或其他非数据行 + if (string.IsNullOrWhiteSpace(line) || line.StartsWith("#") || line.StartsWith("//") || line.StartsWith("MeasPoint.Name")) + { + continue; // 跳过空行或注释行 + } + + // 跳过前两行(如果有标题行或其他非数据行) + if (values.Length < 22) + { + MyBase.TraceWriteLine("CSV行数据不完整,跳过该行:" + line); + continue; // 跳过不完整的行 + } + + // 判断 values[2] 是否为 ,如果是则跳过该行 + if (string.IsNullOrEmpty(values[2])) + { + MyBase.TraceWriteLine($"第 {lineNo} 行数据为0,跳过该行:" + line); + continue; // 跳过该行 + } + + // 创建 MeasurementRecord 对象并填充数据 + var record = new CJLR_MeaDataModel + { + PointName = values[0], + GroupName = values[1], + ProductNum = values[2], + Model = values[3], + Station = values[4], + Method = values[5], + Standard = values[6], + DimensionName = values[7], + DimensionValue = values[8], + DimensionUnit = values[9], + IsManual = bool.Parse(values[10]), + Classification = values[11], + ToleranceName0 = values[12], + ToleranceLower0 = values[13], + ToleranceUpper0 = values[14], + ToleranceName1 = values[15], + ToleranceLower1 = values[16], + ToleranceUpper1 = values[17], + NominalValue = values[18], + MeasureDate = DateTime.ParseExact(values[19], "yyyyMMdd", CultureInfo.InvariantCulture), + MeasureTime = TimeSpan.ParseExact(values[20], "hhmmss", CultureInfo.InvariantCulture), + SequenceNum = int.Parse(values[21]) + }; + + records.Add(record); + } + } + } + catch (Exception ex) + { + MyBase.TraceWriteLine("导入CSV文件时发生错误:" + ex.Message); + return; + } + + try + { + // 取第一条记录的时间作为测量时间 + if (records.Count > 0) + { + var firstRecord = records[0]; + ConfigDfn.strMeasureTime = firstRecord.MeasureDate.ToString("yyyy-MM-dd") + " " + firstRecord.MeasureTime.ToString(@"hh\:mm\:ss"); + + // 获取车号 + MyBase.TraceWriteLine("--------------------------------------------------------"); + + ConfigDfn.strEquipNo = firstRecord.ProductNum; + MyBase.TraceWriteLine("车号:" + ConfigDfn.strEquipNo); + //获取车型 + ConfigDfn.strCarModel = firstRecord.Model; + MyBase.TraceWriteLine("车型:" + ConfigDfn.strCarModel); + MyBase.TraceWriteLine("测量时间:" + ConfigDfn.strMeasureTime); + } + else + { + MyBase.TraceWriteLine("没有找到有效的测量记录,无法设置测量时间。"); + + // 将文件移动到 未导入文件夹,如果不存在则新建该文件夹 + //string strNotImportPath = ConfigDfn.strFileFolder + "\\NextSenseCSVNotImport\\"; + //if (!Directory.Exists(strNotImportPath)) + //{ + // Directory.CreateDirectory(strNotImportPath); + //} + //string destFilePath = Path.Combine(strNotImportPath, Path.GetFileName(filePath)); + //File.Move(filePath, destFilePath); + //MyBase.TraceWriteLine("将文件移动到未导入文件夹,路径为:" + destFilePath); + + return; + } + + // 逐条插入数据到数据库 + foreach (var record in records) + { + _dal.InsertCJLRMeaData(record); + } + + MyBase.TraceWriteLine("CSV文件导入到数据库成功!"); + MyBase.TraceWriteLine("--------------------------------------------------------"); + } + catch (Exception ex) + { + MyBase.TraceWriteLine("导入CSV文件时发生错误:" + ex.Message); + } + } + + //解析EH3 CSV文件函数 + public void AnalysisNxsCSV(string strCSVName) + { + // 判断文件是否存在 + if (!File.Exists(strCSVName)) + { + MyBase.TraceWriteLine("文件不存在:" + strCSVName); + return; + } + + try + { + // 解析 CSV 文件并导入到数据库 + ImportCsv2Sql(strCSVName); + + // 解析完成后触发事件 + if (!string.IsNullOrEmpty(ConfigDfn.strEquipNo)) + { + OnFileParsed?.Invoke(ConfigDfn.strEquipNo); + } + } + catch (Exception ex) + { + MyBase.TraceWriteLine("解析 CSV 文件时发生错误:" + ex.Message); + } + } + + private void GenCustomerReport() + { + //#region 解析完报告后,重新生成客户模板报告 + + //string filePath = strSaveReprotPath + DateTime.Now.ToString("yyyyMMddHHmmss") + "_" + strCarID + ".csv"; //wsp 后期还要再改 + //string strWithoutLCarVin = strCarID.Substring(1); + //StringBuilder sb = new StringBuilder(); + ////添加表头 + //sb.Append("Measurement Info Name"); + //sb.Append(","); + //sb.Append("Measurement Info"); + //sb.AppendLine(); + //sb.Append("Date_Time"); + //sb.Append(","); + //sb.Append(DateTime.Now.ToString("yyyy/MM/dd HH:mm:ss")); + //sb.AppendLine(); + //for (int i = 0; i < listCSVTitleInfo.Count; i++) + //{ + // if (listCSVTitleInfo[i].Contains("prodnum")) + // { + // listCSVTitleInfo[i] = listCSVTitleInfo[i].Replace("prodnum", "Part_ident"); + // } + // if (listCSVTitleInfo[i].Contains(strWithoutLCarVin)) + // { + // listCSVTitleInfo[i] = listCSVTitleInfo[i].Replace(strWithoutLCarVin, strCarID); + // } + // sb.Append(listCSVTitleInfo[i]); + // sb.AppendLine(); + //} + //sb.AppendLine(); + //sb.AppendLine(); + //sb.AppendLine(); + //sb.AppendLine(); + //sb.AppendLine(); + ////添加测量数据 + //sb.Append("Characteristic"); + //sb.Append(","); + //sb.Append("Extension"); + //sb.Append(","); + //sb.Append("Measured_Value"); + //sb.AppendLine(); + //foreach (DataRow row in dtCSVContent.Rows) + //{ + // sb.Append(row.ItemArray[2]); + // sb.Append(","); + // sb.Append(row.ItemArray[3]); + // sb.Append(","); + // sb.Append(row.ItemArray[7]); + // sb.AppendLine(); + //} + + //sb.Append("POP"); + //sb.Append(","); + //sb.Append("P"); + //sb.Append(","); + //sb.Append(Math.Round(FPYPercent * 100.00d, 2).ToString("F2")); + //sb.AppendLine(); + //// 将数据写入CSV文件 + //File.WriteAllText(filePath, sb.ToString()); + //MyBase.TraceWriteLine("客户csv报告生成完毕,路径为:" + filePath); + + //#endregion 解析完报告后,重新生成客户模板报告 + } + + private void Trace(string msg) + { + OnLog?.Invoke(msg); + MyBase.TraceWriteLine(msg); // 保持原有日志 + } + + // 测试方法 public void test() { SQLHelper.connStr = DatabaseDfn.SqlConnectStr(); @@ -221,6 +455,5 @@ namespace NSAnalysis.BaseUnit //bool result = MatchCsvValue(testPath, "X540_L", 3, 1); //MyBase.TraceWriteLine($"匹配结果: {result}"); } - } } \ No newline at end of file diff --git a/Analysis/DAL/Model/TMeasureResultModel.cs b/Analysis/DAL/Model/TMeasureResultModel.cs index bc20b58..1fff118 100644 --- a/Analysis/DAL/Model/TMeasureResultModel.cs +++ b/Analysis/DAL/Model/TMeasureResultModel.cs @@ -56,5 +56,6 @@ /// Remark 备注 /// public string Remark { get; set; } + } } \ No newline at end of file diff --git a/Analysis/DAL/SQLHelper.cs b/Analysis/DAL/SQLHelper.cs index f31ef30..63a6df7 100644 --- a/Analysis/DAL/SQLHelper.cs +++ b/Analysis/DAL/SQLHelper.cs @@ -84,16 +84,20 @@ namespace NSAnalysis.DAL public static int ExecuteNonQuery(string cmdText, SqlParameter[] paras, CommandType ct) { int res = 0; - - using (cmd = new SqlCommand(cmdText, GetConn())) + using (var conn = new SqlConnection(connStr)) { - cmd.CommandType = ct; - cmd.Parameters.AddRange(paras); - res = cmd.ExecuteNonQuery(); + conn.Open(); + using (var cmd = new SqlCommand(cmdText, conn)) + { + cmd.CommandType = ct; + cmd.Parameters.AddRange(paras); + res = cmd.ExecuteNonQuery(); + } } return res; } + #endregion 执行带参数的增删改SQL语句或存储过程 返回int类型 返回受影响的行数 #region 执行不带参数的查询SQL语句或存储过程 返回DataTable类型 diff --git a/Analysis/Define/Define.cs b/Analysis/Define/Define.cs index 5a36388..a3a9b5d 100644 --- a/Analysis/Define/Define.cs +++ b/Analysis/Define/Define.cs @@ -83,7 +83,7 @@ namespace NSAnalysis public static double dFPY = 0.8; public static double dFPY2 = 0.6; - public static string strCarModel = ""; + public static string strCarModel = ""; //车型 public static string strEquipNo = ""; public static string strEquipName = ""; public static string strIOTAddress = ""; @@ -134,7 +134,6 @@ namespace NSAnalysis bRememberMe = FileIni.ReadBool(ConfigDfn.strConfigFile, strSection, "RememberMe", 0); strNextSenseCSVEH3Path = FileIni.ReadString(ConfigDfn.strConfigFile, strSection, "NextsenseCSVEH3Path"); - strPwd = FileIni.ReadString(ConfigDfn.strConfigFile, strSection, "Password"); iCreateReportFlag = FileIni.ReadInt(ConfigDfn.strConfigFile, strSection, "CreateReportFlag"); strUploadPath = FileIni.ReadString(ConfigDfn.strConfigFile, strSection, "tavascanUploadPath"); @@ -148,6 +147,8 @@ namespace NSAnalysis iIncludeRangeFlag = FileIni.ReadInt(strConfigFile, strSection, "IncludeRangeFlag"); iMeasureItemsCount = FileIni.ReadInt(strConfigFile, strSection, "MeasureCarItemsCount"); + + #endregion 读取系统配置参数 } diff --git a/Analysis/FormMain.cs b/Analysis/FormMain.cs index 4286fd5..cbcb6a9 100644 --- a/Analysis/FormMain.cs +++ b/Analysis/FormMain.cs @@ -5,13 +5,11 @@ using NSAnalysis.Model; using NSAnalysis.Properties; using System; -using System.Collections.Generic; using System.Data; using System.Drawing; -using System.Globalization; using System.IO; -using System.Linq; using System.Text; +using System.Threading.Tasks; using System.Windows.Forms; using Telerik.WinControls; using Telerik.WinControls.UI; @@ -20,17 +18,18 @@ namespace NSAnalysis { public partial class FormMain : Telerik.WinControls.UI.ShapedForm { + private Timer fileSortTimer = new Timer(); // 定时器,用于定时分发任务 + private FileSorter fileSorter = new FileSorter(); + #region 全局变量 private int[] yValues = new int[3]; private string[] xValues = new string[3]; private DataTable dtCSVContent = new DataTable(); - private DataTable dtRangeData = new DataTable(); - private CjlrDAL tmdal = new CjlrDAL(); - private string strSaveReprotPath = ""; - private bool bReadCSVFlag = false; - private int iCurrentMeasureItemsFailedCount = 0; + private CjlrDAL tmdal = new CjlrDAL(); + + private bool bReadCSVFlag = false; private int iLastMesureCount = 0; @@ -83,20 +82,15 @@ namespace NSAnalysis rdtpStartTime.Text = DateTime.Now.ToString("yyyy-MM-dd"); rdtpEndTime.Text = DateTime.Now.ToString("yyyy-MM-dd"); - MyBase.TraceWriteLine(" 进入解析CSV文件模式,开始解析扫码CSV文件!"); - tmReadNextsenseCSV.Interval = 5000; - tmReadNextsenseCSV.Start(); + // 定时处理任务 + fileSortTimer.Interval = 10000; // 每60秒检查一次分发任务 + fileSortTimer.Tick += FileSortTimer_Tick; + fileSortTimer.Start(); + + // 订阅处理中事件 + fileSorter.OnFileParsed += FileSorter_OnFileParsed; + - if (Directory.Exists(ConfigDfn.strNextSenseCSVEH3Path)) - { - MyBase.TraceWriteLine("软件首次启动, Nextsense EH3 CSV读取路径存在;不清空,读取NextSense生成 CSV报告路径下的所有文件,路径为:" + ConfigDfn.strNextSenseCSVEH3Path); - } - else - { - string strTip = "错误:软件首次启动,读取NextSense生成EH3 CSV报告的路径:" + ConfigDfn.strNextSenseCSVEH3Path + " 不存在!请检查并进行修改!点击是按钮,软件将自动创建该路径!"; - MyBase.TraceWriteLine(strTip); - Directory.CreateDirectory(ConfigDfn.strNextSenseCSVEH3Path); - } //绑定按钮 lpcSoftwareSetup.labPicture.Click += new EventHandler(lpcSoftwareSetup_Click); @@ -128,7 +122,7 @@ namespace NSAnalysis #endregion 清空信息 InitTableColumns(); - strSaveReprotPath = ConfigDfn.strReportPath + @"\"; + } private void InitTableColumns() @@ -175,14 +169,6 @@ namespace NSAnalysis DataColumn dcRemark = new DataColumn("Remark", Type.GetType("System.String")); //将列添加到table表中 - dtRangeData.Columns.Add(dcCarID); - dtRangeData.Columns.Add(dcRangeName); - dtRangeData.Columns.Add(dcRangeValue); - dtRangeData.Columns.Add(dcRangeLowUpp); - dtRangeData.Columns.Add(dcResult); - dtRangeData.Columns.Add(dcCreateTime); - dtRangeData.Columns.Add(dcRemark); - #endregion 极差数据Table初始化 #region 分页相关 @@ -238,6 +224,8 @@ namespace NSAnalysis System.Environment.Exit(0); } + #endregion 主窗口事件 + private void tmSystem_Tick(object sender, EventArgs e) { rleTime.Text = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"); @@ -246,309 +234,144 @@ namespace NSAnalysis bReadCSVFlag = !bReadCSVFlag; } - #endregion 主窗口事件 - - private void tmReadNextsenseCSV_Tick(object sender, EventArgs e) + private void FileSortTimer_Tick(object sender, EventArgs e) //分发定时器 { - tmReadNextsenseCSV.Stop(); - - //AnalysisNxsCSV(); - - tmReadNextsenseCSV.Start(); + // 后台运行,避免阻塞UI + Task.Run(() => + { + try + { + fileSorter.ProcessFiles(); + } + catch (Exception ex) + { + MyBase.TraceWriteLine($"分发任务异常: {ex.Message}"); + } + }); } - public void ImportCsv2Sql(string filePath) + private void DisplayMeasureData(string strCarID) { - var records = new List(); - var lineNo = 0; // 行号计数器 - decimal dimensionValue; - using (var reader = new StreamReader(filePath)) - { - // Skip header - reader.ReadLine(); - - lineNo = 1; // 初始化行号计数器 - while (!reader.EndOfStream) - { - lineNo++; // 增加行号计数器 - var line = reader.ReadLine(); - var values = line.Split(','); // 假设 CSV 使用制表符分隔 - - // 跳过前两行(如果有标题行或其他非数据行 - if (string.IsNullOrWhiteSpace(line) || line.StartsWith("#") || line.StartsWith("//") || line.StartsWith("MeasPoint.Name")) - { - continue; // 跳过空行或注释行 - } - - // 跳过前两行(如果有标题行或其他非数据行) - if (values.Length < 22) - { - MyBase.TraceWriteLine("CSV行数据不完整,跳过该行:" + line); - continue; // 跳过不完整的行 - } - if (!decimal.TryParse(values[8], NumberStyles.Any, CultureInfo.InvariantCulture, out dimensionValue)) - { - MyBase.TraceWriteLine($"CSV第{lineNo}行,DimensionValue字段格式不正确,值为:{values[8]},跳过该行。"); - continue; // 跳过该行 - } - // 创建 MeasurementRecord 对象并填充数据 - var record = new CJLR_MeaDataModel - { - PointName = values[0], - GroupName = values[1], - ProductNum = values[2], - Model = values[3], - Station = values[4], - Method = values[5], - Standard = values[6], - DimensionName = values[7], - DimensionValue = decimal.Parse(values[8], CultureInfo.InvariantCulture), - DimensionUnit = values[9], - IsManual = bool.Parse(values[10]), - Classification = values[11], - ToleranceName0 = values[12], - ToleranceLower0 = decimal.Parse(values[13], CultureInfo.InvariantCulture), - ToleranceUpper0 = decimal.Parse(values[14], CultureInfo.InvariantCulture), - ToleranceName1 = values[15], - ToleranceLower1 = decimal.Parse(values[16], CultureInfo.InvariantCulture), - ToleranceUpper1 = decimal.Parse(values[17], CultureInfo.InvariantCulture), - NominalValue = decimal.Parse(values[18], CultureInfo.InvariantCulture), - MeasureDate = DateTime.ParseExact(values[19], "yyyyMMdd", CultureInfo.InvariantCulture), - MeasureTime = TimeSpan.ParseExact(values[20], "hhmmss", CultureInfo.InvariantCulture), - SequenceNum = int.Parse(values[21]) - }; - - records.Add(record); - } - } - try { - // 取第一条记录的时间作为测量时间 - if (records.Count > 0) + #region 左侧统计和饼图、合格率 + + MyBase.TraceWriteLine("正在查询车ID为:" + strCarID + " 的测量结果。"); + DataTable sampleData = tmdal.SelectMeasureResultByCarID(strCarID); + + AnalysisResult analysis = AnalysisResult.AnalyzeMeasureData(sampleData); + AnalysisResult.DisplayAnalysisResult(analysis); + + // 记录正在查询 + + //表格行数 + int dtRowCount = analysis.TotalCount; + //超差个数 + double OutCount = analysis.OutCount; + //Ok个数 + double OKCount = analysis.OKCount; + //异常个数 + double RejectedCount = analysis.RejectedCount; + //合格率 + double FPYPercent = analysis.FPYPercent; + + labVIN.Text = strCarID; + labCarType.Text = ConfigDfn.strCarModel; + TMeasureResultModel tmrm = new TMeasureResultModel(); + labNGCount.Text = OutCount.ToString(); + labOKCount.Text = OKCount.ToString(); + labRejectCount.Text = RejectedCount.ToString(); + labMeaTime.Text = ConfigDfn.strMeasureTime; + labSumMeasureCount.Text = dtRowCount.ToString(); + FPYPercent = OKCount / (OKCount + OutCount); + if (FPYPercent >= ConfigDfn.dFPY) { - var firstRecord = records[0]; - ConfigDfn.strMeasureTime = firstRecord.MeasureDate.ToString("yyyy-MM-dd") + " " + firstRecord.MeasureTime.ToString(@"hh\:mm\:ss"); - - // 获取车号 - MyBase.TraceWriteLine("--------------------------------------------------------"); - - var strCarID = firstRecord.ProductNum; - MyBase.TraceWriteLine("车号:" + strCarID); - //获取车型 - ConfigDfn.strCarModel = firstRecord.Model; - MyBase.TraceWriteLine("车型:" + ConfigDfn.strCarModel); - MyBase.TraceWriteLine("测量时间:" + ConfigDfn.strMeasureTime); + labResultPercent.Text = Math.Round(FPYPercent * 100.00d, 2).ToString("F2") + "%"; + labResult.Text = "合格"; + labResultPercent.ForeColor = Color.LimeGreen; + labResult.ForeColor = Color.LimeGreen; + pbResult.Image = Resources.OK; + tmrm.Result = 1; + } + else if (FPYPercent >= ConfigDfn.dFPY2 && FPYPercent < ConfigDfn.dFPY) + { + labResultPercent.Text = Math.Round(FPYPercent * 100.00d, 2).ToString("F2") + "%"; + labResult.Text = "合格"; + labResultPercent.ForeColor = Color.Yellow; + labResult.ForeColor = Color.Yellow; + pbResult.Image = Resources.OK; + tmrm.Result = 1; } else { - MyBase.TraceWriteLine("没有找到有效的测量记录,无法设置测量时间。"); + labResultPercent.Text = Math.Round(FPYPercent * 100.00d, 2).ToString("F2") + "%"; + labResult.Text = "不合格"; + labResultPercent.ForeColor = Color.Red; + labResult.ForeColor = Color.Red; + pbResult.Image = Resources.NG; + tmrm.Result = 2; + } + xValues[0] = "合格 : " + OKCount.ToString(); + xValues[1] = "不合格 : " + OutCount.ToString(); + xValues[2] = "异常 : " + RejectedCount.ToString(); + yValues[0] = (int)OKCount; + yValues[1] = (int)OutCount; + yValues[2] = (int)RejectedCount; + chartResultPie.Series[0].Points.DataBindXY(xValues, yValues); - // 将文件移动到 未导入文件夹,如果不存在则新建该文件夹 - string strNotImportPath = ConfigDfn.strFileFolder + "\\NextSenseCSVNotImport\\"; - if (!Directory.Exists(strNotImportPath)) - { - Directory.CreateDirectory(strNotImportPath); - } - string destFilePath = Path.Combine(strNotImportPath, Path.GetFileName(filePath)); - File.Move(filePath, destFilePath); - MyBase.TraceWriteLine("将文件移动到未导入文件夹,路径为:" + destFilePath); + string strTargetRate = Math.Round(ConfigDfn.dFPY2 * 100.00d, 2).ToString("F2") + "%"; + tmrm.CarID = strCarID; + tmrm.CarType = ConfigDfn.strCarModel; + tmrm.SumMeasureItems = dtRowCount; + tmrm.GoodMeasureItems = (int)OKCount; + tmrm.NoGoodMeasureItems = (int)OutCount; + tmrm.RejectMeasureItems = (int)RejectedCount; + tmrm.FPY = FPYPercent.ToString("F4"); + tmrm.Remark = ""; + tmrm.MeasureDate = ConfigDfn.strMeasureTime; + tmdal.InsertTMeasureResult(tmrm); + MyBase.TraceWriteLine("将总结果插入数据库完毕。"); + + #endregion 左侧统计和饼图、合格率 + + #region 表单区填充 + + DataTable dataTable = tmdal.SelectMeasureDataByCarID(strCarID); + + // 判断是否有数据 + if (dataTable == null || dataTable.Rows.Count == 0) + { + MyBase.TraceWriteLine("没有找到车ID为:" + strCarID + " 的测量数据。"); return; } + dgvMeasureContent.DataSource = dataTable; - // 逐条插入数据到数据库 - foreach (var record in records) + this.dgvMeasureContent.Rows[dgvMeasureContent.Rows.Count - 1].DefaultCellStyle.ForeColor = Color.White; + if (dgvMeasureContent.Rows.Count > 0) { - tmdal.InsertCJLRMeaData(record); - } - } - catch (Exception ex) - { - MyBase.TraceWriteLine("导入CSV文件时发生错误:" + ex.Message); - return; - } - } - - private void AnalysisNxsCSV(string scanFolderPath) //解析EH3 CSV文件函数 - { - // 打印正在扫描的路径 - MyBase.TraceWriteLine("正在扫描 CSV文件路径:" + scanFolderPath); - // 判断该路径是否存在 - if (!Directory.Exists(scanFolderPath)) - { - MyBase.TraceWriteLine("错误: CSV文件路径:" + scanFolderPath + " 不存在!请检查并进行修改!"); - return; - } - - try - { - lbCSVFiles.Items.Clear(); - FileInfo[] fileInfos = null; - if (Directory.Exists(scanFolderPath)) - { - DirectoryInfo di = new DirectoryInfo(scanFolderPath); - fileInfos = di.GetFiles("*.CSV"); - if (fileInfos.Count() >= 1) + SetdgvRowBgColor(dgvMeasureContent); + for (int i = 0; i < dgvMeasureContent.Rows.Count; i++) { - MyBase.TraceWriteLine("存在CSV文件,开始解析:"); - List listCSVTitleInfo = new List(); - string strCarID = ""; - foreach (FileInfo fi in fileInfos) + //if (dgvMeasureContent.Rows[i].Cells["MResult"].Value.ToString().ToLower().Contains("ok")) + //{ + // dgvMeasureContent.Rows[i].DefaultCellStyle.BackColor = Color.Orange; + //} + if (dgvMeasureContent.Rows[i].Cells["Classification"].Value.ToString().ToLower().Contains("ng")) + { + dgvMeasureContent.Rows[i].DefaultCellStyle.BackColor = Color.Orange; + } + else if (string.IsNullOrEmpty(dgvMeasureContent.Rows[i].Cells["Classification"].Value.ToString())) + { + dgvMeasureContent.Rows[i].DefaultCellStyle.BackColor = Color.Red; + } + else { - listCSVTitleInfo.Clear(); - - dtCSVContent.Clear(); - // 直接清空数据源 - if (dgvMeasureContent.DataSource is DataTable dt) - { - dt.Rows.Clear(); - } - - string strCSVName = fi.FullName; - - #region 解析EH3 CSV报告 - - MyBase.TraceWriteLine("开始解析 CSV 报告:" + strCSVName); - ImportCsv2Sql(strCSVName); - - // 备份数据 - File.Copy(fi.FullName, ConfigDfn.strFileFolder + "\\NextSenseCSVBackup\\" + fi.Name, true); - MyBase.TraceWriteLine("Copy " + fi.FullName + " TO " + ConfigDfn.strFileFolder + "\\NextSenseCSVBackup\\" + fi.Name + " Done. 备份完成"); - lbCSVFiles.Items.Add(fi.Name); - MyBase.TraceWriteLine("解析 CSV 报告完毕!"); - - #endregion 解析EH3 CSV报告 - - #region 左侧统计和饼图、合格率 - - // 从文件名 strCSVName 提取文件名中的车ID - int startIndex = strCSVName.LastIndexOf("\\") + 1; - int endIndex = strCSVName.LastIndexOf("."); - strCarID = strCSVName.Substring(startIndex, endIndex - startIndex); - MyBase.TraceWriteLine("正在查询车ID为:" + strCarID + " 的测量结果。"); - DataTable sampleData = tmdal.SelectMeasureResultByCarID(strCarID); - - AnalysisResult analysis = AnalysisResult.AnalyzeMeasureData(sampleData); - AnalysisResult.DisplayAnalysisResult(analysis); - - // 记录正在查询 - - //表格行数 - int dtRowCount = analysis.TotalCount; - //超差个数 - double OutCount = analysis.OutCount; - //Ok个数 - double OKCount = analysis.OKCount; - //异常个数 - double RejectedCount = analysis.RejectedCount; - //合格率 - double FPYPercent = analysis.FPYPercent; - - labVIN.Text = strCarID; - labCarType.Text = ConfigDfn.strCarModel; - TMeasureResultModel tmrm = new TMeasureResultModel(); - labNGCount.Text = OutCount.ToString(); - labOKCount.Text = OKCount.ToString(); - labRejectCount.Text = RejectedCount.ToString(); - labMeaTime.Text = ConfigDfn.strMeasureTime; - labSumMeasureCount.Text = dtRowCount.ToString(); - FPYPercent = OKCount / (OKCount + OutCount); - if (FPYPercent >= ConfigDfn.dFPY) - { - labResultPercent.Text = Math.Round(FPYPercent * 100.00d, 2).ToString("F2") + "%"; - labResult.Text = "合格"; - labResultPercent.ForeColor = Color.LimeGreen; - labResult.ForeColor = Color.LimeGreen; - pbResult.Image = Resources.OK; - tmrm.Result = 1; - } - else if (FPYPercent >= ConfigDfn.dFPY2 && FPYPercent < ConfigDfn.dFPY) - { - labResultPercent.Text = Math.Round(FPYPercent * 100.00d, 2).ToString("F2") + "%"; - labResult.Text = "合格"; - labResultPercent.ForeColor = Color.Yellow; - labResult.ForeColor = Color.Yellow; - pbResult.Image = Resources.OK; - tmrm.Result = 1; - } - else - { - labResultPercent.Text = Math.Round(FPYPercent * 100.00d, 2).ToString("F2") + "%"; - labResult.Text = "不合格"; - labResultPercent.ForeColor = Color.Red; - labResult.ForeColor = Color.Red; - pbResult.Image = Resources.NG; - tmrm.Result = 2; - } - xValues[0] = "合格 : " + OKCount.ToString(); - xValues[1] = "不合格 : " + OutCount.ToString(); - xValues[2] = "异常 : " + RejectedCount.ToString(); - yValues[0] = (int)OKCount; - yValues[1] = (int)OutCount; - yValues[2] = (int)RejectedCount; - chartResultPie.Series[0].Points.DataBindXY(xValues, yValues); - - string strTargetRate = Math.Round(ConfigDfn.dFPY2 * 100.00d, 2).ToString("F2") + "%"; - - tmrm.CarID = strCarID; - tmrm.CarType = ConfigDfn.strCarModel; - tmrm.SumMeasureItems = dtRowCount; - tmrm.GoodMeasureItems = (int)OKCount; - tmrm.NoGoodMeasureItems = (int)OutCount; - tmrm.RejectMeasureItems = (int)RejectedCount; - tmrm.FPY = FPYPercent.ToString("F4"); - tmrm.Remark = ""; - tmrm.MeasureDate = ConfigDfn.strMeasureTime; - tmdal.InsertTMeasureResult(tmrm); - MyBase.TraceWriteLine("将总结果插入数据库完毕。"); - MyBase.TraceWriteLine("全部插入解析完毕,删除文件:" + fi.Name); - fi.Delete(); - - #endregion 左侧统计和饼图、合格率 - - #region 表单区填充 - - DataTable dataTable = tmdal.SelectMeasureDataByCarID(strCarID); - - // 判断是否有数据 - if (dataTable == null || dataTable.Rows.Count == 0) - { - MyBase.TraceWriteLine("没有找到车ID为:" + strCarID + " 的测量数据。"); - return; - } - dgvMeasureContent.DataSource = dataTable; - - this.dgvMeasureContent.Rows[dgvMeasureContent.Rows.Count - 1].DefaultCellStyle.ForeColor = Color.White; - if (dgvMeasureContent.Rows.Count > 0) - { - SetdgvRowBgColor(dgvMeasureContent); - for (int i = 0; i < dgvMeasureContent.Rows.Count; i++) - { - //if (dgvMeasureContent.Rows[i].Cells["MResult"].Value.ToString().ToLower().Contains("ok")) - //{ - // dgvMeasureContent.Rows[i].DefaultCellStyle.BackColor = Color.Orange; - //} - if (dgvMeasureContent.Rows[i].Cells["Classification"].Value.ToString().ToLower().Contains("ng")) - { - dgvMeasureContent.Rows[i].DefaultCellStyle.BackColor = Color.Orange; - } - else if (string.IsNullOrEmpty(dgvMeasureContent.Rows[i].Cells["Classification"].Value.ToString())) - { - dgvMeasureContent.Rows[i].DefaultCellStyle.BackColor = Color.Red; - } - else - { - } - } - } - - #endregion 表单区填充 - - //生成客户的 CSV文件 } } } + + #endregion 表单区填充 } catch (Exception ex) { @@ -556,70 +379,28 @@ namespace NSAnalysis } } - private void GenCustomerReport() + private void FileSorter_OnFileParsed(string strCarID) { - //#region 解析完报告后,重新生成客户模板报告 + // 线程安全更新 UI + if (InvokeRequired) + { + Invoke(new Action(FileSorter_OnFileParsed), strCarID); + return; + } - //string filePath = strSaveReprotPath + DateTime.Now.ToString("yyyyMMddHHmmss") + "_" + strCarID + ".csv"; //wsp 后期还要再改 - //string strWithoutLCarVin = strCarID.Substring(1); - //StringBuilder sb = new StringBuilder(); - ////添加表头 - //sb.Append("Measurement Info Name"); - //sb.Append(","); - //sb.Append("Measurement Info"); - //sb.AppendLine(); - //sb.Append("Date_Time"); - //sb.Append(","); - //sb.Append(DateTime.Now.ToString("yyyy/MM/dd HH:mm:ss")); - //sb.AppendLine(); - //for (int i = 0; i < listCSVTitleInfo.Count; i++) - //{ - // if (listCSVTitleInfo[i].Contains("prodnum")) - // { - // listCSVTitleInfo[i] = listCSVTitleInfo[i].Replace("prodnum", "Part_ident"); - // } - // if (listCSVTitleInfo[i].Contains(strWithoutLCarVin)) - // { - // listCSVTitleInfo[i] = listCSVTitleInfo[i].Replace(strWithoutLCarVin, strCarID); - // } - // sb.Append(listCSVTitleInfo[i]); - // sb.AppendLine(); - //} - //sb.AppendLine(); - //sb.AppendLine(); - //sb.AppendLine(); - //sb.AppendLine(); - //sb.AppendLine(); - ////添加测量数据 - //sb.Append("Characteristic"); - //sb.Append(","); - //sb.Append("Extension"); - //sb.Append(","); - //sb.Append("Measured_Value"); - //sb.AppendLine(); - //foreach (DataRow row in dtCSVContent.Rows) - //{ - // sb.Append(row.ItemArray[2]); - // sb.Append(","); - // sb.Append(row.ItemArray[3]); - // sb.Append(","); - // sb.Append(row.ItemArray[7]); - // sb.AppendLine(); - //} + // 这里可以更新界面控件,例如 ListBox、Label 等 + // 例如:listBoxParsedFiles.Items.Add(fileName); + // 或 rleMessage.Text = $"已解析: {fileName}"; + rleMessage.Text = $"已解析: {strCarID}"; + + + // 显示数据, 此时为左侧或右侧数据 + DisplayMeasureData(strCarID); - //sb.Append("POP"); - //sb.Append(","); - //sb.Append("P"); - //sb.Append(","); - //sb.Append(Math.Round(FPYPercent * 100.00d, 2).ToString("F2")); - //sb.AppendLine(); - //// 将数据写入CSV文件 - //File.WriteAllText(filePath, sb.ToString()); - //MyBase.TraceWriteLine("客户csv报告生成完毕,路径为:" + filePath); - //#endregion 解析完报告后,重新生成客户模板报告 } + /// 通过给定的文件流,判断文件的编码类型 /// 文件流 /// 文件的编码类型 @@ -735,9 +516,6 @@ namespace NSAnalysis #region datagridview分页功能 - /// - /// LoadPage方法 - /// private void LoadPage() { if (currentPage < 1) currentPage = 1; diff --git a/Analysis/FormMain.designer.cs b/Analysis/FormMain.designer.cs index a4adde1..801a313 100644 --- a/Analysis/FormMain.designer.cs +++ b/Analysis/FormMain.designer.cs @@ -52,8 +52,6 @@ namespace NSAnalysis System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle7 = new System.Windows.Forms.DataGridViewCellStyle(); System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle8 = new System.Windows.Forms.DataGridViewCellStyle(); System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle9 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle10 = new System.Windows.Forms.DataGridViewCellStyle(); - System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle11 = new System.Windows.Forms.DataGridViewCellStyle(); this.radTitleBar1 = new Telerik.WinControls.UI.RadTitleBar(); this.label2 = new System.Windows.Forms.Label(); this.labTitle = new System.Windows.Forms.Label(); @@ -72,6 +70,14 @@ namespace NSAnalysis this.label4 = new System.Windows.Forms.Label(); this.lbCSVFiles = new System.Windows.Forms.ListBox(); this.dgvMeasureContent = new System.Windows.Forms.DataGridView(); + this.PointName = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.DimensionName = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.NormalVal = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.LowerTolVal = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.UpperTolVal = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.MeasureValue = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.MeasureDateTime = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.Classification = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.splitContainer2 = new System.Windows.Forms.SplitContainer(); this.labCarType = new System.Windows.Forms.Label(); this.label24 = new System.Windows.Forms.Label(); @@ -117,6 +123,15 @@ namespace NSAnalysis this.radLabel11 = new Telerik.WinControls.UI.RadLabel(); this.chartFPYLine = new System.Windows.Forms.DataVisualization.Charting.Chart(); this.dgvSelectMeasureData = new System.Windows.Forms.DataGridView(); + this.Column2 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.dataGridViewTextBoxColumn2 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.dataGridViewTextBoxColumn3 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.dataGridViewTextBoxColumn4 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.dataGridViewTextBoxColumn5 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.dataGridViewTextBoxColumn6 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.dataGridViewTextBoxColumn7 = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.MeasureItemResult = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.dgvFPYResult = new System.Windows.Forms.DataGridView(); this.dataGridViewTextBoxColumn9 = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.dataGridViewTextBoxColumn10 = new System.Windows.Forms.DataGridViewTextBoxColumn(); @@ -127,30 +142,12 @@ namespace NSAnalysis this.dataGridViewTextBoxColumn16 = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.SMResult = new System.Windows.Forms.DataGridViewTextBoxColumn(); this.rpvpSetup = new Telerik.WinControls.UI.RadPageViewPage(); - this.tmSystem = new System.Windows.Forms.Timer(this.components); - this.tmReadNextsenseCSV = new System.Windows.Forms.Timer(this.components); - this.tmrMonitorDBToCreateReport = new System.Windows.Forms.Timer(this.components); this.lpcToleranceSetup = new UserControlClass.LabPictureControl(); this.lpcShowLog = new UserControlClass.LabPictureControl(); this.lpcSoftwareSetup = new UserControlClass.LabPictureControl(); this.lpcAboutSoftware = new UserControlClass.LabPictureControl(); - this.PointName = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.DimensionName = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.NormalVal = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.LowerTolVal = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.UpperTolVal = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.MeasureValue = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.MeasureDateTime = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.Classification = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.Column2 = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.dataGridViewTextBoxColumn2 = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.dataGridViewTextBoxColumn3 = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.dataGridViewTextBoxColumn4 = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.dataGridViewTextBoxColumn5 = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.dataGridViewTextBoxColumn6 = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.dataGridViewTextBoxColumn7 = new System.Windows.Forms.DataGridViewTextBoxColumn(); - this.MeasureItemResult = new System.Windows.Forms.DataGridViewTextBoxColumn(); + this.tmSystem = new System.Windows.Forms.Timer(this.components); + this.tmrMonitorDBToCreateReport = new System.Windows.Forms.Timer(this.components); ((System.ComponentModel.ISupportInitialize)(this.radTitleBar1)).BeginInit(); this.radTitleBar1.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.radStatusStrip1)).BeginInit(); @@ -352,9 +349,9 @@ namespace NSAnalysis this.RPV.DefaultPage = this.rpvpAnalysis; this.RPV.Font = new System.Drawing.Font("微软雅黑", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); this.RPV.ItemSizeMode = ((Telerik.WinControls.UI.PageViewItemSizeMode)((Telerik.WinControls.UI.PageViewItemSizeMode.EqualWidth | Telerik.WinControls.UI.PageViewItemSizeMode.EqualHeight))); - this.RPV.Location = new System.Drawing.Point(1, 42); + this.RPV.Location = new System.Drawing.Point(1, 38); this.RPV.Name = "RPV"; - this.RPV.SelectedPage = this.rpvpSearch; + this.RPV.SelectedPage = this.rpvpAnalysis; this.RPV.Size = new System.Drawing.Size(1918, 1008); this.RPV.TabIndex = 127; this.RPV.ViewMode = Telerik.WinControls.UI.PageViewMode.NavigationView; @@ -437,7 +434,7 @@ namespace NSAnalysis ((Telerik.WinControls.UI.NavigationViewHeaderElement)(this.RPV.GetChildAt(0).GetChildAt(2))).BackColor3 = System.Drawing.Color.FromArgb(((int)(((byte)(45)))), ((int)(((byte)(135)))), ((int)(((byte)(161))))); ((Telerik.WinControls.UI.NavigationViewHeaderElement)(this.RPV.GetChildAt(0).GetChildAt(2))).BackColor4 = System.Drawing.Color.FromArgb(((int)(((byte)(45)))), ((int)(((byte)(135)))), ((int)(((byte)(161))))); ((Telerik.WinControls.UI.NavigationViewHeaderElement)(this.RPV.GetChildAt(0).GetChildAt(2))).HorizontalLineColor = System.Drawing.Color.FromArgb(((int)(((byte)(19)))), ((int)(((byte)(46)))), ((int)(((byte)(53))))); - ((Telerik.WinControls.UI.NavigationViewHeaderElement)(this.RPV.GetChildAt(0).GetChildAt(2))).Text = " 查询界面"; + ((Telerik.WinControls.UI.NavigationViewHeaderElement)(this.RPV.GetChildAt(0).GetChildAt(2))).Text = " 分析主界面"; ((Telerik.WinControls.UI.NavigationViewHeaderElement)(this.RPV.GetChildAt(0).GetChildAt(2))).FocusBorderColor = System.Drawing.Color.FromArgb(((int)(((byte)(45)))), ((int)(((byte)(135)))), ((int)(((byte)(161))))); ((Telerik.WinControls.UI.NavigationViewHeaderElement)(this.RPV.GetChildAt(0).GetChildAt(2))).ForeColor = System.Drawing.Color.White; ((Telerik.WinControls.UI.NavigationViewHeaderElement)(this.RPV.GetChildAt(0).GetChildAt(2))).BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(27)))), ((int)(((byte)(60)))), ((int)(((byte)(68))))); @@ -479,7 +476,7 @@ namespace NSAnalysis this.rpvpAnalysis.Controls.Add(this.splitContainer1); this.rpvpAnalysis.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.rpvpAnalysis.Image = ((System.Drawing.Image)(resources.GetObject("rpvpAnalysis.Image"))); - this.rpvpAnalysis.ItemSize = new System.Drawing.SizeF(162F, 40F); + this.rpvpAnalysis.ItemSize = new System.Drawing.SizeF(46F, 46F); this.rpvpAnalysis.Location = new System.Drawing.Point(49, 35); this.rpvpAnalysis.Name = "rpvpAnalysis"; this.rpvpAnalysis.Size = new System.Drawing.Size(1868, 972); @@ -528,7 +525,7 @@ namespace NSAnalysis this.lbCSVFiles.ItemHeight = 19; this.lbCSVFiles.Location = new System.Drawing.Point(19, 39); this.lbCSVFiles.Name = "lbCSVFiles"; - this.lbCSVFiles.Size = new System.Drawing.Size(1084, 59); + this.lbCSVFiles.Size = new System.Drawing.Size(1084, 173); this.lbCSVFiles.TabIndex = 174; // // dgvMeasureContent @@ -561,7 +558,7 @@ namespace NSAnalysis this.Classification}); this.dgvMeasureContent.EnableHeadersVisualStyles = false; this.dgvMeasureContent.GridColor = System.Drawing.Color.FromArgb(((int)(((byte)(100)))), ((int)(((byte)(181)))), ((int)(((byte)(200))))); - this.dgvMeasureContent.Location = new System.Drawing.Point(21, 104); + this.dgvMeasureContent.Location = new System.Drawing.Point(21, 232); this.dgvMeasureContent.Name = "dgvMeasureContent"; this.dgvMeasureContent.ReadOnly = true; this.dgvMeasureContent.RowHeadersBorderStyle = System.Windows.Forms.DataGridViewHeaderBorderStyle.Single; @@ -581,9 +578,76 @@ namespace NSAnalysis this.dgvMeasureContent.RowsDefaultCellStyle = dataGridViewCellStyle3; this.dgvMeasureContent.RowTemplate.DefaultCellStyle.Font = new System.Drawing.Font("Segoe UI", 10F); this.dgvMeasureContent.RowTemplate.Height = 38; - this.dgvMeasureContent.Size = new System.Drawing.Size(1082, 846); + this.dgvMeasureContent.Size = new System.Drawing.Size(1082, 718); this.dgvMeasureContent.TabIndex = 173; // + // PointName + // + this.PointName.DataPropertyName = "PointName"; + this.PointName.HeaderText = "测量点名称"; + this.PointName.Name = "PointName"; + this.PointName.ReadOnly = true; + this.PointName.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; + this.PointName.Width = 150; + // + // DimensionName + // + this.DimensionName.DataPropertyName = "DimensionName"; + this.DimensionName.HeaderText = "尺寸名"; + this.DimensionName.Name = "DimensionName"; + this.DimensionName.ReadOnly = true; + this.DimensionName.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; + this.DimensionName.Width = 80; + // + // NormalVal + // + this.NormalVal.DataPropertyName = "NominalValue"; + this.NormalVal.HeaderText = "理论值"; + this.NormalVal.Name = "NormalVal"; + this.NormalVal.ReadOnly = true; + this.NormalVal.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; + this.NormalVal.Visible = false; + // + // LowerTolVal + // + this.LowerTolVal.DataPropertyName = "LowerLimit"; + this.LowerTolVal.HeaderText = "下限值"; + this.LowerTolVal.Name = "LowerTolVal"; + this.LowerTolVal.ReadOnly = true; + this.LowerTolVal.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; + // + // UpperTolVal + // + this.UpperTolVal.DataPropertyName = "UpperLimit"; + this.UpperTolVal.HeaderText = "上限值"; + this.UpperTolVal.Name = "UpperTolVal"; + this.UpperTolVal.ReadOnly = true; + this.UpperTolVal.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; + // + // MeasureValue + // + this.MeasureValue.DataPropertyName = "DimensionValue"; + this.MeasureValue.HeaderText = "实测值"; + this.MeasureValue.Name = "MeasureValue"; + this.MeasureValue.ReadOnly = true; + this.MeasureValue.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; + // + // MeasureDateTime + // + this.MeasureDateTime.DataPropertyName = "MeasureDateTime"; + this.MeasureDateTime.HeaderText = "测量时间"; + this.MeasureDateTime.Name = "MeasureDateTime"; + this.MeasureDateTime.ReadOnly = true; + this.MeasureDateTime.Width = 190; + // + // Classification + // + this.Classification.DataPropertyName = "Classification"; + this.Classification.HeaderText = "结果"; + this.Classification.Name = "Classification"; + this.Classification.ReadOnly = true; + this.Classification.Width = 150; + // // splitContainer2 // this.splitContainer2.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; @@ -878,7 +942,7 @@ namespace NSAnalysis this.rpvpSearch.Controls.Add(this.dgvSelectMeasureData); this.rpvpSearch.Controls.Add(this.dgvFPYResult); this.rpvpSearch.Image = ((System.Drawing.Image)(resources.GetObject("rpvpSearch.Image"))); - this.rpvpSearch.ItemSize = new System.Drawing.SizeF(162F, 40F); + this.rpvpSearch.ItemSize = new System.Drawing.SizeF(46F, 46F); this.rpvpSearch.Location = new System.Drawing.Point(49, 35); this.rpvpSearch.Name = "rpvpSearch"; this.rpvpSearch.Size = new System.Drawing.Size(1868, 972); @@ -1527,39 +1591,105 @@ namespace NSAnalysis this.dataGridViewTextBoxColumn6, this.dataGridViewTextBoxColumn7, this.MeasureItemResult}); - dataGridViewCellStyle5.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; - dataGridViewCellStyle5.BackColor = System.Drawing.SystemColors.Window; - dataGridViewCellStyle5.Font = new System.Drawing.Font("微软雅黑", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - dataGridViewCellStyle5.ForeColor = System.Drawing.Color.White; - dataGridViewCellStyle5.SelectionBackColor = System.Drawing.SystemColors.Highlight; - dataGridViewCellStyle5.SelectionForeColor = System.Drawing.SystemColors.HighlightText; - dataGridViewCellStyle5.WrapMode = System.Windows.Forms.DataGridViewTriState.False; - this.dgvSelectMeasureData.DefaultCellStyle = dataGridViewCellStyle5; this.dgvSelectMeasureData.EnableHeadersVisualStyles = false; this.dgvSelectMeasureData.GridColor = System.Drawing.Color.FromArgb(((int)(((byte)(100)))), ((int)(((byte)(181)))), ((int)(((byte)(200))))); this.dgvSelectMeasureData.Location = new System.Drawing.Point(30, 126); this.dgvSelectMeasureData.Name = "dgvSelectMeasureData"; this.dgvSelectMeasureData.ReadOnly = true; this.dgvSelectMeasureData.RowHeadersBorderStyle = System.Windows.Forms.DataGridViewHeaderBorderStyle.Single; - dataGridViewCellStyle6.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; + dataGridViewCellStyle5.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; + dataGridViewCellStyle5.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(27)))), ((int)(((byte)(60)))), ((int)(((byte)(68))))); + dataGridViewCellStyle5.Font = new System.Drawing.Font("微软雅黑", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + dataGridViewCellStyle5.ForeColor = System.Drawing.Color.White; + dataGridViewCellStyle5.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(151)))), ((int)(((byte)(186))))); + dataGridViewCellStyle5.SelectionForeColor = System.Drawing.SystemColors.HighlightText; + dataGridViewCellStyle5.WrapMode = System.Windows.Forms.DataGridViewTriState.True; + this.dgvSelectMeasureData.RowHeadersDefaultCellStyle = dataGridViewCellStyle5; + this.dgvSelectMeasureData.RowHeadersWidthSizeMode = System.Windows.Forms.DataGridViewRowHeadersWidthSizeMode.AutoSizeToAllHeaders; dataGridViewCellStyle6.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(27)))), ((int)(((byte)(60)))), ((int)(((byte)(68))))); - dataGridViewCellStyle6.Font = new System.Drawing.Font("微软雅黑", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + dataGridViewCellStyle6.Font = new System.Drawing.Font("微软雅黑", 10F); dataGridViewCellStyle6.ForeColor = System.Drawing.Color.White; dataGridViewCellStyle6.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(151)))), ((int)(((byte)(186))))); - dataGridViewCellStyle6.SelectionForeColor = System.Drawing.SystemColors.HighlightText; - dataGridViewCellStyle6.WrapMode = System.Windows.Forms.DataGridViewTriState.True; - this.dgvSelectMeasureData.RowHeadersDefaultCellStyle = dataGridViewCellStyle6; - this.dgvSelectMeasureData.RowHeadersWidthSizeMode = System.Windows.Forms.DataGridViewRowHeadersWidthSizeMode.AutoSizeToAllHeaders; - dataGridViewCellStyle7.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(27)))), ((int)(((byte)(60)))), ((int)(((byte)(68))))); - dataGridViewCellStyle7.Font = new System.Drawing.Font("微软雅黑", 10F); - dataGridViewCellStyle7.ForeColor = System.Drawing.Color.White; - dataGridViewCellStyle7.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(151)))), ((int)(((byte)(186))))); - this.dgvSelectMeasureData.RowsDefaultCellStyle = dataGridViewCellStyle7; + this.dgvSelectMeasureData.RowsDefaultCellStyle = dataGridViewCellStyle6; this.dgvSelectMeasureData.RowTemplate.Height = 37; this.dgvSelectMeasureData.Size = new System.Drawing.Size(1204, 805); this.dgvSelectMeasureData.TabIndex = 174; this.dgvSelectMeasureData.RowStateChanged += new System.Windows.Forms.DataGridViewRowStateChangedEventHandler(this.dgvSelectMeasureData_RowStateChanged); // + // Column2 + // + this.Column2.DataPropertyName = "ProductNum"; + this.Column2.HeaderText = "车身编号"; + this.Column2.Name = "Column2"; + this.Column2.ReadOnly = true; + this.Column2.Width = 170; + // + // dataGridViewTextBoxColumn1 + // + this.dataGridViewTextBoxColumn1.DataPropertyName = "PointName"; + this.dataGridViewTextBoxColumn1.HeaderText = "测量点名称"; + this.dataGridViewTextBoxColumn1.Name = "dataGridViewTextBoxColumn1"; + this.dataGridViewTextBoxColumn1.ReadOnly = true; + this.dataGridViewTextBoxColumn1.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; + this.dataGridViewTextBoxColumn1.Width = 150; + // + // dataGridViewTextBoxColumn2 + // + this.dataGridViewTextBoxColumn2.DataPropertyName = "DimensionName"; + this.dataGridViewTextBoxColumn2.HeaderText = "尺寸名"; + this.dataGridViewTextBoxColumn2.Name = "dataGridViewTextBoxColumn2"; + this.dataGridViewTextBoxColumn2.ReadOnly = true; + this.dataGridViewTextBoxColumn2.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; + this.dataGridViewTextBoxColumn2.Width = 80; + // + // dataGridViewTextBoxColumn3 + // + this.dataGridViewTextBoxColumn3.DataPropertyName = "NominalValue"; + this.dataGridViewTextBoxColumn3.HeaderText = "理论值"; + this.dataGridViewTextBoxColumn3.Name = "dataGridViewTextBoxColumn3"; + this.dataGridViewTextBoxColumn3.ReadOnly = true; + this.dataGridViewTextBoxColumn3.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; + // + // dataGridViewTextBoxColumn4 + // + this.dataGridViewTextBoxColumn4.DataPropertyName = "LowerLimit"; + this.dataGridViewTextBoxColumn4.HeaderText = "下公差"; + this.dataGridViewTextBoxColumn4.Name = "dataGridViewTextBoxColumn4"; + this.dataGridViewTextBoxColumn4.ReadOnly = true; + this.dataGridViewTextBoxColumn4.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; + // + // dataGridViewTextBoxColumn5 + // + this.dataGridViewTextBoxColumn5.DataPropertyName = "UpperLimit"; + this.dataGridViewTextBoxColumn5.HeaderText = "上公差"; + this.dataGridViewTextBoxColumn5.Name = "dataGridViewTextBoxColumn5"; + this.dataGridViewTextBoxColumn5.ReadOnly = true; + this.dataGridViewTextBoxColumn5.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; + // + // dataGridViewTextBoxColumn6 + // + this.dataGridViewTextBoxColumn6.DataPropertyName = "DimensionValue"; + this.dataGridViewTextBoxColumn6.HeaderText = "实测值"; + this.dataGridViewTextBoxColumn6.Name = "dataGridViewTextBoxColumn6"; + this.dataGridViewTextBoxColumn6.ReadOnly = true; + this.dataGridViewTextBoxColumn6.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; + // + // dataGridViewTextBoxColumn7 + // + this.dataGridViewTextBoxColumn7.DataPropertyName = "MeasureDateTime"; + this.dataGridViewTextBoxColumn7.HeaderText = "测量时间"; + this.dataGridViewTextBoxColumn7.Name = "dataGridViewTextBoxColumn7"; + this.dataGridViewTextBoxColumn7.ReadOnly = true; + this.dataGridViewTextBoxColumn7.Width = 190; + // + // MeasureItemResult + // + this.MeasureItemResult.DataPropertyName = "Classification"; + this.MeasureItemResult.HeaderText = "结果"; + this.MeasureItemResult.Name = "MeasureItemResult"; + this.MeasureItemResult.ReadOnly = true; + this.MeasureItemResult.Width = 120; + // // dgvFPYResult // this.dgvFPYResult.AllowUserToAddRows = false; @@ -1570,14 +1700,14 @@ namespace NSAnalysis this.dgvFPYResult.BackgroundColor = System.Drawing.Color.FromArgb(((int)(((byte)(27)))), ((int)(((byte)(60)))), ((int)(((byte)(68))))); this.dgvFPYResult.BorderStyle = System.Windows.Forms.BorderStyle.None; this.dgvFPYResult.ColumnHeadersBorderStyle = System.Windows.Forms.DataGridViewHeaderBorderStyle.Single; - dataGridViewCellStyle8.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; - dataGridViewCellStyle8.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(27)))), ((int)(((byte)(60)))), ((int)(((byte)(68))))); - dataGridViewCellStyle8.Font = new System.Drawing.Font("微软雅黑", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - dataGridViewCellStyle8.ForeColor = System.Drawing.Color.White; - dataGridViewCellStyle8.SelectionBackColor = System.Drawing.SystemColors.Highlight; - dataGridViewCellStyle8.SelectionForeColor = System.Drawing.SystemColors.HighlightText; - dataGridViewCellStyle8.WrapMode = System.Windows.Forms.DataGridViewTriState.True; - this.dgvFPYResult.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle8; + dataGridViewCellStyle7.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; + dataGridViewCellStyle7.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(27)))), ((int)(((byte)(60)))), ((int)(((byte)(68))))); + dataGridViewCellStyle7.Font = new System.Drawing.Font("微软雅黑", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + dataGridViewCellStyle7.ForeColor = System.Drawing.Color.White; + dataGridViewCellStyle7.SelectionBackColor = System.Drawing.SystemColors.Highlight; + dataGridViewCellStyle7.SelectionForeColor = System.Drawing.SystemColors.HighlightText; + dataGridViewCellStyle7.WrapMode = System.Windows.Forms.DataGridViewTriState.True; + this.dgvFPYResult.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle7; this.dgvFPYResult.ColumnHeadersHeight = 37; this.dgvFPYResult.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] { this.dataGridViewTextBoxColumn9, @@ -1588,34 +1718,26 @@ namespace NSAnalysis this.dataGridViewTextBoxColumn14, this.dataGridViewTextBoxColumn16, this.SMResult}); - dataGridViewCellStyle9.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; - dataGridViewCellStyle9.BackColor = System.Drawing.SystemColors.Window; - dataGridViewCellStyle9.Font = new System.Drawing.Font("微软雅黑", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - dataGridViewCellStyle9.ForeColor = System.Drawing.Color.White; - dataGridViewCellStyle9.SelectionBackColor = System.Drawing.SystemColors.Highlight; - dataGridViewCellStyle9.SelectionForeColor = System.Drawing.SystemColors.HighlightText; - dataGridViewCellStyle9.WrapMode = System.Windows.Forms.DataGridViewTriState.False; - this.dgvFPYResult.DefaultCellStyle = dataGridViewCellStyle9; this.dgvFPYResult.EnableHeadersVisualStyles = false; this.dgvFPYResult.GridColor = System.Drawing.Color.FromArgb(((int)(((byte)(100)))), ((int)(((byte)(181)))), ((int)(((byte)(200))))); this.dgvFPYResult.Location = new System.Drawing.Point(29, 126); this.dgvFPYResult.Name = "dgvFPYResult"; this.dgvFPYResult.ReadOnly = true; this.dgvFPYResult.RowHeadersBorderStyle = System.Windows.Forms.DataGridViewHeaderBorderStyle.Single; - dataGridViewCellStyle10.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; - dataGridViewCellStyle10.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(27)))), ((int)(((byte)(60)))), ((int)(((byte)(68))))); - dataGridViewCellStyle10.Font = new System.Drawing.Font("微软雅黑", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); - dataGridViewCellStyle10.ForeColor = System.Drawing.Color.White; - dataGridViewCellStyle10.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(151)))), ((int)(((byte)(186))))); - dataGridViewCellStyle10.SelectionForeColor = System.Drawing.SystemColors.HighlightText; - dataGridViewCellStyle10.WrapMode = System.Windows.Forms.DataGridViewTriState.True; - this.dgvFPYResult.RowHeadersDefaultCellStyle = dataGridViewCellStyle10; + dataGridViewCellStyle8.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft; + dataGridViewCellStyle8.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(27)))), ((int)(((byte)(60)))), ((int)(((byte)(68))))); + dataGridViewCellStyle8.Font = new System.Drawing.Font("微软雅黑", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(134))); + dataGridViewCellStyle8.ForeColor = System.Drawing.Color.White; + dataGridViewCellStyle8.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(151)))), ((int)(((byte)(186))))); + dataGridViewCellStyle8.SelectionForeColor = System.Drawing.SystemColors.HighlightText; + dataGridViewCellStyle8.WrapMode = System.Windows.Forms.DataGridViewTriState.True; + this.dgvFPYResult.RowHeadersDefaultCellStyle = dataGridViewCellStyle8; this.dgvFPYResult.RowHeadersWidthSizeMode = System.Windows.Forms.DataGridViewRowHeadersWidthSizeMode.AutoSizeToAllHeaders; - dataGridViewCellStyle11.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(27)))), ((int)(((byte)(60)))), ((int)(((byte)(68))))); - dataGridViewCellStyle11.Font = new System.Drawing.Font("微软雅黑", 10F); - dataGridViewCellStyle11.ForeColor = System.Drawing.Color.White; - dataGridViewCellStyle11.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(151)))), ((int)(((byte)(186))))); - this.dgvFPYResult.RowsDefaultCellStyle = dataGridViewCellStyle11; + dataGridViewCellStyle9.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(27)))), ((int)(((byte)(60)))), ((int)(((byte)(68))))); + dataGridViewCellStyle9.Font = new System.Drawing.Font("微软雅黑", 10F); + dataGridViewCellStyle9.ForeColor = System.Drawing.Color.White; + dataGridViewCellStyle9.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(151)))), ((int)(((byte)(186))))); + this.dgvFPYResult.RowsDefaultCellStyle = dataGridViewCellStyle9; this.dgvFPYResult.RowTemplate.Height = 37; this.dgvFPYResult.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect; this.dgvFPYResult.Size = new System.Drawing.Size(1205, 798); @@ -1696,28 +1818,12 @@ namespace NSAnalysis this.rpvpSetup.Controls.Add(this.lpcAboutSoftware); this.rpvpSetup.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); this.rpvpSetup.Image = ((System.Drawing.Image)(resources.GetObject("rpvpSetup.Image"))); - this.rpvpSetup.ItemSize = new System.Drawing.SizeF(162F, 40F); + this.rpvpSetup.ItemSize = new System.Drawing.SizeF(46F, 46F); this.rpvpSetup.Location = new System.Drawing.Point(49, 35); this.rpvpSetup.Name = "rpvpSetup"; this.rpvpSetup.Size = new System.Drawing.Size(1868, 972); this.rpvpSetup.Text = " 软件设置"; // - // tmSystem - // - this.tmSystem.Enabled = true; - this.tmSystem.Interval = 1000; - this.tmSystem.Tick += new System.EventHandler(this.tmSystem_Tick); - // - // tmReadNextsenseCSV - // - this.tmReadNextsenseCSV.Interval = 300; - this.tmReadNextsenseCSV.Tick += new System.EventHandler(this.tmReadNextsenseCSV_Tick); - // - // tmrMonitorDBToCreateReport - // - this.tmrMonitorDBToCreateReport.Interval = 1000; - this.tmrMonitorDBToCreateReport.Tick += new System.EventHandler(this.tmrMonitorDBToCreateReport_Tick); - // // lpcToleranceSetup // this.lpcToleranceSetup.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(19)))), ((int)(((byte)(46)))), ((int)(((byte)(53))))); @@ -1777,146 +1883,16 @@ namespace NSAnalysis this.lpcAboutSoftware.TabIndex = 450; this.lpcAboutSoftware.Click += new System.EventHandler(this.lpcAboutSoftware_Click); // - // PointName + // tmSystem // - this.PointName.DataPropertyName = "PointName"; - this.PointName.HeaderText = "测量点名称"; - this.PointName.Name = "PointName"; - this.PointName.ReadOnly = true; - this.PointName.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; - this.PointName.Width = 150; + this.tmSystem.Enabled = true; + this.tmSystem.Interval = 1000; + this.tmSystem.Tick += new System.EventHandler(this.tmSystem_Tick); // - // DimensionName + // tmrMonitorDBToCreateReport // - this.DimensionName.DataPropertyName = "DimensionName"; - this.DimensionName.HeaderText = "尺寸名"; - this.DimensionName.Name = "DimensionName"; - this.DimensionName.ReadOnly = true; - this.DimensionName.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; - this.DimensionName.Width = 80; - // - // NormalVal - // - this.NormalVal.DataPropertyName = "NominalValue"; - this.NormalVal.HeaderText = "理论值"; - this.NormalVal.Name = "NormalVal"; - this.NormalVal.ReadOnly = true; - this.NormalVal.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; - this.NormalVal.Visible = false; - // - // LowerTolVal - // - this.LowerTolVal.DataPropertyName = "LowerLimit"; - this.LowerTolVal.HeaderText = "下限值"; - this.LowerTolVal.Name = "LowerTolVal"; - this.LowerTolVal.ReadOnly = true; - this.LowerTolVal.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; - // - // UpperTolVal - // - this.UpperTolVal.DataPropertyName = "UpperLimit"; - this.UpperTolVal.HeaderText = "上限值"; - this.UpperTolVal.Name = "UpperTolVal"; - this.UpperTolVal.ReadOnly = true; - this.UpperTolVal.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; - // - // MeasureValue - // - this.MeasureValue.DataPropertyName = "DimensionValue"; - this.MeasureValue.HeaderText = "实测值"; - this.MeasureValue.Name = "MeasureValue"; - this.MeasureValue.ReadOnly = true; - this.MeasureValue.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; - // - // MeasureDateTime - // - this.MeasureDateTime.DataPropertyName = "MeasureDateTime"; - this.MeasureDateTime.HeaderText = "测量时间"; - this.MeasureDateTime.Name = "MeasureDateTime"; - this.MeasureDateTime.ReadOnly = true; - this.MeasureDateTime.Width = 190; - // - // Classification - // - this.Classification.DataPropertyName = "Classification"; - this.Classification.HeaderText = "结果"; - this.Classification.Name = "Classification"; - this.Classification.ReadOnly = true; - this.Classification.Width = 150; - // - // Column2 - // - this.Column2.DataPropertyName = "ProductNum"; - this.Column2.HeaderText = "车身编号"; - this.Column2.Name = "Column2"; - this.Column2.ReadOnly = true; - this.Column2.Width = 170; - // - // dataGridViewTextBoxColumn1 - // - this.dataGridViewTextBoxColumn1.DataPropertyName = "PointName"; - this.dataGridViewTextBoxColumn1.HeaderText = "测量点名称"; - this.dataGridViewTextBoxColumn1.Name = "dataGridViewTextBoxColumn1"; - this.dataGridViewTextBoxColumn1.ReadOnly = true; - this.dataGridViewTextBoxColumn1.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; - this.dataGridViewTextBoxColumn1.Width = 150; - // - // dataGridViewTextBoxColumn2 - // - this.dataGridViewTextBoxColumn2.DataPropertyName = "DimensionName"; - this.dataGridViewTextBoxColumn2.HeaderText = "尺寸名"; - this.dataGridViewTextBoxColumn2.Name = "dataGridViewTextBoxColumn2"; - this.dataGridViewTextBoxColumn2.ReadOnly = true; - this.dataGridViewTextBoxColumn2.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; - this.dataGridViewTextBoxColumn2.Width = 80; - // - // dataGridViewTextBoxColumn3 - // - this.dataGridViewTextBoxColumn3.DataPropertyName = "NominalValue"; - this.dataGridViewTextBoxColumn3.HeaderText = "理论值"; - this.dataGridViewTextBoxColumn3.Name = "dataGridViewTextBoxColumn3"; - this.dataGridViewTextBoxColumn3.ReadOnly = true; - this.dataGridViewTextBoxColumn3.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; - // - // dataGridViewTextBoxColumn4 - // - this.dataGridViewTextBoxColumn4.DataPropertyName = "LowerLimit"; - this.dataGridViewTextBoxColumn4.HeaderText = "下公差"; - this.dataGridViewTextBoxColumn4.Name = "dataGridViewTextBoxColumn4"; - this.dataGridViewTextBoxColumn4.ReadOnly = true; - this.dataGridViewTextBoxColumn4.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; - // - // dataGridViewTextBoxColumn5 - // - this.dataGridViewTextBoxColumn5.DataPropertyName = "UpperLimit"; - this.dataGridViewTextBoxColumn5.HeaderText = "上公差"; - this.dataGridViewTextBoxColumn5.Name = "dataGridViewTextBoxColumn5"; - this.dataGridViewTextBoxColumn5.ReadOnly = true; - this.dataGridViewTextBoxColumn5.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; - // - // dataGridViewTextBoxColumn6 - // - this.dataGridViewTextBoxColumn6.DataPropertyName = "DimensionValue"; - this.dataGridViewTextBoxColumn6.HeaderText = "实测值"; - this.dataGridViewTextBoxColumn6.Name = "dataGridViewTextBoxColumn6"; - this.dataGridViewTextBoxColumn6.ReadOnly = true; - this.dataGridViewTextBoxColumn6.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable; - // - // dataGridViewTextBoxColumn7 - // - this.dataGridViewTextBoxColumn7.DataPropertyName = "MeasureDateTime"; - this.dataGridViewTextBoxColumn7.HeaderText = "测量时间"; - this.dataGridViewTextBoxColumn7.Name = "dataGridViewTextBoxColumn7"; - this.dataGridViewTextBoxColumn7.ReadOnly = true; - this.dataGridViewTextBoxColumn7.Width = 190; - // - // MeasureItemResult - // - this.MeasureItemResult.DataPropertyName = "Classification"; - this.MeasureItemResult.HeaderText = "结果"; - this.MeasureItemResult.Name = "MeasureItemResult"; - this.MeasureItemResult.ReadOnly = true; - this.MeasureItemResult.Width = 120; + this.tmrMonitorDBToCreateReport.Interval = 1000; + this.tmrMonitorDBToCreateReport.Tick += new System.EventHandler(this.tmrMonitorDBToCreateReport_Tick); // // FormMain // @@ -2032,7 +2008,6 @@ namespace NSAnalysis private Telerik.WinControls.UI.RadButton rbtnExportCSVReport; private System.Windows.Forms.DataVisualization.Charting.Chart chartFPYLine; private System.Windows.Forms.Timer tmSystem; - private System.Windows.Forms.Timer tmReadNextsenseCSV; private System.Windows.Forms.PictureBox pbResult; private System.Windows.Forms.Label labRejectCount; private System.Windows.Forms.Label label7; diff --git a/Analysis/FormMain.resx b/Analysis/FormMain.resx index b33b31b..7878e21 100644 --- a/Analysis/FormMain.resx +++ b/Analysis/FormMain.resx @@ -296,14 +296,11 @@ 17, 17 - - 127, 14 - - 310, 14 + 128, 17 - 65 + 25 diff --git a/Analysis/Program.cs b/Analysis/Program.cs index e3f60ad..d2b8735 100644 --- a/Analysis/Program.cs +++ b/Analysis/Program.cs @@ -1,6 +1,6 @@ using BaseFunction; using Microsoft.Win32; -using NSAnalysis.BaseUnit; +using NSAnalysis; using System; using System.Diagnostics; using System.Runtime.InteropServices; diff --git a/Analysis/bin/x64/Debug/Debug.txt b/Analysis/bin/x64/Debug/Debug.txt index 1faa538..b236eea 100644 --- a/Analysis/bin/x64/Debug/Debug.txt +++ b/Analysis/bin/x64/Debug/Debug.txt @@ -1,22 +1,87 @@ -2025-08-11 15:03:04.024----软件Program Main函数开始执行-- -2025-08-11 15:03:04.031--加载配置文件——>开始 -2025-08-11 15:03:04.037--数据库连接 SqlServerName:127.0.0.1 -2025-08-11 15:03:04.038--数据库连接 SqlUserName:sa -2025-08-11 15:03:04.039--数据库连接 SqlPassword:Hexagon123 -2025-08-11 15:03:04.064--数据库连接 SqlDbName:CJLR -2025-08-11 15:03:04.065--加载配置文件——>完成 -2025-08-11 15:03:05.918--数据库连接 SqlServerName:127.0.0.1 -2025-08-11 15:03:05.919--数据库连接 SqlUserName:sa -2025-08-11 15:03:05.920--数据库连接 SqlPassword:Hexagon123 -2025-08-11 15:03:05.921--数据库连接 SqlDbName:CJLR -2025-08-11 15:03:05.922--数据库连接字符串:Data Source=127.0.0.1;initial Catalog=CJLR;User ID=sa;password=Hexagon123; -2025-08-11 15:03:06.206-- 进入解析CSV文件模式,开始解析扫码CSV文件! -2025-08-11 15:03:06.208--软件首次启动, Nextsense EH3 CSV读取路径存在;不清空,读取NextSense生成 CSV报告路径下的所有文件,路径为:D:\cherytestEH3 -2025-08-11 15:03:12.470--车身尺寸数据导出成功,路径为:C:\Users\zhengxuan.zhang\Desktop\车身尺寸数据20250811150310982.CSV -2025-08-11 15:03:26.159--合格率数据导出成功,路径为:C:\Users\zhengxuan.zhang\Desktop\合格率20250811150325109.CSV -2025-08-11 15:04:09.338--数据库连接 SqlServerName:127.0.0.1 -2025-08-11 15:04:09.340--数据库连接 SqlUserName:sa -2025-08-11 15:04:09.340--数据库连接 SqlPassword:Hexagon123 -2025-08-11 15:04:09.343--数据库连接 SqlDbName:CJLR -2025-08-11 15:04:09.343--数据库连接字符串:Data Source=127.0.0.1;initial Catalog=CJLR;User ID=sa;password=Hexagon123; -2025-08-11 15:04:24.311---------------海克斯康面隙分析软件程序关闭--------------------- +2025-08-18 14:16:02.926----软件Program Main函数开始执行-- +2025-08-18 14:16:02.927--加载配置文件——>开始 +2025-08-18 14:16:02.947--数据库连接 SqlServerName:127.0.0.1 +2025-08-18 14:16:02.948--数据库连接 SqlUserName:sa +2025-08-18 14:16:02.949--数据库连接 SqlPassword:Hexagon123 +2025-08-18 14:16:02.949--数据库连接 SqlDbName:CJLR +2025-08-18 14:16:02.950--加载配置文件——>完成 +2025-08-18 14:16:04.153--数据库连接 SqlServerName:127.0.0.1 +2025-08-18 14:16:04.154--数据库连接 SqlUserName:sa +2025-08-18 14:16:04.155--数据库连接 SqlPassword:Hexagon123 +2025-08-18 14:16:04.156--数据库连接 SqlDbName:CJLR +2025-08-18 14:16:04.157--数据库连接字符串:Data Source=127.0.0.1;initial Catalog=CJLR;User ID=sa;password=Hexagon123; +2025-08-18 14:16:14.507-- +2025-08-18 14:16:14.510-- +2025-08-18 14:16:14.510-- +2025-08-18 14:16:14.511-- +2025-08-18 14:16:14.512-- +2025-08-18 14:16:14.513-- +2025-08-18 14:16:14.514-- +2025-08-18 14:16:14.515-- +2025-08-18 14:16:14.516-- +2025-08-18 14:16:14.517-- +2025-08-18 14:16:14.517-- +2025-08-18 14:16:14.519-- +2025-08-18 14:16:14.520-- +2025-08-18 14:16:14.521-- +2025-08-18 14:16:14.522--Processing Task - Source: P:\, Target: K:\X260R, ModelCode: X260 Position: R +2025-08-18 14:16:14.524--[ProcessFiles] 源文件地址不存在或错误: P:\ +2025-08-18 14:16:14.528--Processing Task - Source: D:\CJLR\DATA\Input\LLL, Target: D:\CJLR\DATA\Output\X540L, ModelCode: X540 Position: L +2025-08-18 14:16:14.533--匹配文件特征符: X540_L +2025-08-18 14:16:14.536--正在处理文件 : D:\CJLR\DATA\Input\LLL\K1902905.csv +2025-08-18 14:16:14.540--第 35 行数据为0,跳过该行:,,,,,,,,,,,,,,,,,,,,, +2025-08-18 14:16:14.541--第 36 行数据为0,跳过该行:,,,,,,,,,,,,,,,,,,,,, +2025-08-18 14:16:14.542--第 37 行数据为0,跳过该行:,,,,,,,,,,,,,,,,,,,,, +2025-08-18 14:16:19.608---------------------------------------------------------- +2025-08-18 14:16:19.609--车号:K1902905 +2025-08-18 14:16:19.610--车型:MY20 +2025-08-18 14:16:19.611--测量时间:2020-05-04 12:16:16 +2025-08-18 14:16:19.871--CSV文件导入到数据库成功! +2025-08-18 14:16:19.872---------------------------------------------------------- +2025-08-18 14:16:19.879--正在查询车ID为:K1902905 的测量结果。 +2025-08-18 14:16:19.916--将总结果插入数据库完毕。 +2025-08-18 14:16:20.094--未匹配到文件: D:\CJLR\DATA\Input\LLL\K1902905.csv +2025-08-18 14:16:20.104--Processing Task - Source: O:\, Target: L:\X260L, ModelCode: X260 Position: L +2025-08-18 14:16:20.105--[ProcessFiles] 源文件地址不存在或错误: O:\ +2025-08-18 14:16:20.108--Processing Task - Source: O:\, Target: L:\X760L, ModelCode: X760 Position: L +2025-08-18 14:16:20.109--[ProcessFiles] 源文件地址不存在或错误: O:\ +2025-08-18 14:16:20.110--Processing Task - Source: P:\, Target: K:\X760R, ModelCode: X760 Position: R +2025-08-18 14:16:20.111--[ProcessFiles] 源文件地址不存在或错误: P:\ +2025-08-18 14:16:20.117--Processing Task - Source: P:\, Target: K:\L551R 21MY, ModelCode: L551_21MY Position: R +2025-08-18 14:16:20.118--[ProcessFiles] 源文件地址不存在或错误: P:\ +2025-08-18 14:16:20.121--Processing Task - Source: O:\, Target: L:\L551L 21MY, ModelCode: L551_21MY Position: L +2025-08-18 14:16:20.122--[ProcessFiles] 源文件地址不存在或错误: O:\ +2025-08-18 14:16:20.123--Processing Task - Source: O:\, Target: L:\X540L 20MY, ModelCode: X540_24MY Position: L +2025-08-18 14:16:20.124--[ProcessFiles] 源文件地址不存在或错误: O:\ +2025-08-18 14:16:20.126--Processing Task - Source: P:\, Target: K:\X540R 20MY, ModelCode: X540_24MY Position: R +2025-08-18 14:16:20.126--[ProcessFiles] 源文件地址不存在或错误: P:\ +2025-08-18 14:16:20.128--Processing Task - Source: O:\, Target: L:\X540L, ModelCode: X540_18MY Position: L +2025-08-18 14:16:20.129--[ProcessFiles] 源文件地址不存在或错误: O:\ +2025-08-18 14:16:20.130--Processing Task - Source: O:\, Target: L:\L550L, ModelCode: L550_23MY Position: L +2025-08-18 14:16:20.132--[ProcessFiles] 源文件地址不存在或错误: O:\ +2025-08-18 14:16:20.241--Processing Task - Source: P:\, Target: K:\X540R, ModelCode: X540_18MY Position: R +2025-08-18 14:16:20.243--[ProcessFiles] 源文件地址不存在或错误: P:\ +2025-08-18 14:16:20.249--Processing Task - Source: P:\, Target: K:\L550R, ModelCode: L550_23MY Position: R +2025-08-18 14:16:20.251--[ProcessFiles] 源文件地址不存在或错误: P:\ +2025-08-18 14:16:24.571-- +2025-08-18 14:16:24.573-- +2025-08-18 14:16:24.574-- +2025-08-18 14:16:24.575-- +2025-08-18 14:16:24.579-- +2025-08-18 14:16:24.580-- +2025-08-18 14:16:24.581-- +2025-08-18 14:16:24.582-- +2025-08-18 14:16:24.583-- +2025-08-18 14:16:24.584-- +2025-08-18 14:16:24.584-- +2025-08-18 14:16:24.585-- +2025-08-18 14:16:24.586-- +2025-08-18 14:16:24.586-- +2025-08-18 14:16:24.587--Processing Task - Source: P:\, Target: K:\X260R, ModelCode: X260 Position: R +2025-08-18 14:16:24.588--[ProcessFiles] 源文件地址不存在或错误: P:\ +2025-08-18 14:16:24.598--Processing Task - Source: D:\CJLR\DATA\Input\LLL, Target: D:\CJLR\DATA\Output\X540L, ModelCode: X540 Position: L +2025-08-18 14:16:24.599--匹配文件特征符: X540_L +2025-08-18 14:16:24.600--正在处理文件 : D:\CJLR\DATA\Input\LLL\K1902905.csv +2025-08-18 14:16:24.604--第 35 行数据为0,跳过该行:,,,,,,,,,,,,,,,,,,,,, +2025-08-18 14:16:24.605--第 36 行数据为0,跳过该行:,,,,,,,,,,,,,,,,,,,,, +2025-08-18 14:16:24.605--第 37 行数据为0,跳过该行:,,,,,,,,,,,,,,,,,,,,, diff --git a/Analysis/bin/x64/Debug/File/DebugFiles/Debug(2025.05.19 13-52-24 To 2025.05.19 13-52-34).txt b/Analysis/bin/x64/Debug/File/DebugFiles/Debug(2025.05.19 13-52-24 To 2025.05.19 13-52-34).txt deleted file mode 100644 index d69081c..0000000 --- a/Analysis/bin/x64/Debug/File/DebugFiles/Debug(2025.05.19 13-52-24 To 2025.05.19 13-52-34).txt +++ /dev/null @@ -1,15 +0,0 @@ -2025-05-19 13:52:25.230----软件Program Main函数开始执行-- -2025-05-19 13:52:25.232--加载配置文件——>开始 -2025-05-19 13:52:25.270--加载配置文件——>完成 -2025-05-19 13:52:27.769-- 进入显示车身模式!显示车身界面。 -2025-05-19 13:52:28.620--启动PLC写线程! -2025-05-19 13:52:28.623-- 进入解析CSV文件模式,开始解析扫码CSV文件! -2025-05-19 13:52:28.657--连接PLC.... -2025-05-19 13:52:28.659--软件首次启动, Nextsense EH3 CSV读取路径存在;不清空,读取NextSense生成 CSV报告路径下的所有文件,路径为:D:\cherytestEH3 -2025-05-19 13:52:28.660--软件首次启动, Nextsense EHY CSV读取路径存在;不清空,读取NextSense生成 CSV报告路径下的所有文件,路径为:D:\cherytestEHY -2025-05-19 13:52:29.711--Right EH3 UI Refresh tmrRefreshData (strVIN.Length==21):CarType:EHY ;VIN: LNNBBDEC8RDA23997 -2025-05-19 13:52:29.739--Right EHY UI Refresh tmrRefreshData (strVIN.Length==21):CarType:EHY ;VIN: LNNBBDEC8RDA23997 -2025-05-19 13:52:29.934--显示右侧EHY车身数据界面。 -2025-05-19 13:52:30.781--PLC S7连接失败。 -2025-05-19 13:52:30.784--连接PLC失败 -2025-05-19 13:52:34.968---------------海克斯康面隙分析软件程序关闭--------------------- diff --git a/Analysis/bin/x64/Debug/File/DebugFiles/Debug(2025.05.19 13-53-16 To 2025.05.19 13-53-43).txt b/Analysis/bin/x64/Debug/File/DebugFiles/Debug(2025.05.19 13-53-16 To 2025.05.19 13-53-43).txt deleted file mode 100644 index d5ac9bd..0000000 --- a/Analysis/bin/x64/Debug/File/DebugFiles/Debug(2025.05.19 13-53-16 To 2025.05.19 13-53-43).txt +++ /dev/null @@ -1,15 +0,0 @@ -2025-05-19 13:53:16.548----软件Program Main函数开始执行-- -2025-05-19 13:53:16.550--加载配置文件——>开始 -2025-05-19 13:53:16.569--加载配置文件——>完成 -2025-05-19 13:53:18.447-- 进入显示车身模式!显示车身界面。 -2025-05-19 13:53:18.887--启动PLC写线程! -2025-05-19 13:53:18.890-- 进入解析CSV文件模式,开始解析扫码CSV文件! -2025-05-19 13:53:18.914--软件首次启动, Nextsense EH3 CSV读取路径存在;不清空,读取NextSense生成 CSV报告路径下的所有文件,路径为:D:\cherytestEH3 -2025-05-19 13:53:18.915--连接PLC.... -2025-05-19 13:53:18.916--软件首次启动, Nextsense EHY CSV读取路径存在;不清空,读取NextSense生成 CSV报告路径下的所有文件,路径为:D:\cherytestEHY -2025-05-19 13:53:20.959--PLC S7连接失败。 -2025-05-19 13:53:39.351--连接PLC失败 -2025-05-19 13:53:39.805--Right EH3 UI Refresh tmrRefreshData (strVIN.Length==21):CarType:EHY ;VIN: LNNBBDEC8RDA23997 -2025-05-19 13:53:39.836--Right EHY UI Refresh tmrRefreshData (strVIN.Length==21):CarType:EHY ;VIN: LNNBBDEC8RDA23997 -2025-05-19 13:53:40.123--显示右侧EHY车身数据界面。 -2025-05-19 13:53:43.161---------------海克斯康面隙分析软件程序关闭--------------------- diff --git a/Analysis/bin/x64/Debug/File/DebugFiles/Debug(2025.08.04 11-42-25 To 2025.08.04 11-42-32).txt b/Analysis/bin/x64/Debug/File/DebugFiles/Debug(2025.08.04 11-42-25 To 2025.08.04 11-42-32).txt deleted file mode 100644 index fd49dd1..0000000 --- a/Analysis/bin/x64/Debug/File/DebugFiles/Debug(2025.08.04 11-42-25 To 2025.08.04 11-42-32).txt +++ /dev/null @@ -1,17 +0,0 @@ -2025-08-04 11:42:26.704----软件Program Main函数开始执行-- -2025-08-04 11:42:26.707--加载配置文件——>开始 -2025-08-04 11:42:26.727--数据库连接 SqlServerName:127.0.0.1 -2025-08-04 11:42:26.728--数据库连接 SqlUserName:sa -2025-08-04 11:42:26.729--数据库连接 SqlPassword:Hexagon123 -2025-08-04 11:42:26.729--数据库连接 SqlDbName:NextSenseStandardDB -2025-08-04 11:42:26.729--加载配置文件——>完成 -2025-08-04 11:42:28.483--数据库连接 SqlServerName:127.0.0.1 -2025-08-04 11:42:28.484--数据库连接 SqlUserName:sa -2025-08-04 11:42:28.485--数据库连接 SqlPassword:Hexagon123 -2025-08-04 11:42:28.486--数据库连接 SqlDbName:NextSenseStandardDB -2025-08-04 11:42:28.486--数据库连接字符串:Data Source=127.0.0.1;initial Catalog=NextSenseStandardDB;User ID=sa;password=Hexagon123; -2025-08-04 11:42:28.853-- 进入显示车身模式!显示车身界面。 -2025-08-04 11:42:28.854-- 进入解析CSV文件模式,开始解析扫码CSV文件! -2025-08-04 11:42:28.856--软件首次启动, Nextsense EH3 CSV读取路径存在;不清空,读取NextSense生成 CSV报告路径下的所有文件,路径为:D:\cherytestEH3 -2025-08-04 11:42:28.857--软件首次启动, Nextsense EHY CSV读取路径存在;不清空,读取NextSense生成 CSV报告路径下的所有文件,路径为:D:\cherytestEHY -2025-08-04 11:42:32.820---------------海克斯康面隙分析软件程序关闭--------------------- diff --git a/Analysis/bin/x64/Debug/NSAnalysis.exe b/Analysis/bin/x64/Debug/NSAnalysis.exe index 863c88a..93b3778 100644 Binary files a/Analysis/bin/x64/Debug/NSAnalysis.exe and b/Analysis/bin/x64/Debug/NSAnalysis.exe differ diff --git a/Analysis/bin/x64/Debug/NSAnalysis.pdb b/Analysis/bin/x64/Debug/NSAnalysis.pdb index 79bd2b0..33a1e80 100644 Binary files a/Analysis/bin/x64/Debug/NSAnalysis.pdb and b/Analysis/bin/x64/Debug/NSAnalysis.pdb differ