Browse Source

dev_报告插件,数据导出部分完成,节点一

zhangjiaxin 3 years ago
parent
commit
76b044f394

File diff suppressed because it is too large
+ 189 - 1747
OTSIncAReportApp/1-UI/OTSTemplateDesigner/Export_ReportTemplate.cs


+ 124 - 618
OTSIncAReportApp/1-UI/OTSTemplateDesigner/OTSReport_Export.cs

@@ -43,6 +43,7 @@ namespace OTSIncAReportApp
         public XmlConfigUtil xmlutil;
         public XmlConfigUtil xmlutil2;
         public MBSZClass m_mbszclass = null;
+        OTS_DEVReport DEVReport;
         /*public bool ReportExporting = false;*///判断报告是不在是在导出的过程中
 
         #endregion
@@ -109,6 +110,11 @@ namespace OTSIncAReportApp
             /// 颗粒列表信息
             /// </summary>
             public KLLBXX M_KLLBXX { get; set; }
+
+            /// <summary>
+            /// 夹杂物占比
+            /// </summary>
+            public JZWZB M_JZWZB { get; set; }
             #endregion
 
             #region 构造函数
@@ -124,6 +130,7 @@ namespace OTSIncAReportApp
                 M_SYXT.list_lbv_syxt_mblb = new List<string>();
                 M_SYXT.list_lbv_syxt_mblb_index = new List<int>();
                 M_KLLBXX = new KLLBXX();
+                M_JZWZB = new JZWZB();
                 M_KLLBXX.list_str_tb_lllb_sxys = new List<string>();
                 M_DZ = new DZ();
             }
@@ -446,6 +453,11 @@ namespace OTSIncAReportApp
                 /// </summary>
                 public bool b_ck_kllb_xsmk { get; set; }
 
+                /// <summary>
+                /// 颗粒列表 是否显示附加帧图模块
+                /// </summary>
+                public bool b_ck_kllb_fjzt { get; set; }
+
                 /// <summary>
                 /// 颗粒列表 计算方式 文本
                 /// </summary>
@@ -544,10 +556,23 @@ namespace OTSIncAReportApp
                 /// 颗粒列表 颗粒帧图表行中第二个可选字段 索引
                 /// </summary>
                 public int index_cb_kllb_chartSort_p2 { get; set; }
-             
+
             }
             #endregion
+            #region 夹杂物占比
+            public class JZWZB
+            {
+                /// <summary>
+                /// 夹杂物占比表
+                /// </summary>
+                public bool b_ck_surface { get; set; }
+                /// <summary>
+                /// 夹杂物占比图
+                /// </summary>
+                public bool b_ck_chart { get; set; }
+            }
 
+            #endregion
         }
         #endregion
 
@@ -698,6 +723,7 @@ namespace OTSIncAReportApp
             }
             //颗粒列表信息
             m_mbszclass.M_KLLBXX.b_ck_kllb_xsmk = Convert.ToBoolean(xmlutil2.Read("M_KLLBXX", "b_ck_kllb_xsmk"));    //是否显示模块
+            m_mbszclass.M_KLLBXX.b_ck_kllb_fjzt = Convert.ToBoolean(xmlutil2.Read("M_KLLBXX", "b_ck_kllb_fjzt"));    //是否显示帧图模块
             m_mbszclass.M_KLLBXX.index_cb_kllb_jsfs = Convert.ToInt32(xmlutil2.Read("M_KLLBXX", "index_cb_kllb_jsfs"));    //计算方式
             m_mbszclass.M_KLLBXX.index_cb_kllb_klfw = Convert.ToInt32(xmlutil2.Read("M_KLLBXX", "index_cb_kllb_klfw"));    //颗粒范围
             m_mbszclass.M_KLLBXX.int_tb_kllb_ylsx = Convert.ToInt32(xmlutil2.Read("M_KLLBXX", "int_tb_kllb_ylsx"));    //数量上限
@@ -734,7 +760,9 @@ namespace OTSIncAReportApp
             //m_mbszclass.M_KLLBXX.str_cb_kllb_chartSort_p3 = Convert.ToString(xmlutil2.Read("M_KLLBXX", "str_cb_kllb_chartSort_p3"));//帧图表列中第三个可选参数
             //m_mbszclass.M_KLLBXX.index_cb_kllb_chartSort_p3 = Convert.ToInt32(xmlutil2.Read("M_KLLBXX", "index_cb_kllb_chartSort_p3"));
 
-
+            //夹杂物占比
+            m_mbszclass.M_JZWZB.b_ck_surface = Convert.ToBoolean(xmlutil2.Read("M_JZWZB", "b_ck_surface"));//夹杂物占比表
+            m_mbszclass.M_JZWZB.b_ck_chart= Convert.ToBoolean(xmlutil2.Read("M_JZWZB", "b_ck_chart"));//夹杂物占比图
         }
         /// <summary>
         /// 从配置文件中读取报告模板路径
@@ -1106,45 +1134,8 @@ namespace OTSIncAReportApp
         /// </summary>
         private void OpenOTSINcAreportTemplateAPP()
         {
-            //----------------------------------
-            //共传4个参数
-            //参数1:是需要打开db数据库的路径
-            //参数2:是打开报表模板xml文件的路径
-            //参数3:是要执行查看报表的类型,输出主报表,还是输出颗粒列表
-            //参数4:判断测量结果是夹杂物还是清洁度
-            //参数5:是要执行查看报表的类型,输出主报表时,指定读取的标记帧图图像范围,如0-50,50-100,输出颗粒列表时无用
-            //----------------------------------
-            //Process[] processes = Process.GetProcesses();
-            //foreach (Process proc in processes)
-            //{
-            //    if (proc.ProcessName == "OTSIncAReportTemplate")
-            //    {
-            //        proc.Kill();-+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
-            //        proc.WaitForExit();
-            //        break;
-            //    }
-            //}
-            ProcessStartInfo process = new ProcessStartInfo();
-            process.FileName = "ReportTemplateExe\\OTSIncAReportTemplate.exe";//打开app的路径
-            string arg1 = m_strDBpath.Replace(" ", "^");//参数1,是需要打开db数据库的路径
-            string arg2 = tb_mblj.Text.Trim().Replace(" ", "^");//参数2,是模板文件的路径
-            string arg3 = "MainReport";//主体报表
-            string arg4 = "";
-
-            ResultFile resfile = m_ReportApp.m_rstDataMgr.ResultFilesList[m_ReportApp.m_rstDataMgr.GetWorkingResult()];
-            if (((Dictionary<string, object>)((Dictionary<string, object>)((Dictionary<string, object>)resfile.ResultInfo["Sample"])["Members"])["MsrParams"])["SysType"].ToString() == "0:IncA")
-            {
-                 arg4 = "inca";//打卡夹杂物报告
-            }
-            else
-            {
-                arg4 = "Cleanness";//打卡清洁度报告
-            }
-
-            string arg5 = "null";
-            process.Arguments = string.Format("{0} {1} {2} {3} {4}", arg1, arg2, arg3, arg4, arg5);  //多个参数用空格隔开
-            process.WindowStyle = ProcessWindowStyle.Normal;
-            Process.Start(process);
+            ReportPrintTool tool = new ReportPrintTool(DEVReport);
+            tool.ShowPreview();
         }
 
 
@@ -1190,6 +1181,11 @@ namespace OTSIncAReportApp
 
         private void btn_preview_Click(object sender, EventArgs e)
         {
+            
+            DEVReport = new OTS_DEVReport(this);
+            //DEVReport.Dispose();
+          
+
             //为防止重复打开报告后,显示数据库占用错误,先确保报告模板进程已关闭
             Process[] processes = Process.GetProcesses();
             foreach (Process proc in processes)
@@ -1227,6 +1223,11 @@ namespace OTSIncAReportApp
                     return;
                 }
             }
+            
+            //frmReportConditionChoose frm = new frmReportConditionChoose(m_ReportApp);
+            //frm.ShowDataDiagram(DisplayPicutureType.AnalyzeDataChart);
+            
+
             m_ReportApp.m_rstDataMgr.setSelectedIndex(cbo_sjy.SelectedIndex);
             
             //重新导出报表数据
@@ -1321,523 +1322,7 @@ namespace OTSIncAReportApp
         }
 
         #endregion
-
-        
-
-        #region 将报表数据保存到数据库中
-        /// <summary>
-        /// 将报表数据保存到数据库中
-        /// </summary>
-        private void SaveReportTemplateDBFile()
-        {
-            File.Delete(m_strDBpath);//测试时删除数据库文件,为防止第二次打开报告提示数据库占用,挪到方法开始处
-            SqlHelper.CreateNewDatabase(m_strDBpath);
-            SqlHelper sh = new SqlHelper("data source='" + m_strDBpath + "'");
-
-            //开始事务
-            SQLiteTransaction tr = sh.BeginTranscation();
-
-            //数据库过程
-            //try
-            //{
-                //创建表 ResultGrid
-                string[] strcolumns_ResultGrid = { "CLJGMC", "YXSJ", "SCZS", "FLFA", "YJCTZ", "SCMJ", "CKBZ" , "FDBS" };
-                string[] strcoltypes_ResultGrid = { "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT" , "TEXT" };
-
-
-                //创建表 Largest_frame
-                string[] strcolumns_Largest_frame = { "pid", "Size", "Width","DMAX","DMIN", "Class", "ColName1", "ColName2", "ColName3", "ColName4", "ColName5", "ColName6",
-                "ColVal1", "ColVal2", "ColVal3", "ColVal4", "ColVal5", "ColVal6" ,"FieldId","p1"};
-                string[] strcoltypes_Largest_frame = { "TEXT", "TEXT", "TEXT", "TEXT","TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT" ,
-            "INT","BLOB"};
-                
-
-                //创建表 Largest20
-                string[] strcolumns_Largest20 = { "pid", "Size", "Width","DMAX","DMIN", "Class", "ColName1", "ColName2", "ColName3", "ColName4", "ColName5", "ColName6",
-                "ColVal1", "ColVal2", "ColVal3", "ColVal4", "ColVal5", "ColVal6" ,"p1" ,"p2" ,"p3"};
-                string[] strcoltypes_Largest20 = {"TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT" ,
-            "BLOB","BLOB","BLOB"};
-                
-
-                //创建表 field_dt
-                string[] strcolumns_field_dt = { "FieldId", "FieldImg" };
-                string[] strcoltypes_field_dt = { "INT", "BLOB" };
-                
-
-                //创建表 ElementName
-                string[] strcolumns_ElementName = { "e1", "e2", "e3", "e4", "e5", "e6", "e7", "e8", "e9","e10","e11","e12","e13","e14" };
-                string[] strcoltypes_ElementName = { "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT" };
-
-
-                //创建表 ElementValue
-                string[] strcolumns_ElementValue = { "e1", "e2", "e3", "e4", "e5", "e6", "e7", "e8", "e9","e10","e11","e12","e13","e14", "PName", "Count" , "AllElements" };
-                string[] strcoltypes_ElementValue = { "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT" };
-
-                //创建元素物质表
-                string[] strcolumns_ElementalSubstance_Name = { "Name", "Area", "e1", "e2", "e3", "e4", "e5", "e6", "e7", "e8", "e9", "e10", "e11", "e12", "e13" };
-                string[] strcoltypes_ElementalSubstance_Name = { "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT" };
-                string[] strcolumns_ElementalSubstance_Value = { "Name", "Area", "e1", "e2", "e3", "e4", "e5", "e6", "e7", "e8", "e9", "e10", "e11", "e12", "e13" };
-                string[] strcoltypes_ElementalSubstance_Value = { "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT" };
-                //创建元素物质细分表
-                string[] strcolumns_ElementSubdivision_Name = { "Class", "Area", "e1", "e2", "e3", "e4", "e5", "e6", "e7", "e8", "e9", "e10", "e11", "e12", "e13", "Name" };
-                string[] strcoltypes_ElementSubdivision_Name = { "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT" };
-                string[] strcolumns_ElementSubdivision_Value = { "Class", "Area", "e1", "e2", "e3", "e4", "e5", "e6", "e7", "e8", "e9", "e10", "e11", "e12", "e13", "Name" };
-                string[] strcoltypes_ElementSubdivision_Value = { "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT" };
-
-                //创建表 PartSize
-                string[] strcolumns_PartSize = { "c1", "c2", "c3", "c4", "c5", "c6", "c7", "c8", "c9" };
-                string[] strcoltypes_PartSize = { "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT" };
-
-
-                //创建表 Particel
-                string[] strcolumns_Particel = { "c1", "c2", "c3", "c4", "c5", "c6", "c7", "c8", "c9", "total", "Name" };
-                string[] strcoltypes_Particel = { "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT" };
-
-                //创建表 Particel_subdivision
-                string[] strcolumns_Particel_subdivision = { "c1", "c2", "c3", "c4", "c5", "c6", "c7", "c8", "c9", "Name", "total" ,"Class"};
-                string[] strcoltypes_Particel_subdivision = { "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT", "TEXT" };
-
-                //创建表 PicKL
-                string[] strcolumns_PicKL = { "pict" };
-                string[] strcoltypes_PicKL = { "BLOB" };
-                
-
-                //创建表 夹杂物面积比
-                string[] strcolumns_PicInclusionAreaRatio = { "pict" };
-                string[] strcoltypes_PicInclusionAreaRatio = { "BLOB" };
-
-                //创建表 大分类夹杂物面积比
-                string[] strcolumns_PicInclusionAreaClassRatio = { "pict" };
-                string[] strcoltypes_PicInclusionAreaClassRatio = { "BLOB" };
-
-
-                //创建表 PicYS
-                string[] strcolumns_PicYS = { "pict" };
-                string[] strcoltypes_PicYS = { "BLOB" };
-                
-
-                //创建表 PicSYXT2T
-                string[] strcolumns_PicSYXT2T = { "pict", "pict2" };
-                string[] strcoltypes_PicSYXT2T = { "BLOB", "BLOB" };
-                
-
-                //创建表 PicSYXT3T
-                string[] strcolumns_PicSYXT3T = { "pict", "pict2", "pict3" };
-                string[] strcoltypes_PicSYXT3T = { "BLOB", "BLOB", "BLOB" };
-
-
-                string[] strcolums_AreaRatio = { "c1", "c2", "c3", "c4", "c5" };
-                string[] strcoltypes_AreaRatio = { "TEXT", "TEXT", "TEXT", "TEXT", "TEXT" };
-                
-
-                //将数据插入到数据库中
-                List<DataTable> list_dt = m_export_reporttemplate.m_list_dt;
-                //元素分析-物质大分类保存至数据库
-                if (JudgeWhetherTheTableExists(list_dt, "ElementalSubstance_Name"))
-                    DataTableSurfaceSaveToDB(list_dt, "ElementalSubstance_Name", "ElementalSubstance_Name", sh, strcolumns_ElementalSubstance_Name, strcoltypes_ElementalSubstance_Name, tr);
-                if (JudgeWhetherTheTableExists(list_dt, "ElementalSubstance_Value"))
-                    DataTableSurfaceSaveToDB(list_dt, "ElementalSubstance_Value", "ElementalSubstance_Value", sh, strcolumns_ElementalSubstance_Value, strcoltypes_ElementalSubstance_Value, tr);
-                //元素分析-物质小分类细分保存至数据库
-                if (JudgeWhetherTheTableExists(list_dt, "ElementSubdivision_Name"))
-                    DataTableSurfaceSaveToDB(list_dt, "ElementSubdivision_Name", "ElementSubdivision_Name", sh, strcolumns_ElementSubdivision_Name, strcoltypes_ElementSubdivision_Name, tr);
-                if (JudgeWhetherTheTableExists(list_dt, "ElementSubdivision_Value"))
-                    DataTableSurfaceSaveToDB(list_dt, "ElementSubdivision_Value", "ElementSubdivision_Value", sh, strcolumns_ElementSubdivision_Value, strcoltypes_ElementSubdivision_Value, tr);
-
-                //创建 颗粒面积比表
-                if (JudgeWhetherTheTableExists(list_dt, "InclusionAreaRatio"))
-                    DataTableSurfaceSaveToDB(list_dt, "AreaRatio", "InclusionAreaRatio", sh, strcolums_AreaRatio, strcoltypes_AreaRatio, tr);
-
-                //创建 样品信息表
-                if (JudgeWhetherTheTableExists(list_dt, "ResultGrid"))
-                    DataTableSurfaceSaveToDB(list_dt, "ResultGrid", "ResultGrid",sh, strcolumns_ResultGrid, strcoltypes_ResultGrid,tr);
-
-
-                //插入 Largest_frame
-                if (JudgeWhetherTheTableExists(list_dt, "Largest_frame"))
-                {
-                    sh.CreateTable("Largest_frame", strcolumns_Largest_frame, strcoltypes_Largest_frame);
-                    DataTable ls_Largest_frame = list_dt.Where(aa => aa.TableName.Contains("Largest_frame")).ToList()[0];
-                    for (int i = 0; i < ls_Largest_frame.Rows.Count; i++)
-                    {
-                        if (ls_Largest_frame.Rows[i][17] == null)
-                        {
-                            continue;
-                        }
-                        if (ls_Largest_frame.Rows[i][17] == DBNull.Value)
-                        {
-                            continue;
-                        }
-
-                        string ls_sqlstr = "insert into Largest_frame (pid, Size, Width, DMAX,DMIN,Class, ColName1, ColName2, ColName3, ColName4, ColName5, ColName6,ColVal1, ColVal2, ColVal3, ColVal4, ColVal5, ColVal6 ,FieldID,p1) values('"
-                            + ls_Largest_frame.Rows[i][0].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][1].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][2].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][3].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][4].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][5].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][6].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][7].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][8].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][9].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][10].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][11].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][12].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][13].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][14].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][15].ToString() + "','"
-                             + ls_Largest_frame.Rows[i][16].ToString() + "','"
-                              + ls_Largest_frame.Rows[i][17].ToString() + "',"
-                            + ls_Largest_frame.Rows[i][18].ToString() + ",:p1)";
-
-                        byte[] byte_p1 = (byte[])ls_Largest_frame.Rows[i][19];
-
-                        int iresult = sh.ExecuteQuery(ls_sqlstr, "p1", byte_p1, tr);
-                    }
-                }
-                    
-
-                //插入帧图子表
-                if(JudgeWhetherTheTableExists(list_dt, "FrameGraphSubTable"))
-                {
-                    sh.CreateTable("FrameGraphSubTable", strcolumns_Largest_frame, strcoltypes_Largest_frame);
-                    DataTable ls_Largest_frame = list_dt.Where(aa => aa.TableName.Contains("FrameGraphSubTable")).ToList()[0];
-                    for (int i = 0; i < ls_Largest_frame.Rows.Count; i++)
-                    {
-                        if (ls_Largest_frame.Rows[i][19] == null)
-                        {
-                            continue;
-                        }
-                        if (ls_Largest_frame.Rows[i][19] == DBNull.Value)
-                        {
-                            continue;
-                        }
-
-                        string ls_sqlstr = "insert into FrameGraphSubTable (pid, Size, Width,DMAX,DMIN, Class, ColName1, ColName2, ColName3, ColName4, ColName5, ColName6,ColVal1, ColVal2, ColVal3, ColVal4, ColVal5, ColVal6 ,FieldID,p1) values('"
-                            + ls_Largest_frame.Rows[i][0].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][1].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][2].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][3].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][4].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][5].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][6].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][7].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][8].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][9].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][10].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][11].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][12].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][13].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][14].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][15].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][16].ToString() + "','"
-                            + ls_Largest_frame.Rows[i][17].ToString() + "',"
-                            + ls_Largest_frame.Rows[i][18].ToString() + ",:p1)";
-
-                        byte[] byte_p1 = (byte[])ls_Largest_frame.Rows[i][19];
-
-                        int iresult = sh.ExecuteQuery(ls_sqlstr, "p1", byte_p1, tr);
-                    }
-                }
-
-                //插入 Largest20
-                if(JudgeWhetherTheTableExists(list_dt, "Largest20"))
-                {
-                    sh.CreateTable("Largest20", strcolumns_Largest20, strcoltypes_Largest20);
-                    DataTable ls_Largest20 = list_dt.Where(aa => aa.TableName.Contains("Largest20")).ToList()[0];
-                    for (int i = 0; i < ls_Largest20.Rows.Count; i++)
-                    {
-                        if (ls_Largest20.Rows[i][16] == null)
-                        {
-                            continue;
-                        }
-                        if (ls_Largest20.Rows[i][16] == DBNull.Value)
-                        {
-                            continue;
-                        }
-
-                        string ls_sqlstr = "insert into Largest20 (pid, Size, Width ,DMAX,DMIN,Class, ColName1, ColName2, ColName3, ColName4, ColName5, ColName6,ColVal1, ColVal2, ColVal3, ColVal4, ColVal5, ColVal6 ,p1,p2,p3) values('"
-                            + ls_Largest20.Rows[i][0].ToString() + "','"
-                            + ls_Largest20.Rows[i][1].ToString() + "','"
-                            + ls_Largest20.Rows[i][2].ToString() + "','"
-                            + ls_Largest20.Rows[i][3].ToString() + "','"
-                            + ls_Largest20.Rows[i][4].ToString() + "','"
-                            + ls_Largest20.Rows[i][5].ToString() + "','"
-                            + ls_Largest20.Rows[i][6].ToString() + "','"
-                            + ls_Largest20.Rows[i][7].ToString() + "','"
-                            + ls_Largest20.Rows[i][8].ToString() + "','"
-                            + ls_Largest20.Rows[i][9].ToString() + "','"
-                            + ls_Largest20.Rows[i][10].ToString() + "','"
-                            + ls_Largest20.Rows[i][11].ToString() + "','"
-                            + ls_Largest20.Rows[i][12].ToString() + "','"
-                            + ls_Largest20.Rows[i][13].ToString() + "','"
-                            + ls_Largest20.Rows[i][14].ToString() + "','"
-                            + ls_Largest20.Rows[i][15].ToString() + "','"
-                            + ls_Largest20.Rows[i][16].ToString() + "','"
-                            + ls_Largest20.Rows[i][17].ToString() + "',:p1,:p2,:p3)";
-
-                        byte[] byte_p1 = (byte[])ls_Largest20.Rows[i][18];
-                        byte[] byte_p2 = (byte[])ls_Largest20.Rows[i][19];
-                        byte[] byte_p3 = (byte[])ls_Largest20.Rows[i][20];
-
-                        int iresult = sh.ExecuteQuery(ls_sqlstr, "p1", byte_p1, "p2", byte_p2, "p3", byte_p3, tr);
-                    }
-                }
-                
-
-                //-----------------------------------------------------------------------------------------------------------------------------------
-                ////插入标记帧部份,进行特殊处理,从硬盘中拿现已经生成好的标记图像,进行加载,然后转成byte数组,存入到数据库中                ////准备存放标记图的文件夹
-                string m_strFieldPath_Mark = m_ReportApp.m_rstDataMgr.ResultFilesList[m_ReportApp.m_rstDataMgr.getSelectedIndex()].FilePath + "\\FIELD_FILES_MARK\\";
-
-                //插入 field_dt
-                if (JudgeWhetherTheTableExists(list_dt, "field_dt"))
-                {
-                    sh.CreateTable("field_dt", strcolumns_field_dt, strcoltypes_field_dt);
-                    DataTable ls_field_dt = list_dt.Where(aa => aa.TableName.Contains("field_dt")).ToList()[0];
-                    for (int i = 0; i < ls_field_dt.Rows.Count; i++)
-                    {
-                        string ls_sqlstr = "insert into field_dt (FieldId,FieldImg) values(" + ls_field_dt.Rows[i]["FieldId"] + ",:pict)";
-                        string str_fieldid = ls_field_dt.Rows[i][0].ToString();
-
-                        //从生成的FIELD_FIES_MARK文件夹中加载图像并转成byte数组,保存到数据库,节省内存
-                        Bitmap ls_bp_mark = new Bitmap(m_strFieldPath_Mark + str_fieldid + ".bmp");
-                        MemoryStream newms_fieldmark = new MemoryStream();
-                        ls_bp_mark.Save(newms_fieldmark, System.Drawing.Imaging.ImageFormat.Bmp);
-                        newms_fieldmark.Seek(0, SeekOrigin.Begin);
-                        byte[] newarr_field_mrak = new byte[newms_fieldmark.Length];
-                        newms_fieldmark.Read(newarr_field_mrak, 0, newarr_field_mrak.Length);
-
-                        int iresult = sh.ExecuteQuery(ls_sqlstr, "pict", newarr_field_mrak, tr);
-
-                        newms_fieldmark.Dispose();
-                        newms_fieldmark = null;
-                        ls_bp_mark.Dispose();
-                        ls_bp_mark = null;
-
-                        GC.Collect();
-                        GC.WaitForPendingFinalizers();
-                    }
-                }
-
-                //-----------------------------------------------------------------------------------------------------------------
-
-                //插入 ElementName
-                if (JudgeWhetherTheTableExists(list_dt, "ElementName"))
-                    DataTableSurfaceSaveToDB(list_dt, "ElementName", "ElementName", sh, strcolumns_ElementName, strcoltypes_ElementName, tr);
-
-
-                //插入 ElementValue
-                if (JudgeWhetherTheTableExists(list_dt, "ElementValue"))
-                    DataTableSurfaceSaveToDB(list_dt, "ElementValue", "ElementValue", sh, strcolumns_ElementValue, strcoltypes_ElementValue, tr);
-
-
-                //插入 PartSize
-                if (JudgeWhetherTheTableExists(list_dt, "PartSize"))
-                    DataTableSurfaceSaveToDB(list_dt, "PartSize", "PartSize", sh, strcolumns_PartSize, strcoltypes_PartSize, tr);
-
-
-                //插入 Particel
-                if (JudgeWhetherTheTableExists(list_dt, "Particel"))
-                    DataTableSurfaceSaveToDB(list_dt, "Particel", "Particel", sh, strcolumns_Particel, strcoltypes_Particel, tr);
-
-
-                //插入 Particel_subdivision
-                if (JudgeWhetherTheTableExists(list_dt, "Particel_subdivision"))
-                    DataTableSurfaceSaveToDB(list_dt, "Particel_subdivision", "Particel_subdivision", sh, strcolumns_Particel_subdivision, strcoltypes_Particel_subdivision, tr);
-
-                //插入 PicKL
-                if (JudgeWhetherTheTableExists(list_dt, "PicKL"))
-                {
-                    sh.CreateTable("PicKL", strcolumns_PicKL, strcoltypes_PicKL);
-                    DataTable ls_PicKL = list_dt.Where(aa => aa.TableName.Contains("PicKL")).ToList()[0];
-                    for (int i = 0; i < ls_PicKL.Rows.Count; i++)
-                    {
-                        if (ls_PicKL.Rows[i][0] == null)
-                        {
-                            continue;
-                        }
-                        if (ls_PicKL.Rows[i][0] == DBNull.Value)
-                        {
-                            continue;
-                        }
-
-                        string ls_sqlstr = "insert into PicKL (pict) values(:pict)";
-                        byte[] byte_p1 = (byte[])ls_PicKL.Rows[i][0];
-                        int iresult = sh.ExecuteQuery(ls_sqlstr, "pict", byte_p1, tr);
-                    }
-                }
-                
-
-                //插入 Pic_InclusionAreaRatio
-                if (JudgeWhetherTheTableExists(list_dt, "Pic_InclusionAreaRatio"))
-                {
-                    sh.CreateTable("PicInclusionAreaRatio", strcolumns_PicKL, strcoltypes_PicKL);
-                    DataTable ls_PicInclusionAreaRatio = list_dt.Where(aa => aa.TableName.Contains("Pic_InclusionAreaRatio")).ToList()[0];
-                    for (int i = 0; i < ls_PicInclusionAreaRatio.Rows.Count; i++)
-                    {
-                        if (ls_PicInclusionAreaRatio.Rows[i][0] == null)
-                        {
-                            continue;
-                        }
-                        if (ls_PicInclusionAreaRatio.Rows[i][0] == DBNull.Value)
-                        {
-                            continue;
-                        }
-
-                        string ls_sqlstr = "insert into PicInclusionAreaRatio (pict) values(:pict)";
-                        byte[] byte_p1 = (byte[])ls_PicInclusionAreaRatio.Rows[i][0];
-                        int iresult = sh.ExecuteQuery(ls_sqlstr, "pict", byte_p1, tr);
-                    }
-                }
-                
-
-
-                //插入 PicYS
-                if (JudgeWhetherTheTableExists(list_dt, "PicYS"))
-                {
-                    sh.CreateTable("PicYS", strcolumns_PicYS, strcoltypes_PicYS);
-                    DataTable ls_PicYS = list_dt.Where(aa => aa.TableName.Contains("PicYS")).ToList()[0];
-                    for (int i = 0; i < ls_PicYS.Rows.Count; i++)
-                    {
-                        if (ls_PicYS.Rows[i][0] == null)
-                        {
-                            continue;
-                        }
-                        if (ls_PicYS.Rows[i][0] == DBNull.Value)
-                        {
-                            continue;
-                        }
-                        string ls_sqlstr = "insert into PicYS (pict) values(:pict)";
-                        byte[] byte_p1 = (byte[])ls_PicYS.Rows[i][0];
-                        int iresult = sh.ExecuteQuery(ls_sqlstr, "pict", byte_p1, tr);
-                    }
-                }
-                
-
-                //插入 PicSYXT2T
-                if (JudgeWhetherTheTableExists(list_dt, "PicSYXT2T"))
-                {
-                    sh.CreateTable("PicSYXT2T", strcolumns_PicSYXT2T, strcoltypes_PicSYXT2T);
-                    DataTable ls_PicSYXT2T = list_dt.Where(aa => aa.TableName.Contains("PicSYXT2T")).ToList()[0];
-                    for (int i = 0; i < ls_PicSYXT2T.Rows.Count; i++)
-                    {
-                        if (ls_PicSYXT2T.Rows[i][0] == null)
-                        {
-                            continue;
-                        }
-                        if (ls_PicSYXT2T.Rows[i][0] == DBNull.Value)
-                        {
-                            continue;
-                        }
-                        string ls_sqlstr = "insert into PicSYXT2T (pict,pict2) values(:pict,:pict2)";
-                        byte[] byte_p1 = (byte[])ls_PicSYXT2T.Rows[i][0];
-                        byte[] byte_p2 = (byte[])ls_PicSYXT2T.Rows[i][1];
-                        int iresult = sh.ExecuteQuery(ls_sqlstr, "pict", byte_p1, "pict2", byte_p2, tr);
-                    }
-                }
-                
-
-                //插入 PicSYXT3T
-                if (JudgeWhetherTheTableExists(list_dt, "PicSYXT3T"))
-                {
-                    sh.CreateTable("PicSYXT3T", strcolumns_PicSYXT3T, strcoltypes_PicSYXT3T);
-                    DataTable ls_PicSYXT3T = list_dt.Where(aa => aa.TableName.Contains("PicSYXT3T")).ToList()[0];
-                    for (int i = 0; i < ls_PicSYXT3T.Rows.Count; i++)
-                    {
-                        if (ls_PicSYXT3T.Rows[i][0] == null)
-                        {
-                            continue;
-                        }
-                        if (ls_PicSYXT3T.Rows[i][0] == DBNull.Value)
-                        {
-                            continue;
-                        }
-
-                        string ls_sqlstr = "insert into PicSYXT3T (pict,pict2,pict3) values(:pict,:pict2,:pict3)";
-                        byte[] byte_p1 = (byte[])ls_PicSYXT3T.Rows[i][0];
-                        byte[] byte_p2 = (byte[])ls_PicSYXT3T.Rows[i][1];
-                        byte[] byte_p3 = (byte[])ls_PicSYXT3T.Rows[i][2];
-                        int iresult = sh.ExecuteQuery(ls_sqlstr, "pict", byte_p1, "pict2", byte_p2, "pict3", byte_p3, tr);
-                    }
-                }
-
-
-
-                //插入 PicKL
-                if (JudgeWhetherTheTableExists(list_dt, "Pic_InclusionareaClassRatio"))
-                {
-                    sh.CreateTable("Pic_InclusionareaClassRatio", strcolumns_PicInclusionAreaClassRatio, strcoltypes_PicInclusionAreaClassRatio);
-                    DataTable ls_PicKL = list_dt.Where(aa => aa.TableName.Contains("Pic_InclusionareaClassRatio")).ToList()[0];
-                    for (int i = 0; i < ls_PicKL.Rows.Count; i++)
-                    {
-                        if (ls_PicKL.Rows[i][0] == null)
-                        {
-                            continue;
-                        }
-                        if (ls_PicKL.Rows[i][0] == DBNull.Value)
-                        {
-                            continue;
-                        }
-
-                        string ls_sqlstr = "insert into Pic_InclusionareaClassRatio (pict) values(:pict)";
-                        byte[] byte_p1 = (byte[])ls_PicKL.Rows[i][0];
-                        int iresult = sh.ExecuteQuery(ls_sqlstr, "pict", byte_p1, tr);
-                    }
-                }
-
-
-                //事务提交
-                sh.TranscationCommit(tr);
-            //}
-            //catch (Exception ee)
-            //{
-            //    //回滚
-            //    sh.TranscationRollback(tr);
-            //}
-            //finally
-            //{
-                //最后关闭连接
-                tr.Dispose();
-                tr = null;
-                sh.CloseConnection();
-            //}
-        }
        
-        private void DataTableSurfaceSaveToDB(List<DataTable> list_dt,string a_surfaceName,string a_DatatableSurfaceName, SqlHelper sh,string[] strcolumns,string[] strcoltypes, SQLiteTransaction tr)
-        {
-            sh.CreateTable(a_surfaceName, strcolumns, strcoltypes);
-            DataTable dt = list_dt.Where(aa => aa.TableName.Contains(a_DatatableSurfaceName)).ToList()[0];
-            string strcolumnsName = "";
-            for (int i = 0;i< strcolumns.Count();i++)
-            {
-                strcolumnsName = strcolumnsName + strcolumns[i].ToString();
-                if (i != strcolumns.Count() - 1)
-                    strcolumnsName = strcolumnsName + ",";
-            }
-            for (int i = 0; i < dt.Rows.Count; i++)
-            {
-                string ls_dtstr = "";
-                for(int a=0;a< strcolumns.Count();a++)
-                {
-                    ls_dtstr = ls_dtstr + dt.Rows[i][a].ToString();
-                    if (a != strcolumns.Count() - 1)
-                        ls_dtstr = ls_dtstr + "','";
-
-                }
-                string ls_sqlstr = "insert into "+ a_surfaceName+" ("+strcolumnsName+") values('"
-                   + ls_dtstr + "')";
-                sh.ExecuteQueryResult(ls_sqlstr, tr);
-            }
-        }
-        private bool JudgeWhetherTheTableExists(List<DataTable> list_dt,string str)
-        {
-            for (int i=0;i< list_dt.Count;i++)
-            {
-                if (list_dt[i].TableName.Contains(str))
-                    return true;
-            }
-            return false;
-        }
-        #endregion
 
         #region 导出工作线程部份
         private void backgroundWorker2_DoWork(object sender, DoWorkEventArgs e)
@@ -1862,8 +1347,8 @@ namespace OTSIncAReportApp
             i_zz = 80 / 9;
 
             //首先将测量结果信息表导出,在表头------------------------------------------------
-            worker.ReportProgress(0, table["rictbox5"].ToString());//加载测量结果信息表模块中....
-            worker.ReportProgress(0, table["rictbox6"].ToString());//加载:测量结果信息表
+            worker.ReportProgress(0, table["result_information_ing"].ToString());//加载测量结果信息表模块中....
+            worker.ReportProgress(0, table["load_result_information"].ToString());//加载:测量结果信息表
             //更新进度条
             processvalue = processvalue + 1;
             worker.ReportProgress(processvalue);
@@ -1873,12 +1358,13 @@ namespace OTSIncAReportApp
             {
                 System.Threading.Thread.Sleep(500);
             }
-            worker.ReportProgress(0, table["rictbox8"].ToString());//加载测量结果信息表模块完成
-            //-------------------------------------------------------------------------
+            worker.ReportProgress(0, table["loading_result_information_completed"].ToString());//加载测量结果信息表模块完成
+                                                                                               //-------------------------------------------------------------------------
 
-            //调用输出,颗粒列表----------------------------------------
-            worker.ReportProgress(0, table["rictbox9"].ToString());//加载颗粒列表模块中....
-            worker.ReportProgress(0, table["rictbox10"].ToString());//加载:颗粒列表
+
+            //调用,颗粒尺寸分析表------------------------------------------------
+            worker.ReportProgress(0, table["dimensional_analysis_table_ing"].ToString());//加载颗粒尺寸分析表模块中....
+            worker.ReportProgress(0, table["loading_dimension_analysis_table"].ToString());//加载:颗粒尺寸分析表
             //更新进度条
             processvalue = processvalue + i_zz;
             worker.ReportProgress(processvalue);
@@ -1888,29 +1374,29 @@ namespace OTSIncAReportApp
             {
                 System.Threading.Thread.Sleep(500);
             }
-            worker.ReportProgress(0, table["rictbox14"].ToString());//加载颗粒列表模块完成
+            worker.ReportProgress(0, table["loading_dimension_analysis_table_completed"].ToString());//加载颗粒尺寸分析表模块完成
 
 
 
-            //调用输出,平均元素含量表---------------------------------------
-            worker.ReportProgress(0, table["rictbox15"].ToString());//加载平均元素含量表模块中....
-            worker.ReportProgress(0, table["rictbox16"].ToString());//加载:平均元素含量
+            //调用,元素分析表---------------------------------------------
+            worker.ReportProgress(0, table["element_analysis_table_ing"].ToString());//加载元素分析表模块中....
+            worker.ReportProgress(0, table["load_element_analysis_table"].ToString());//加载:元素分析
             //更新进度条
             processvalue = processvalue + i_zz;
             worker.ReportProgress(processvalue);
             lock (m_thread_flag)
-                m_thread_flag = table["rictbox7"].ToString(); //等待
+                m_thread_flag = table["rictbox7"].ToString();//等待
             while (m_thread_flag == table["rictbox7"].ToString())//等待
             {
                 System.Threading.Thread.Sleep(500);
             }
-            worker.ReportProgress(0, table["rictbox17"].ToString());//加载平均元素含量表模块完成
+            worker.ReportProgress(0, table["loading_element_analysis_table_completed"].ToString());//加载元素分析表模块完成
 
 
 
-            //调用输出,颗粒尺寸表--------------------------------------
-            worker.ReportProgress(0, table["rictbox19"].ToString());//加载颗粒尺寸表模块中....
-            worker.ReportProgress(0, table["rictbox20"].ToString());//加载:颗粒尺寸
+            //调用,夹杂物面积比表---------------------------------------------
+            worker.ReportProgress(0, table["inca_area_ratio_table_ing"].ToString());//加载夹杂物面积比表模块中....
+            worker.ReportProgress(0, table["load_inca_area_ratio_table"].ToString());//加载:夹杂物面积比
             //更新进度条
             processvalue = processvalue + i_zz;
             worker.ReportProgress(processvalue);
@@ -1920,14 +1406,28 @@ namespace OTSIncAReportApp
             {
                 System.Threading.Thread.Sleep(500);
             }
-            worker.ReportProgress(0, table["rictbox21"].ToString());//加载颗粒尺寸表模块完成
+            worker.ReportProgress(0, table["loading_inca_area_ratio_table_completed"].ToString());//加载夹杂物面积比表模块完成
 
 
+            //调用,夹杂物面积比图---------------------------------------------
+            worker.ReportProgress(0, table["inca_area_ratio_diagram_ing"].ToString());//加载夹杂物面积比图模块中....
+            worker.ReportProgress(0, table["load_inca_area_ratio_diagram"].ToString());//加载:夹杂物面积比图
+            //更新进度条
+            processvalue = processvalue + i_zz;
+            worker.ReportProgress(processvalue);
+            lock (m_thread_flag)
+                m_thread_flag = table["rictbox7"].ToString();//等待
+            while (m_thread_flag == table["rictbox7"].ToString())//等待
+            {
+                System.Threading.Thread.Sleep(500);
+            }
+            worker.ReportProgress(0, table["loading_inca_area_ratio_diagram_completed"].ToString());//加载夹杂物面积比图模块完成
 
 
-            //调用,颗粒成份图------------------------------------------------
-            worker.ReportProgress(0, table["rictbox23"].ToString());//加载颗粒成份图模块中....
-            worker.ReportProgress(0, table["rictbox24"].ToString());//加载:颗粒成份图
+            System.Threading.Thread.Sleep(2000);
+            //调用,三元相图----------------------------------------------
+            worker.ReportProgress(0, table["ternary_graph_ing"].ToString());//加载三元相图模块中....
+            worker.ReportProgress(0, table["load_ternary_graph"].ToString());//加载:三元相图
             //更新进度条
             processvalue = processvalue + i_zz;
             worker.ReportProgress(processvalue);
@@ -1937,11 +1437,12 @@ namespace OTSIncAReportApp
             {
                 System.Threading.Thread.Sleep(500);
             }
-            worker.ReportProgress(0, table["rictbox25"].ToString());//加载颗粒成份图模块完成
+            worker.ReportProgress(0, table["loading_ternary_graph_completed"].ToString());//加载三元相图模块完成
+
 
-            //调用,元素成份图---------------------------------------------
-            worker.ReportProgress(0, table["rictbox27"].ToString());//加载元素成份图模块中....
-            worker.ReportProgress(0, table["rictbox28"].ToString());//加载:元素成份图
+            //调用输出,颗粒列表----------------------------------------
+            worker.ReportProgress(0, table["particle_list_ing"].ToString());//加载颗粒列表模块中....
+            worker.ReportProgress(0, table["load_particle_list"].ToString());//加载:颗粒列表
             //更新进度条
             processvalue = processvalue + i_zz;
             worker.ReportProgress(processvalue);
@@ -1951,12 +1452,13 @@ namespace OTSIncAReportApp
             {
                 System.Threading.Thread.Sleep(500);
             }
-            worker.ReportProgress(0, table["rictbox29"].ToString());//加载元素成份图模块完成
+            worker.ReportProgress(0, table["loading_particle_list_completed"].ToString());//加载颗粒列表模块完成
 
 
-            //调用,三元相图----------------------------------------------
-            worker.ReportProgress(0, table["rictbox31"].ToString());//加载三元相图模块中....
-            worker.ReportProgress(0, table["rictbox32"].ToString());//加载:三元相图
+
+            //调用输出,颗粒列表帧图----------------------------------------
+            worker.ReportProgress(0, table["particle_list_frame_diagram_ing"].ToString());//加载颗粒列表帧图模块中....
+            worker.ReportProgress(0, table["load_particle_list_frame_diagram"].ToString());//加载:颗粒列表帧图
             //更新进度条
             processvalue = processvalue + i_zz;
             worker.ReportProgress(processvalue);
@@ -1966,7 +1468,7 @@ namespace OTSIncAReportApp
             {
                 System.Threading.Thread.Sleep(500);
             }
-            worker.ReportProgress(0, table["rictbox33"].ToString());//加载三元相图模块完成
+            worker.ReportProgress(0, table["loading_particle_list_frame_diagram_completed"].ToString());//加载颗粒列表帧图模块完成
 
 
             //生成,模板临时数据库文件----------------------------------------------
@@ -2012,71 +1514,74 @@ namespace OTSIncAReportApp
                 string s = AnalyticGraphics(m_mbszclass.M_KLFXJG.index_cb_jzwfl_xstx);
                 if (ls_str.IndexOf(table["rictbox12"].ToString()) > -1)//加载:
                 {
-                    if (ls_str.IndexOf(table["rictbox11"].ToString()) > -1)//测量结果信息表
+                    if (ls_str.IndexOf(table["result_information"].ToString()) > -1)//测量结果信息表
                     {
-                        //m_export_reporttemplate.GetDBData();
-                        m_export_reporttemplate.InsertReportTemplateTable_ResultGrid();
+                        DEVReport.setResultGrid(m_mbszclass);
                         lock (m_thread_flag)
                             m_thread_flag = strNill;
                     }
-                    if (ls_str.IndexOf(table["rictbox13"].ToString()) > -1)//颗粒列
+                    if (ls_str.IndexOf(table["dimensional_analysis_table"].ToString()) > -1)//颗粒尺寸分析
                     {
-                        //判断颗粒列表是否导出
-                        if (m_mbszclass.M_KLLBXX.b_ck_kllb_xsmk)
-                        {
-                            m_export_reporttemplate.InsertReportTemplateTable_ParticlesGridDevidePage_CleanlinessA(m_mbszclass);
-                        }
-                            
+
+                        if (m_mbszclass.M_KLFXJG.b_ck_klcc_xsmk)
+                            DEVReport.setParticleSizeTable(m_mbszclass);
                         lock (m_thread_flag)
                             m_thread_flag = strNill;
                     }
 
-                    if (ls_str.IndexOf(table["rictbox18"].ToString()) > -1)//平均元素含量
+                    if (ls_str.IndexOf(table["element_analysis_table"].ToString()) > -1)//元素分析
                     {
-                        m_export_reporttemplate.InsertReportTemplateTable_ElementAvgGrid(m_mbszclass);
-                        m_export_reporttemplate.InsertReportTemplateChart_InclusionAreaClassRatio("pie", m_mbszclass);
-
-
-                        m_export_reporttemplate.InsertReportTemplateTable_ElementCompositionAvgGrid(m_mbszclass);
-                        m_export_reporttemplate.InsertReportTemplateChart_InclusionAreaRatio("pie", m_mbszclass);
+                        if (m_mbszclass.M_YSFXJG.b_ck_ysfx_xsmk)
+                            DEVReport.setElementAvgGrid(m_mbszclass);
                         lock (m_thread_flag)
                             m_thread_flag = strNill;
                     }
 
-                    if (ls_str.IndexOf(table["rictbox22"].ToString()) > -1)//颗粒尺寸
+                    if (ls_str.IndexOf(table["inca_area_ratio_table"].ToString()) > -1)//夹杂物面积比
                     {
-                        m_export_reporttemplate.InsertReportTemplateTable_ParticleSizeGrid(m_mbszclass);
+                        if (m_mbszclass.M_JZWZB.b_ck_surface)
+                            DEVReport.setINCAtable(m_mbszclass);
                         lock (m_thread_flag)
                             m_thread_flag = strNill;
                     }
 
-                    if (ls_str.IndexOf(table["rictbox26"].ToString()) > -1)//颗粒成份
+                    if (ls_str.IndexOf(table["inca_area_ratio_diagram"].ToString()) > -1)//夹杂物面积比
                     {
-                        //m_export_reporttemplate.InsertReportTemplateChart_ParticlesCompositionChart(AnalyticGraphics(m_mbszclass.M_KLFXJG.index_cb_jzwfl_xstx));
+                        if (m_mbszclass.M_JZWZB.b_ck_chart)
+                        {
+                            DEVReport.set_incaPIC_classify(m_mbszclass);
+                            DEVReport.set_incaPIC_subdivision(m_mbszclass);
+                        }
                         lock (m_thread_flag)
                             m_thread_flag = strNill;
                     }
-                    if (ls_str.IndexOf(table["rictbox30"].ToString()) > -1)//元素成份图
+                    if (ls_str.IndexOf(table["ternary_graph"].ToString()) > -1)//三元
                     {
-                     //   m_export_reporttemplate.InsertReportTemplateChart_ElementCompositionChart(AnalyticGraphics(m_mbszclass.M_YSFXJG.index_cb_yscf_xstx));
+                        if (m_mbszclass.M_SYXT.b_ck_syxt_xsmk)
+                            DEVReport.InsertReportTemplateChart_Trianglediagram(m_mbszclass);
                         lock (m_thread_flag)
                             m_thread_flag = strNill;
                     }
 
-                    if (ls_str.IndexOf(table["rictbox34"].ToString()) > -1)//三元相图
+                    if (ls_str.IndexOf(table["particle_list"].ToString()) > -1)//颗粒列表
                     {
-                        //三元图部分
-                        if (m_mbszclass.M_SYXT.b_ck_syxt_xsmk)
-                            m_export_reporttemplate.InsertReportTemplateChart_Trianglediagram(m_mbszclass);
+                        if (m_mbszclass.M_KLLBXX.b_ck_kllb_xsmk)
+                            DEVReport.set_kllb_data(m_mbszclass);
                         lock (m_thread_flag)
                             m_thread_flag = strNill;
                     }
 
+                    if (ls_str.IndexOf(table["particle_list_frame_diagram"].ToString()) > -1)//颗粒帧图列表
+                    {
+                        if (m_mbszclass.M_KLLBXX.b_ck_kllb_fjzt)
+                            DEVReport.set_kllb_data_frame(m_mbszclass);
+                        
+                        lock (m_thread_flag)
+                            m_thread_flag = strNill;
+                    }
                     if (ls_str.IndexOf(table["rictbox38"].ToString()) > -1)//生成模板临时数据库文件
                     {
-                        //导出到数据库文件中
-                        SaveReportTemplateDBFile();
-
+                        DEVReport.International_language(dev_internationalLanguage());
                         lock (m_thread_flag)
                             m_thread_flag = strNill;
                     }
@@ -2607,9 +2112,10 @@ namespace OTSIncAReportApp
 
         private void button1_Click(object sender, EventArgs e)
         {
-            OTS_DEVReport DEVReport = new OTS_DEVReport(this);
+            DEVReport = new OTS_DEVReport(this);
             //DEVReport.Dispose();
             //DEVReport = new OTS_DEVReport(this);
+
             DEVReport.setResultGrid(m_mbszclass);
             DEVReport.setParticleSizeTable(m_mbszclass);
             DEVReport.setElementAvgGrid(m_mbszclass);
@@ -2617,7 +2123,7 @@ namespace OTSIncAReportApp
             DEVReport.set_incaPIC_classify(m_mbszclass);
             DEVReport.set_incaPIC_subdivision(m_mbszclass);
 
-          //  DEVReport.InsertReportTemplateChart_Trianglediagram(m_mbszclass);
+            DEVReport.InsertReportTemplateChart_Trianglediagram(m_mbszclass);
             DEVReport.set_kllb_data(m_mbszclass);
 
 

+ 2 - 1
OTSIncAReportApp/1-UI/OTSTemplateDesigner/OTSReport_GetEChartImage.cs

@@ -30,8 +30,9 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
 
         public void get_ParticalesCompositionChart(string pic)
         {
+            
             PicStr = pic;
-
+           
             //得到图片数据后,关闭该窗体
             this.Close();
 

+ 98 - 10
OTSIncAReportApp/1-UI/OTSTemplateDesigner/OTSReport_TemplateDesignerRM.Designer.cs

@@ -75,6 +75,8 @@
             this.label33 = new System.Windows.Forms.Label();
             this.label42 = new System.Windows.Forms.Label();
             this.groupBox8 = new System.Windows.Forms.GroupBox();
+            this.ck_kllb_fjzt = new System.Windows.Forms.CheckBox();
+            this.label111 = new System.Windows.Forms.Label();
             this.groupBox_zt = new System.Windows.Forms.GroupBox();
             this.ParticleList_5 = new System.Windows.Forms.Label();
             this.cb_FrameChart_p2 = new System.Windows.Forms.ComboBox();
@@ -111,11 +113,16 @@
             this.pictureBox2 = new System.Windows.Forms.PictureBox();
             this.pictureBox1 = new System.Windows.Forms.PictureBox();
             this.panel3 = new System.Windows.Forms.Panel();
+            this.groupBox2 = new System.Windows.Forms.GroupBox();
             this.groupBZ = new System.Windows.Forms.GroupBox();
             this.textBox_strBZ = new System.Windows.Forms.TextBox();
             this.groupBox9 = new System.Windows.Forms.GroupBox();
             this.label39 = new System.Windows.Forms.Label();
             this.cb_ParticleRange = new System.Windows.Forms.ComboBox();
+            this.ck_jzwzb_surface = new System.Windows.Forms.CheckBox();
+            this.label12 = new System.Windows.Forms.Label();
+            this.label13 = new System.Windows.Forms.Label();
+            this.ck_jzwzb_chart = new System.Windows.Forms.CheckBox();
             this.groupBox1.SuspendLayout();
             this.groupBox4.SuspendLayout();
             this.groupBox6.SuspendLayout();
@@ -132,6 +139,7 @@
             ((System.ComponentModel.ISupportInitialize)(this.pictureBox2)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
             this.panel3.SuspendLayout();
+            this.groupBox2.SuspendLayout();
             this.groupBZ.SuspendLayout();
             this.groupBox9.SuspendLayout();
             this.SuspendLayout();
@@ -625,6 +633,8 @@
             // 
             // groupBox8
             // 
+            this.groupBox8.Controls.Add(this.ck_kllb_fjzt);
+            this.groupBox8.Controls.Add(this.label111);
             this.groupBox8.Controls.Add(this.groupBox_zt);
             this.groupBox8.Controls.Add(this.groupBox_px);
             this.groupBox8.Controls.Add(this.ck_kllb_npxx);
@@ -644,13 +654,31 @@
             this.groupBox8.TabStop = false;
             this.groupBox8.Text = "颗粒列表";
             // 
+            // ck_kllb_fjzt
+            // 
+            this.ck_kllb_fjzt.AutoSize = true;
+            this.ck_kllb_fjzt.Location = new System.Drawing.Point(224, 47);
+            this.ck_kllb_fjzt.Name = "ck_kllb_fjzt";
+            this.ck_kllb_fjzt.Size = new System.Drawing.Size(15, 14);
+            this.ck_kllb_fjzt.TabIndex = 57;
+            this.ck_kllb_fjzt.UseVisualStyleBackColor = true;
+            // 
+            // label111
+            // 
+            this.label111.AutoSize = true;
+            this.label111.Location = new System.Drawing.Point(7, 47);
+            this.label111.Name = "label111";
+            this.label111.Size = new System.Drawing.Size(53, 12);
+            this.label111.TabIndex = 56;
+            this.label111.Text = "附加帧图";
+            // 
             // groupBox_zt
             // 
             this.groupBox_zt.Controls.Add(this.ParticleList_5);
             this.groupBox_zt.Controls.Add(this.cb_FrameChart_p2);
             this.groupBox_zt.Controls.Add(this.ParticleList_4);
             this.groupBox_zt.Controls.Add(this.cb_FrameChart_p1);
-            this.groupBox_zt.Location = new System.Drawing.Point(9, 227);
+            this.groupBox_zt.Location = new System.Drawing.Point(8, 239);
             this.groupBox_zt.Name = "groupBox_zt";
             this.groupBox_zt.Size = new System.Drawing.Size(249, 125);
             this.groupBox_zt.TabIndex = 55;
@@ -705,7 +733,7 @@
             this.groupBox_px.Controls.Add(this.ParticleList_2);
             this.groupBox_px.Controls.Add(this.ParticleList_1);
             this.groupBox_px.Controls.Add(this.comboBox_p1);
-            this.groupBox_px.Location = new System.Drawing.Point(9, 55);
+            this.groupBox_px.Location = new System.Drawing.Point(8, 67);
             this.groupBox_px.Name = "groupBox_px";
             this.groupBox_px.Size = new System.Drawing.Size(249, 166);
             this.groupBox_px.TabIndex = 54;
@@ -775,7 +803,7 @@
             // ck_kllb_npxx
             // 
             this.ck_kllb_npxx.AutoSize = true;
-            this.ck_kllb_npxx.Location = new System.Drawing.Point(230, 428);
+            this.ck_kllb_npxx.Location = new System.Drawing.Point(229, 440);
             this.ck_kllb_npxx.Margin = new System.Windows.Forms.Padding(2);
             this.ck_kllb_npxx.Name = "ck_kllb_npxx";
             this.ck_kllb_npxx.Size = new System.Drawing.Size(15, 14);
@@ -786,7 +814,7 @@
             // ck_kllb_fdtx
             // 
             this.ck_kllb_fdtx.AutoSize = true;
-            this.ck_kllb_fdtx.Location = new System.Drawing.Point(230, 400);
+            this.ck_kllb_fdtx.Location = new System.Drawing.Point(229, 412);
             this.ck_kllb_fdtx.Margin = new System.Windows.Forms.Padding(2);
             this.ck_kllb_fdtx.Name = "ck_kllb_fdtx";
             this.ck_kllb_fdtx.Size = new System.Drawing.Size(15, 14);
@@ -797,7 +825,7 @@
             // ck_kllb_ystx
             // 
             this.ck_kllb_ystx.AutoSize = true;
-            this.ck_kllb_ystx.Location = new System.Drawing.Point(230, 374);
+            this.ck_kllb_ystx.Location = new System.Drawing.Point(229, 386);
             this.ck_kllb_ystx.Margin = new System.Windows.Forms.Padding(2);
             this.ck_kllb_ystx.Name = "ck_kllb_ystx";
             this.ck_kllb_ystx.Size = new System.Drawing.Size(15, 14);
@@ -819,7 +847,7 @@
             // label32
             // 
             this.label32.AutoSize = true;
-            this.label32.Location = new System.Drawing.Point(22, 428);
+            this.label32.Location = new System.Drawing.Point(21, 440);
             this.label32.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
             this.label32.Name = "label32";
             this.label32.Size = new System.Drawing.Size(53, 12);
@@ -829,7 +857,7 @@
             // label31
             // 
             this.label31.AutoSize = true;
-            this.label31.Location = new System.Drawing.Point(20, 402);
+            this.label31.Location = new System.Drawing.Point(19, 414);
             this.label31.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
             this.label31.Name = "label31";
             this.label31.Size = new System.Drawing.Size(53, 12);
@@ -839,7 +867,7 @@
             // label30
             // 
             this.label30.AutoSize = true;
-            this.label30.Location = new System.Drawing.Point(20, 376);
+            this.label30.Location = new System.Drawing.Point(19, 388);
             this.label30.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
             this.label30.Name = "label30";
             this.label30.Size = new System.Drawing.Size(53, 12);
@@ -1013,6 +1041,7 @@
             // panel3
             // 
             this.panel3.AutoScroll = true;
+            this.panel3.Controls.Add(this.groupBox2);
             this.panel3.Controls.Add(this.groupBox7);
             this.panel3.Controls.Add(this.groupBZ);
             this.panel3.Controls.Add(this.groupBox8);
@@ -1022,13 +1051,26 @@
             this.panel3.Controls.Add(this.groupBox1);
             this.panel3.Location = new System.Drawing.Point(714, 74);
             this.panel3.Name = "panel3";
-            this.panel3.Size = new System.Drawing.Size(287, 644);
+            this.panel3.Size = new System.Drawing.Size(288, 644);
             this.panel3.TabIndex = 74;
             // 
+            // groupBox2
+            // 
+            this.groupBox2.Controls.Add(this.ck_jzwzb_chart);
+            this.groupBox2.Controls.Add(this.label13);
+            this.groupBox2.Controls.Add(this.label12);
+            this.groupBox2.Controls.Add(this.ck_jzwzb_surface);
+            this.groupBox2.Location = new System.Drawing.Point(3, 1706);
+            this.groupBox2.Name = "groupBox2";
+            this.groupBox2.Size = new System.Drawing.Size(263, 81);
+            this.groupBox2.TabIndex = 8;
+            this.groupBox2.TabStop = false;
+            this.groupBox2.Text = "夹杂物占比表";
+            // 
             // groupBZ
             // 
             this.groupBZ.Controls.Add(this.textBox_strBZ);
-            this.groupBZ.Location = new System.Drawing.Point(5, 1696);
+            this.groupBZ.Location = new System.Drawing.Point(5, 1793);
             this.groupBZ.Name = "groupBZ";
             this.groupBZ.Size = new System.Drawing.Size(263, 139);
             this.groupBZ.TabIndex = 7;
@@ -1084,6 +1126,43 @@
             this.cb_ParticleRange.Size = new System.Drawing.Size(121, 20);
             this.cb_ParticleRange.TabIndex = 76;
             // 
+            // ck_jzwzb_surface
+            // 
+            this.ck_jzwzb_surface.AutoSize = true;
+            this.ck_jzwzb_surface.Location = new System.Drawing.Point(229, 26);
+            this.ck_jzwzb_surface.Name = "ck_jzwzb_surface";
+            this.ck_jzwzb_surface.Size = new System.Drawing.Size(15, 14);
+            this.ck_jzwzb_surface.TabIndex = 0;
+            this.ck_jzwzb_surface.UseVisualStyleBackColor = true;
+            this.ck_jzwzb_surface.CheckedChanged += new System.EventHandler(this.ck_jzwzb_surface_CheckedChanged);
+            // 
+            // label12
+            // 
+            this.label12.AutoSize = true;
+            this.label12.Location = new System.Drawing.Point(19, 28);
+            this.label12.Name = "label12";
+            this.label12.Size = new System.Drawing.Size(65, 12);
+            this.label12.TabIndex = 1;
+            this.label12.Text = "显示该模块";
+            // 
+            // label13
+            // 
+            this.label13.AutoSize = true;
+            this.label13.Location = new System.Drawing.Point(19, 53);
+            this.label13.Name = "label13";
+            this.label13.Size = new System.Drawing.Size(77, 12);
+            this.label13.TabIndex = 2;
+            this.label13.Text = "显示附加图形";
+            // 
+            // ck_jzwzb_chart
+            // 
+            this.ck_jzwzb_chart.AutoSize = true;
+            this.ck_jzwzb_chart.Location = new System.Drawing.Point(229, 53);
+            this.ck_jzwzb_chart.Name = "ck_jzwzb_chart";
+            this.ck_jzwzb_chart.Size = new System.Drawing.Size(15, 14);
+            this.ck_jzwzb_chart.TabIndex = 3;
+            this.ck_jzwzb_chart.UseVisualStyleBackColor = true;
+            // 
             // OTSReport_TemplateDesignerRM
             // 
             this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
@@ -1129,6 +1208,8 @@
             ((System.ComponentModel.ISupportInitialize)(this.pictureBox2)).EndInit();
             ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
             this.panel3.ResumeLayout(false);
+            this.groupBox2.ResumeLayout(false);
+            this.groupBox2.PerformLayout();
             this.groupBZ.ResumeLayout(false);
             this.groupBZ.PerformLayout();
             this.groupBox9.ResumeLayout(false);
@@ -1227,5 +1308,12 @@
         private System.Windows.Forms.Label ParticleList_1;
         private System.Windows.Forms.ComboBox comboBox_p1;
         private System.Windows.Forms.ComboBox cb_ParticleRange;
+        private System.Windows.Forms.CheckBox ck_kllb_fjzt;
+        private System.Windows.Forms.Label label111;
+        private System.Windows.Forms.GroupBox groupBox2;
+        private System.Windows.Forms.CheckBox ck_jzwzb_chart;
+        private System.Windows.Forms.Label label13;
+        private System.Windows.Forms.Label label12;
+        private System.Windows.Forms.CheckBox ck_jzwzb_surface;
     }
 }

+ 28 - 2
OTSIncAReportApp/1-UI/OTSTemplateDesigner/OTSReport_TemplateDesignerRM.cs

@@ -358,6 +358,7 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
                 }
                 //颗粒列表信息
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLLBXX.b_ck_kllb_xsmk.ToString(), "M_KLLBXX", "b_ck_kllb_xsmk");    //是否显示模块
+                xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLLBXX.b_ck_kllb_fjzt.ToString(), "M_KLLBXX", "b_ck_kllb_fjzt");//附加帧图
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLLBXX.index_cb_kllb_jsfs.ToString(), "M_KLLBXX", "index_cb_kllb_jsfs");    //计算方式
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLLBXX.index_cb_kllb_klfw.ToString(), "M_KLLBXX", "index_cb_kllb_klfw");    //颗粒范围
                 //xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLLBXX.int_tb_kllb_ylsx.ToString(), "M_KLLBXX", "int_tb_kllb_ylsx");    //数量上限
@@ -539,6 +540,7 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
                 }
                 //颗粒列表信息
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLLBXX.b_ck_kllb_xsmk.ToString(), "M_KLLBXX", "b_ck_kllb_xsmk");    //是否显示模块
+                xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLLBXX.b_ck_kllb_fjzt.ToString(), "M_KLLBXX", "b_ck_kllb_fjzt");//附加帧图
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLLBXX.index_cb_kllb_jsfs.ToString(), "M_KLLBXX", "index_cb_kllb_jsfs");    //计算方式
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLLBXX.index_cb_kllb_klfw.ToString(), "M_KLLBXX", "index_cb_kllb_klfw");    //颗粒范围
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLLBXX.int_tb_kllb_ylsx.ToString(), "M_KLLBXX", "int_tb_kllb_ylsx");    //数量上限
@@ -582,6 +584,11 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLLBXX.index_cb_kllb_chartSort_p2.ToString(), "M_KLLBXX", "index_cb_kllb_chartSort_p2");//帧图表列第二个可选参数(index)
                 //xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLLBXX.str_cb_kllb_chartSort_p3.ToString(), "M_KLLBXX", "str_cb_kllb_chartSort_p3");//帧图表列第三个可选参数(string)
                 //xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLLBXX.index_cb_kllb_chartSort_p3.ToString(), "M_KLLBXX", "index_cb_kllb_chartSort_p3");//帧图表列第三个可选参数(index)
+
+
+                //夹杂物占比
+                xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_JZWZB.b_ck_surface.ToString(), "M_JZWZB", "b_ck_surface");//夹杂物占比表
+                xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_JZWZB.b_ck_chart.ToString(), "M_JZWZB", "b_ck_chart");//夹杂物占比图
             }
         }
 
@@ -641,7 +648,9 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
 
             //颗粒列表信息
             m_OTSReport_Export.m_mbszclass.M_KLLBXX.b_ck_kllb_xsmk = ck_kllb_xsmk.Checked;
-            
+            m_OTSReport_Export.m_mbszclass.M_KLLBXX.b_ck_kllb_fjzt = ck_kllb_fjzt.Checked;
+
+
             m_OTSReport_Export.m_mbszclass.M_KLLBXX.str_cb_kllb_sort_p1 = comboBox_p1.Text;//颗粒列表行第一个字段的可选参数
             m_OTSReport_Export.m_mbszclass.M_KLLBXX.index_cb_kllb_sort_p1 = comboBox_p1.SelectedIndex;
             m_OTSReport_Export.m_mbszclass.M_KLLBXX.str_cb_kllb_sort_p2 = comboBox_p2.Text;//颗粒列表行第二个字段的可选参数
@@ -674,6 +683,10 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
             m_OTSReport_Export.m_mbszclass.M_SY.str_xzkl = cb_ParticleRange.Text;//颗粒范围内容
             m_OTSReport_Export.m_mbszclass.M_SY.int_xzkl = cb_ParticleRange.SelectedIndex;//颗粒范围索引
 
+            //夹杂物占比
+            m_OTSReport_Export.m_mbszclass.M_JZWZB.b_ck_surface = ck_jzwzb_surface.Checked;//夹杂物占比表
+            m_OTSReport_Export.m_mbszclass.M_JZWZB.b_ck_chart = ck_jzwzb_chart.Checked;//夹杂物占比图
+
         }
 
         private void LoadControls()
@@ -732,7 +745,8 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
 
             //颗粒列表信息
             ck_kllb_xsmk.Checked = m_OTSReport_Export.m_mbszclass.M_KLLBXX.b_ck_kllb_xsmk;
-          
+            ck_kllb_fjzt.Checked = m_OTSReport_Export.m_mbszclass.M_KLLBXX.b_ck_kllb_fjzt;
+
             ck_kllb_ystx.Checked = m_OTSReport_Export.m_mbszclass.M_KLLBXX.b_ck_kllb_ystx;//原始图像
             ck_kllb_fdtx.Checked = m_OTSReport_Export.m_mbszclass.M_KLLBXX.b_ck_kllb_fdtx;//放大图像
             ck_kllb_npxx.Checked = m_OTSReport_Export.m_mbszclass.M_KLLBXX.b_ck_kllb_npxx;//能谱图像
@@ -744,6 +758,10 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
             cb_FrameChart_p1.SelectedIndex = m_OTSReport_Export.m_mbszclass.M_KLLBXX.index_cb_kllb_chartSort_p1;
             cb_FrameChart_p2.SelectedIndex = m_OTSReport_Export.m_mbszclass.M_KLLBXX.index_cb_kllb_chartSort_p2;
             //cb_FrameChart_p3.SelectedIndex = m_OTSReport_Export.m_mbszclass.M_KLLBXX.index_cb_kllb_chartSort_p3;
+
+            //夹杂物占比
+            ck_jzwzb_surface.Checked = m_OTSReport_Export.m_mbszclass.M_JZWZB.b_ck_surface;//夹杂物占比表
+            ck_jzwzb_chart.Checked = m_OTSReport_Export.m_mbszclass.M_JZWZB.b_ck_chart;//夹杂物占比图
         }
 
         /// <summary>
@@ -1181,5 +1199,13 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
             }
             tb_ysfx_xsys.Text = str;
         }
+
+        private void ck_jzwzb_surface_CheckedChanged(object sender, EventArgs e)
+        {
+            if (ck_jzwzb_surface.Checked==false)
+            {
+                ck_jzwzb_chart.Checked = false;
+            }
+        }
     }
 }

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