Browse Source

报告导出BUG修正

zhangjiaxin 1 year ago
parent
commit
938da51a0c

+ 2 - 2
Bin/x64/Debug/Config/ProData/HardwareConfig.xml

@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <XMLData PathName="HardwareConfig.xml" ID="1">
-  <Member RegName="SemControllerName" Value="Bruker" ImageInputSources="SE" />
-  <Member RegName="EDSName" Value="Bruker" DelayQuantify="true" />
+  <Member RegName="SemControllerName" Value="OffLine" ImageInputSources="SE" />
+  <Member RegName="EDSName" Value="OffLine" DelayQuantify="true" />
   <Member RegName="BrukerDllVersion" Version="Bruker.API.Esprit64.dll" />
   <Member RegName="FEIIP" Value="192.168.0.1" />
   <Member RegName="FEIPORT" Value="7520" />

+ 12 - 6
Bin/x64/Debug/Config/ReportTemplate/ReportTemplateConfig.xml

@@ -1,7 +1,8 @@
 <XmlConfig>
   <M_SY>
-    <str_tb_ZBT>Cleanness Report</str_tb_ZBT>
-    <str_tb_FBT>宁德时代</str_tb_FBT>
+    <str_tb_ZBT>夹杂物报告</str_tb_ZBT>
+    <str_tb_FBT>
+    </str_tb_FBT>
     <str_tb_YPBH>0001</str_tb_YPBH>
     <str_tb_CKBZ>
     </str_tb_CKBZ>
@@ -13,10 +14,11 @@
     <int_xzkl>0</int_xzkl>
   </M_SY>
   <M_YMYJ>
-    <str_tb_ymwb>锂电异物分析报告</str_tb_ymwb>
+    <str_tb_ymwb>夹杂物分析报告</str_tb_ymwb>
     <str_tb_KHH>Copi0000123012</str_tb_KHH>
     <b_ck_ym>True</b_ck_ym>
-    <str_tb_yjwb>OTS Result</str_tb_yjwb>
+    <str_tb_yjwb>
+    </str_tb_yjwb>
   </M_YMYJ>
   <M_KLFXJG>
     <b_ck_klcc_xsmk>True</b_ck_klcc_xsmk>
@@ -29,9 +31,12 @@
     <index_cb_jzwfl_ljb>0</index_cb_jzwfl_ljb>
     <index_cb_jzwfl_klfw>0</index_cb_jzwfl_klfw>
     <str_cb_klcc_jsfs>CIRCLE</str_cb_klcc_jsfs>
+    <b_ck_klcc_dfl>True</b_ck_klcc_dfl>
+    <b_ck_klcc_xfl>True</b_ck_klcc_xfl>
+    <b_ck_klcc_xsddt>True</b_ck_klcc_xsddt>
   </M_KLFXJG>
   <M_YSFXJG>
-    <b_ck_ysfx_xsmk>False</b_ck_ysfx_xsmk>
+    <b_ck_ysfx_xsmk>True</b_ck_ysfx_xsmk>
     <index_cb_yxfx_jsfs>0</index_cb_yxfx_jsfs>
     <index_cb_ysfx_klfw>0</index_cb_ysfx_klfw>
     <str_tb_ysfx_xsys>Al,Si,C,S,N,O,Fe,Ti,Mn,Mg,Ca,Ce,La</str_tb_ysfx_xsys>
@@ -115,12 +120,13 @@
     <list_str_kllb_DeleteClass>
       <YS0>misc</YS0>
     </list_str_kllb_DeleteClass>
+    <list_int_kllb_number>20</list_int_kllb_number>
   </M_KLLBXX>
   <M_address>
     <Path>./Config/ReportTemplate/ReportTemplateConfig.xml</Path>
   </M_address>
   <M_JZWZB>
-    <b_ck_surface>False</b_ck_surface>
+    <b_ck_surface>True</b_ck_surface>
     <b_ck_chart>False</b_ck_chart>
   </M_JZWZB>
 </XmlConfig>

+ 2 - 3
OTSIncAMeasureApp/OTSIncAMeasureApp.csproj

@@ -232,9 +232,8 @@
       <HintPath>..\OpenDll\WordApiDll\OTS.WinFormsUI.Docking.dll</HintPath>
       <Private>False</Private>
     </Reference>
-    <Reference Include="OxfordExtenderWrapper, Version=1.0.0.0, Culture=neutral, processorArchitecture=AMD64">
-      <SpecificVersion>False</SpecificVersion>
-      <HintPath>..\Bin\x64\Release_oxford61\OxfordExtender\OxfordExtenderWrapper.exe</HintPath>
+    <Reference Include="OxfordExtenderWrapper">
+      <HintPath>..\Bin\x64\Debug\OxfordExtender\OxfordExtenderWrapper.exe</HintPath>
       <Private>False</Private>
     </Reference>
     <Reference Include="SlmRuntimeCSharp, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">

+ 244 - 0
OTSIncAReportApp/1-UI/OTSTemplateDesigner/Export_ReportTemplate.cs

@@ -1588,6 +1588,250 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
             partsize_dt = ls_partsize_dt.Copy();
         }
 
+        public DataTable ParticleResults(c_TemplateClass m_mbszclass)
+        {
+            if (m_bt_DBData.Columns.Count == 0)
+            {
+                GetDBData(m_mbszclass);
+            }
+
+            List<string> colid = new List<string>();
+            //获取粒级表
+            string path1 = m_otsreport_export.m_ReportApp.m_rstDataMgr.m_RptConfigFile.PartSizeFileFolder + m_otsreport_export.m_ReportApp.m_rstDataMgr.m_RptConfigFile.PartSizeFile;
+            DataSet ds = OTSIncAReportApp.DataOperation.DataAccess.XMLoperate.GetXml(path1);
+            string sizestr = ds.Tables[0].Rows[0]["Sizes"].ToString();
+
+            for (int i = 0; i < sizestr.Split(',').Length - 1; i++)
+            {
+                if (sizestr.Split(',')[i].Length > 0)
+                {
+                    double d1 = Convert.ToDouble(sizestr.Split(',')[i]);
+                    double d2 = Convert.ToDouble(sizestr.Split(',')[i + 1]);
+                    colid.Add(d1.ToString() + "~" + d2.ToString());
+                }
+            }
+            double d = Convert.ToDouble(sizestr.Split(',')[sizestr.Split(',').Length - 1]);
+            colid.Add(d.ToString() + "~MAX");
+            ParticleData fielddata = new ParticleData(m_otsreport_export.m_ReportApp.m_rstDataMgr.ResultFilesList[m_otsreport_export.m_ReportApp.m_rstDataMgr.getSelectedIndex()].FilePath);
+
+
+            //------------------------------------------------
+            DataTable ls_partsize_dt = new DataTable();
+            ls_partsize_dt.TableName = "PartSize";
+            ls_partsize_dt.Columns.Add("c1");
+            ls_partsize_dt.Columns.Add("c2");
+            ls_partsize_dt.Columns.Add("c3");
+            ls_partsize_dt.Columns.Add("c4");
+            ls_partsize_dt.Columns.Add("c5");
+            ls_partsize_dt.Columns.Add("c6");
+            ls_partsize_dt.Columns.Add("c7");
+            ls_partsize_dt.Columns.Add("c8");
+            ls_partsize_dt.Columns.Add("c9");
+            ls_partsize_dt.Columns.Add("c10");
+            DataRow dr = ls_partsize_dt.NewRow();
+            for (int i = 1; i < 11; i++)
+            {
+                if (colid.Count < i)
+                {
+                    dr["c" + i.ToString()] = " ";
+                }
+                else
+                {
+                    dr["c" + i.ToString()] = colid[i - 1];
+                }
+            }
+            ls_partsize_dt.Rows.Add(dr);
+
+
+            DataTable ls_Particel_dt = new DataTable();
+            ls_Particel_dt.TableName = "Particel";
+
+            ls_Particel_dt.Columns.Add("c1");
+            ls_Particel_dt.Columns.Add("c2");
+            ls_Particel_dt.Columns.Add("c3");
+            ls_Particel_dt.Columns.Add("c4");
+            ls_Particel_dt.Columns.Add("c5");
+            ls_Particel_dt.Columns.Add("c6");
+            ls_Particel_dt.Columns.Add("c7");
+            ls_Particel_dt.Columns.Add("c8");
+            ls_Particel_dt.Columns.Add("c9");
+            ls_Particel_dt.Columns.Add("c10");
+            ls_Particel_dt.Columns.Add("Name");
+            ls_Particel_dt.Columns.Add("total");
+            ls_Particel_dt.Columns.Add("TypeId");
+            
+
+            for (int i = 0; i < m_bt_DBData.Rows.Count; i++)
+            {
+                DataRow dr2 = ls_Particel_dt.NewRow();
+                dr2["Name"] = m_bt_DBData.Rows[i]["TypeName"].ToString();
+               
+                dr2["TypeId"] = m_bt_DBData.Rows[i]["TypeId"].ToString();//获取分类编号
+                for (int j = 1; j < 11; j++)
+                {
+                    if (colid.Count >= j)
+                    {
+                        double de = Convert.ToDouble(m_bt_DBData.Rows[i][colid[j - 1]]);
+                        if (de == 0)
+                            dr2["c" + j.ToString()] = " ";
+                        else
+                            dr2["c" + j.ToString()] = de.ToString();
+                    }
+                }
+                if (dr2["Name"].ToString() != "" && dr2["Name"].ToString().IndexOf("number") < 0)
+                {
+                    dr2["total"] = " "; //求合
+                    double d_total = 0;
+
+                    for (int j = 1; j < 11; j++)
+                    {
+                        if (colid.Count >= j)
+                        {
+                            d_total = d_total + Convert.ToInt64(m_bt_DBData.Rows[i][colid[j - 1]]);
+                        }
+                    }
+                    if (d_total == 0)
+                    {
+                        continue;
+                        dr2["total"] = " ";
+                    }
+                    else
+                        dr2["total"] = d_total.ToString();
+                }
+                ls_Particel_dt.Rows.Add(dr2);
+            }
+            return ls_Particel_dt;
+        }
+
+        public DataTable TypeRange()
+        {
+            List<string> colid = new List<string>();
+            //获取粒级表
+            string path1 = m_otsreport_export.m_ReportApp.m_rstDataMgr.m_RptConfigFile.PartSizeFileFolder + m_otsreport_export.m_ReportApp.m_rstDataMgr.m_RptConfigFile.PartSizeFile;
+            DataSet ds = OTSIncAReportApp.DataOperation.DataAccess.XMLoperate.GetXml(path1);
+            string sizestr = ds.Tables[0].Rows[0]["Sizes"].ToString();
+
+            for (int i = 0; i < sizestr.Split(',').Length - 1; i++)
+            {
+                if (sizestr.Split(',')[i].Length > 0)
+                {
+                    double d1 = Convert.ToDouble(sizestr.Split(',')[i]);
+                    double d2 = Convert.ToDouble(sizestr.Split(',')[i + 1]);
+                    colid.Add(d1.ToString() + "≤ X<" + d2.ToString());
+                }
+            }
+            double d = Convert.ToDouble(sizestr.Split(',')[sizestr.Split(',').Length - 1]);
+            colid.Add(d.ToString() + "≤ X<MAX");
+
+            DataTable ls_partsize_dt = new DataTable();
+            ls_partsize_dt.TableName = "PartSize";
+            ls_partsize_dt.Columns.Add("c1");
+            ls_partsize_dt.Columns.Add("c2");
+            ls_partsize_dt.Columns.Add("c3");
+            ls_partsize_dt.Columns.Add("c4");
+            ls_partsize_dt.Columns.Add("c5");
+            ls_partsize_dt.Columns.Add("c6");
+            ls_partsize_dt.Columns.Add("c7");
+            ls_partsize_dt.Columns.Add("c8");
+            ls_partsize_dt.Columns.Add("c9");
+            ls_partsize_dt.Columns.Add("c10");
+            ls_partsize_dt.Columns.Add("c11");
+            ls_partsize_dt.Columns.Add("c12");
+
+            DataRow dr = ls_partsize_dt.NewRow();
+            for (int i = 1; i < 13; i++)
+            {
+                if (colid.Count < i)
+                {
+                    dr["c" + i.ToString()] = "";
+                }
+                else
+                {
+                    dr["c" + i.ToString()] = colid[i - 1];
+                }
+            }
+            ls_partsize_dt.Rows.Add(dr);
+
+            return ls_partsize_dt;
+        }
+
+        public void ChemistryTable(c_TemplateClass m_mbszclass, out DataTable b1,out DataTable b2)
+        {
+            if (m_bt_DBData.Columns.Count == 0)
+            {
+                GetDBData(m_mbszclass);
+            }
+
+            //根据sql条件,查询获取颗粒信息数据
+            ParticleData fielddata = new ParticleData(m_otsreport_export.m_ReportApp.m_rstDataMgr.ResultFilesList[m_otsreport_export.m_ReportApp.m_rstDataMgr.getSelectedIndex()].FilePath);
+
+            DataTable AllAnalysisDetails = new DataTable();
+            AllAnalysisDetails.TableName = "ElementValue";
+            AllAnalysisDetails.Columns.Add("Name");
+            AllAnalysisDetails.Columns.Add("TypeId");
+            AllAnalysisDetails.Columns.Add("Area", typeof(double));
+            AllAnalysisDetails.Columns.Add("Class");
+            AllAnalysisDetails.Columns.Add("con");
+            double  total = 0;
+            for (int i = 0; i < m_bt_DBData.Rows.Count; i++)
+            {
+                DataRow dr2 = AllAnalysisDetails.NewRow();
+                dr2["Name"] = m_bt_DBData.Rows[i]["TypeName"].ToString();
+                dr2["Area"] = Convert.ToDouble(m_bt_DBData.Rows[i]["ar"]);
+                dr2["TypeId"] = m_bt_DBData.Rows[i]["TypeId"].ToString();
+                dr2["Class"] = m_bt_DBData.Rows[i]["Class"].ToString();
+                dr2["con"] = m_bt_DBData.Rows[i]["con"].ToString();
+                total += Convert.ToInt32(m_bt_DBData.Rows[i]["con"]);
+                AllAnalysisDetails.Rows.Add(dr2);
+            }
+            //按照list列表进行物质类排序,物质类中的元素分类按照面积的大小进行排序
+            List<string> ClassName = new List<string>();
+            DataTable getClass_dt = fielddata.GetAllClass();
+            for (int i = 0; i < getClass_dt.Rows.Count; i++)
+            {
+                if (getClass_dt.Rows[i]["GroupName"].ToString() != "NOT_INCLUTION" && getClass_dt.Rows[i]["GroupName"].ToString() != "Invalid")
+                    ClassName.Add(getClass_dt.Rows[i]["GroupName"].ToString());
+            }
+            //统计元素物质大类的元素信息和面积占比
+            DataTable dt_ElementalSubstance = ElementalSubstance(AllAnalysisDetails, ClassName, fielddata);
+            //统计元素并按照Class Name自定义列表进行排序,大类中的小类元素信息按照面积从大到小排序
+            DataTable dt_ElementSorting = ElementSorting(AllAnalysisDetails, ClassName, fielddata);
+            //生成最后导出时物质元素成分表
+            DataTable dt = MaterialElementComposition(dt_ElementalSubstance, 13);//导出14个元素成分信息
+
+            //生成最后导出时物质元素细分表
+            SubdivisionOfMaterialElements(dt_ElementSorting, 13, ClassName, dt, out DataTable dt1, out DataTable dt2);
+            dt2.Columns.Add("con");
+            dt2.Columns.Add("per");
+            dt1.Columns.Add("con");
+            dt1.Columns.Add("per");
+            DataTable table = dt2.Copy();
+            table.Clear();
+            //table.Columns.Add("con");
+            int inxe = 0;
+            for(int i=0;i< dt2.Rows.Count;i++)
+            {
+               if(string.IsNullOrWhiteSpace(dt2.Rows[i]["Class"].ToString()))
+                {
+                    
+                    for (int a=0;a< AllAnalysisDetails.Rows.Count;a++)
+                    {
+                        if(dt2.Rows[i]["Name"].ToString()== AllAnalysisDetails.Rows[a]["Name"].ToString())
+                        {
+                            dt2.Rows[i]["con"] = AllAnalysisDetails.Rows[a]["con"];
+                            dt2.Rows[i]["per"] = (Convert.ToDouble(AllAnalysisDetails.Rows[a]["con"]) / total) * 100;
+                        }
+                    }
+                    table.Rows.Add(dt2.Rows[i].ItemArray);
+                }
+                inxe++;
+            }
+            b1 = dt1.Copy();
+            b2 = table.Copy();
+            //return dt;
+        }
+     
+
         private DataTable classIfIcationSort(DataTable dataTable, List<string> ClassName, DataTable data)
         {
             DataTable dt = new DataTable();

+ 14 - 2
OTSIncAReportApp/1-UI/OTSTemplateDesigner/OTSReport_Export.cs

@@ -45,6 +45,7 @@ namespace OTSIncAReportApp
         public XmlOperateUtil xmlutil2;
         public c_TemplateClass m_mbszclass = null;
         OTS_DEVReport DEVReport;
+        
         GBReport GB_Report;
         /*public bool ReportExporting = false;*///判断报告是不在是在导出的过程中
 
@@ -233,6 +234,10 @@ namespace OTSIncAReportApp
                 /// 是否显示颗粒尺寸分析结果表
                 /// </summary>
                 public bool b_ck_klcc_xsmk { get; set; }
+                /// <summary>
+                /// 是否显示颗粒尺寸 堆叠图
+                /// </summary>
+                public bool b_ck_klcc_xsddt { get; set; }
 
                 /// <summary>
                 ///颗粒尺寸分析结果表 计算方式文本
@@ -673,6 +678,7 @@ namespace OTSIncAReportApp
 
             //颗粒分析结果
             m_mbszclass.M_KLFXJG.b_ck_klcc_xsmk = Convert.ToBoolean(xmlutil2.Read("M_KLFXJG", "b_ck_klcc_xsmk"));//是否显示模块
+            m_mbszclass.M_KLFXJG.b_ck_klcc_xsddt = Convert.ToBoolean(xmlutil2.Read("M_KLFXJG", "b_ck_klcc_xsddt"));
             m_mbszclass.M_KLFXJG.index_cb_klcc_jsfs = Convert.ToInt32(xmlutil2.Read("M_KLFXJG", "index_cb_klcc_jsfs"));//计算方式
             m_mbszclass.M_KLFXJG.str_cb_klcc_jsfs = Convert.ToString(xmlutil2.Read("M_KLFXJG", "str_cb_klcc_jsfs"));//计算方式
             m_mbszclass.M_KLFXJG.index_cb_klcc_ljb = Convert.ToInt32(xmlutil2.Read("M_KLFXJG", "index_cb_klcc_ljb"));//粒级表
@@ -1557,7 +1563,7 @@ namespace OTSIncAReportApp
                         if (m_mbszclass.M_KLFXJG.b_ck_klcc_xsmk)
                         {
                             //DEVReport.setParticleSizeTable(true, false);
-                            DEVReport.setParticleSizeTable(m_mbszclass.M_KLFXJG.b_ck_klcc_dfl, m_mbszclass.M_KLFXJG.b_ck_klcc_xfl);
+                            DEVReport.setParticleSizeTable(m_mbszclass.M_KLFXJG.b_ck_klcc_dfl, m_mbszclass.M_KLFXJG.b_ck_klcc_xfl, m_mbszclass.M_KLFXJG.b_ck_klcc_xsddt);
                         }
                             //DEVReport.setParticleSizeTable(true,false);
                         lock (m_thread_flag)
@@ -1681,6 +1687,7 @@ namespace OTSIncAReportApp
                 m_mbszclass.M_YMYJ.str_tb_yjwb = xmlutil.Read("M_YMYJ", "str_tb_yjwb");
                 //颗粒分析结果
                 m_mbszclass.M_KLFXJG.b_ck_klcc_xsmk = Convert.ToBoolean(xmlutil.Read("M_KLFXJG", "b_ck_klcc_xsmk"));//是否显示模块
+                m_mbszclass.M_KLFXJG.b_ck_klcc_xsddt = Convert.ToBoolean(xmlutil.Read("M_KLFXJG", "b_ck_klcc_xsddt"));
                 m_mbszclass.M_KLFXJG.index_cb_klcc_jsfs = Convert.ToInt32(xmlutil.Read("M_KLFXJG", "index_cb_klcc_jsfs"));//计算方式
                 m_mbszclass.M_KLFXJG.index_cb_klcc_ljb = Convert.ToInt32(xmlutil.Read("M_KLFXJG", "index_cb_klcc_ljb"));//粒级表
                 m_mbszclass.M_KLFXJG.index_cb_klcc_klfw = Convert.ToInt32(xmlutil.Read("M_KLFXJG", "index_cb_klcc_klfw"));//颗粒范围
@@ -1823,7 +1830,7 @@ namespace OTSIncAReportApp
             //DEVReport = new OTS_DEVReport(this);
 
             DEVReport.setResultGrid();
-            DEVReport.setParticleSizeTable(true,true);
+            DEVReport.setParticleSizeTable(true,true,true);
             DEVReport.setElementAvgGrid();
             DEVReport.setINCAtable();
             DEVReport.set_incaPIC_classify();
@@ -1854,6 +1861,11 @@ namespace OTSIncAReportApp
             DataTable dt_stl = sh.ExecuteQuery("select * from "+ Language);
             return dt_stl;
         }
+
+        private void button2_Click_1(object sender, EventArgs e)
+        {
+       
+        }
     }
     
 }

+ 128 - 102
OTSIncAReportApp/1-UI/OTSTemplateDesigner/OTSReport_TemplateDesignerRM.Designer.cs

@@ -53,6 +53,10 @@
             this.tb_ymwb = new System.Windows.Forms.TextBox();
             this.label8 = new System.Windows.Forms.Label();
             this.groupBox4 = new System.Windows.Forms.GroupBox();
+            this.checkBox2 = new System.Windows.Forms.CheckBox();
+            this.checkBox1 = new System.Windows.Forms.CheckBox();
+            this.label11zxc = new System.Windows.Forms.Label();
+            this.label1121ad = new System.Windows.Forms.Label();
             this.ck_klcc_xsmk = new System.Windows.Forms.CheckBox();
             this.label17 = new System.Windows.Forms.Label();
             this.cb_klcc_ljb = new System.Windows.Forms.ComboBox();
@@ -76,6 +80,8 @@
             this.label33 = new System.Windows.Forms.Label();
             this.label42 = new System.Windows.Forms.Label();
             this.groupBox8 = new System.Windows.Forms.GroupBox();
+            this.numericMin = new System.Windows.Forms.NumericUpDown();
+            this.label112121 = new System.Windows.Forms.Label();
             this.label_delete_Class = new System.Windows.Forms.Label();
             this.delete_Class = new System.Windows.Forms.TextBox();
             this.label11111 = new System.Windows.Forms.Label();
@@ -117,17 +123,14 @@
             this.groupBox9 = new System.Windows.Forms.GroupBox();
             this.label39 = new System.Windows.Forms.Label();
             this.cb_ParticleRange = new System.Windows.Forms.ComboBox();
-            this.label112121 = new System.Windows.Forms.Label();
-            this.numericMin = new System.Windows.Forms.NumericUpDown();
-            this.label1121ad = new System.Windows.Forms.Label();
-            this.label11zxc = new System.Windows.Forms.Label();
-            this.checkBox1 = new System.Windows.Forms.CheckBox();
-            this.checkBox2 = new System.Windows.Forms.CheckBox();
+            this.label11 = new System.Windows.Forms.Label();
+            this.ck_klcc_xsddt = new System.Windows.Forms.CheckBox();
             this.groupBox1.SuspendLayout();
             this.groupBox4.SuspendLayout();
             this.groupBox6.SuspendLayout();
             this.groupBox7.SuspendLayout();
             this.groupBox8.SuspendLayout();
+            ((System.ComponentModel.ISupportInitialize)(this.numericMin)).BeginInit();
             this.groupBox_zt.SuspendLayout();
             this.groupBox_px.SuspendLayout();
             this.panel2.SuspendLayout();
@@ -142,7 +145,6 @@
             this.groupBox211.SuspendLayout();
             this.groupBZ.SuspendLayout();
             this.groupBox9.SuspendLayout();
-            ((System.ComponentModel.ISupportInitialize)(this.numericMin)).BeginInit();
             this.SuspendLayout();
             // 
             // tb_FBT
@@ -150,7 +152,7 @@
             this.tb_FBT.Location = new System.Drawing.Point(5, 83);
             this.tb_FBT.Margin = new System.Windows.Forms.Padding(2);
             this.tb_FBT.Name = "tb_FBT";
-            this.tb_FBT.Size = new System.Drawing.Size(258, 21);
+            this.tb_FBT.Size = new System.Drawing.Size(252, 21);
             this.tb_FBT.TabIndex = 20;
             // 
             // tb_ZBT
@@ -158,7 +160,7 @@
             this.tb_ZBT.Location = new System.Drawing.Point(5, 35);
             this.tb_ZBT.Margin = new System.Windows.Forms.Padding(2);
             this.tb_ZBT.Name = "tb_ZBT";
-            this.tb_ZBT.Size = new System.Drawing.Size(258, 21);
+            this.tb_ZBT.Size = new System.Drawing.Size(252, 21);
             this.tb_ZBT.TabIndex = 10;
             // 
             // label5
@@ -218,7 +220,7 @@
             this.tb_YPBH.Location = new System.Drawing.Point(5, 138);
             this.tb_YPBH.Margin = new System.Windows.Forms.Padding(2);
             this.tb_YPBH.Name = "tb_YPBH";
-            this.tb_YPBH.Size = new System.Drawing.Size(258, 21);
+            this.tb_YPBH.Size = new System.Drawing.Size(252, 21);
             this.tb_YPBH.TabIndex = 30;
             // 
             // label4
@@ -236,7 +238,7 @@
             this.tb_CKBZ.Location = new System.Drawing.Point(5, 189);
             this.tb_CKBZ.Margin = new System.Windows.Forms.Padding(2);
             this.tb_CKBZ.Name = "tb_CKBZ";
-            this.tb_CKBZ.Size = new System.Drawing.Size(258, 21);
+            this.tb_CKBZ.Size = new System.Drawing.Size(252, 21);
             this.tb_CKBZ.TabIndex = 50;
             // 
             // ck_jggk
@@ -296,7 +298,7 @@
             this.tb_yjwb.Location = new System.Drawing.Point(7, 89);
             this.tb_yjwb.Margin = new System.Windows.Forms.Padding(2);
             this.tb_yjwb.Name = "tb_yjwb";
-            this.tb_yjwb.Size = new System.Drawing.Size(256, 21);
+            this.tb_yjwb.Size = new System.Drawing.Size(250, 21);
             this.tb_yjwb.TabIndex = 42;
             // 
             // label10
@@ -324,7 +326,7 @@
             this.tb_khh.Location = new System.Drawing.Point(7, 147);
             this.tb_khh.Margin = new System.Windows.Forms.Padding(2);
             this.tb_khh.Name = "tb_khh";
-            this.tb_khh.Size = new System.Drawing.Size(256, 21);
+            this.tb_khh.Size = new System.Drawing.Size(250, 21);
             this.tb_khh.TabIndex = 42;
             this.tb_khh.Visible = false;
             // 
@@ -353,7 +355,7 @@
             this.groupBox1.Margin = new System.Windows.Forms.Padding(2);
             this.groupBox1.Name = "groupBox1";
             this.groupBox1.Padding = new System.Windows.Forms.Padding(2);
-            this.groupBox1.Size = new System.Drawing.Size(268, 181);
+            this.groupBox1.Size = new System.Drawing.Size(263, 181);
             this.groupBox1.TabIndex = 0;
             this.groupBox1.TabStop = false;
             this.groupBox1.Text = "页眉页脚设置";
@@ -363,7 +365,7 @@
             this.tb_ymwb.Location = new System.Drawing.Point(7, 33);
             this.tb_ymwb.Margin = new System.Windows.Forms.Padding(2);
             this.tb_ymwb.Name = "tb_ymwb";
-            this.tb_ymwb.Size = new System.Drawing.Size(256, 21);
+            this.tb_ymwb.Size = new System.Drawing.Size(250, 21);
             this.tb_ymwb.TabIndex = 42;
             // 
             // label8
@@ -378,6 +380,8 @@
             // 
             // groupBox4
             // 
+            this.groupBox4.Controls.Add(this.ck_klcc_xsddt);
+            this.groupBox4.Controls.Add(this.label11);
             this.groupBox4.Controls.Add(this.checkBox2);
             this.groupBox4.Controls.Add(this.checkBox1);
             this.groupBox4.Controls.Add(this.label11zxc);
@@ -392,11 +396,51 @@
             this.groupBox4.Margin = new System.Windows.Forms.Padding(2);
             this.groupBox4.Name = "groupBox4";
             this.groupBox4.Padding = new System.Windows.Forms.Padding(2);
-            this.groupBox4.Size = new System.Drawing.Size(268, 188);
+            this.groupBox4.Size = new System.Drawing.Size(263, 219);
             this.groupBox4.TabIndex = 2;
             this.groupBox4.TabStop = false;
             this.groupBox4.Text = "颗粒尺寸分析结果";
             // 
+            // checkBox2
+            // 
+            this.checkBox2.AutoSize = true;
+            this.checkBox2.Location = new System.Drawing.Point(224, 100);
+            this.checkBox2.Margin = new System.Windows.Forms.Padding(2);
+            this.checkBox2.Name = "checkBox2";
+            this.checkBox2.Size = new System.Drawing.Size(15, 14);
+            this.checkBox2.TabIndex = 57;
+            this.checkBox2.UseVisualStyleBackColor = true;
+            // 
+            // checkBox1
+            // 
+            this.checkBox1.AutoSize = true;
+            this.checkBox1.Location = new System.Drawing.Point(224, 77);
+            this.checkBox1.Margin = new System.Windows.Forms.Padding(2);
+            this.checkBox1.Name = "checkBox1";
+            this.checkBox1.Size = new System.Drawing.Size(15, 14);
+            this.checkBox1.TabIndex = 56;
+            this.checkBox1.UseVisualStyleBackColor = true;
+            // 
+            // label11zxc
+            // 
+            this.label11zxc.AutoSize = true;
+            this.label11zxc.Location = new System.Drawing.Point(12, 100);
+            this.label11zxc.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
+            this.label11zxc.Name = "label11zxc";
+            this.label11zxc.Size = new System.Drawing.Size(65, 12);
+            this.label11zxc.TabIndex = 55;
+            this.label11zxc.Text = "显示小分类";
+            // 
+            // label1121ad
+            // 
+            this.label1121ad.AutoSize = true;
+            this.label1121ad.Location = new System.Drawing.Point(12, 77);
+            this.label1121ad.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
+            this.label1121ad.Name = "label1121ad";
+            this.label1121ad.Size = new System.Drawing.Size(65, 12);
+            this.label1121ad.TabIndex = 54;
+            this.label1121ad.Text = "显示大分类";
+            // 
             // ck_klcc_xsmk
             // 
             this.ck_klcc_xsmk.AutoSize = true;
@@ -421,7 +465,7 @@
             // 
             this.cb_klcc_ljb.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
             this.cb_klcc_ljb.FormattingEnabled = true;
-            this.cb_klcc_ljb.Location = new System.Drawing.Point(23, 156);
+            this.cb_klcc_ljb.Location = new System.Drawing.Point(23, 186);
             this.cb_klcc_ljb.Margin = new System.Windows.Forms.Padding(2);
             this.cb_klcc_ljb.Name = "cb_klcc_ljb";
             this.cb_klcc_ljb.Size = new System.Drawing.Size(216, 20);
@@ -431,7 +475,7 @@
             // 
             this.cb_klcc_jsfs.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
             this.cb_klcc_jsfs.FormattingEnabled = true;
-            this.cb_klcc_jsfs.Location = new System.Drawing.Point(23, 111);
+            this.cb_klcc_jsfs.Location = new System.Drawing.Point(23, 141);
             this.cb_klcc_jsfs.Margin = new System.Windows.Forms.Padding(2);
             this.cb_klcc_jsfs.Name = "cb_klcc_jsfs";
             this.cb_klcc_jsfs.Size = new System.Drawing.Size(216, 20);
@@ -440,7 +484,7 @@
             // label15
             // 
             this.label15.AutoSize = true;
-            this.label15.Location = new System.Drawing.Point(23, 141);
+            this.label15.Location = new System.Drawing.Point(23, 171);
             this.label15.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
             this.label15.Name = "label15";
             this.label15.Size = new System.Drawing.Size(65, 12);
@@ -450,7 +494,7 @@
             // label14
             // 
             this.label14.AutoSize = true;
-            this.label14.Location = new System.Drawing.Point(21, 97);
+            this.label14.Location = new System.Drawing.Point(21, 127);
             this.label14.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
             this.label14.Name = "label14";
             this.label14.Size = new System.Drawing.Size(53, 12);
@@ -465,11 +509,11 @@
             this.groupBox6.Controls.Add(this.button4);
             this.groupBox6.Controls.Add(this.ck_ysfx_xsmk);
             this.groupBox6.Controls.Add(this.label25);
-            this.groupBox6.Location = new System.Drawing.Point(3, 640);
+            this.groupBox6.Location = new System.Drawing.Point(3, 744);
             this.groupBox6.Margin = new System.Windows.Forms.Padding(2);
             this.groupBox6.Name = "groupBox6";
             this.groupBox6.Padding = new System.Windows.Forms.Padding(2);
-            this.groupBox6.Size = new System.Drawing.Size(268, 134);
+            this.groupBox6.Size = new System.Drawing.Size(263, 134);
             this.groupBox6.TabIndex = 4;
             this.groupBox6.TabStop = false;
             this.groupBox6.Text = "元素分析表";
@@ -544,11 +588,11 @@
             this.groupBox7.Controls.Add(this.label38);
             this.groupBox7.Controls.Add(this.label33);
             this.groupBox7.Controls.Add(this.label42);
-            this.groupBox7.Location = new System.Drawing.Point(3, 778);
+            this.groupBox7.Location = new System.Drawing.Point(3, 882);
             this.groupBox7.Margin = new System.Windows.Forms.Padding(2);
             this.groupBox7.Name = "groupBox7";
             this.groupBox7.Padding = new System.Windows.Forms.Padding(2);
-            this.groupBox7.Size = new System.Drawing.Size(263, 471);
+            this.groupBox7.Size = new System.Drawing.Size(263, 427);
             this.groupBox7.TabIndex = 7;
             this.groupBox7.TabStop = false;
             this.groupBox7.Text = "三元相图";
@@ -558,7 +602,7 @@
             this.lbv_syxt_mblb.CheckBoxes = true;
             this.lbv_syxt_mblb.FullRowSelect = true;
             this.lbv_syxt_mblb.HideSelection = false;
-            this.lbv_syxt_mblb.Location = new System.Drawing.Point(8, 199);
+            this.lbv_syxt_mblb.Location = new System.Drawing.Point(8, 161);
             this.lbv_syxt_mblb.Margin = new System.Windows.Forms.Padding(2);
             this.lbv_syxt_mblb.Name = "lbv_syxt_mblb";
             this.lbv_syxt_mblb.Size = new System.Drawing.Size(249, 258);
@@ -590,7 +634,7 @@
             // 
             this.cb_syxt_ljb.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
             this.cb_syxt_ljb.FormattingEnabled = true;
-            this.cb_syxt_ljb.Location = new System.Drawing.Point(14, 73);
+            this.cb_syxt_ljb.Location = new System.Drawing.Point(14, 59);
             this.cb_syxt_ljb.Margin = new System.Windows.Forms.Padding(2);
             this.cb_syxt_ljb.Name = "cb_syxt_ljb";
             this.cb_syxt_ljb.Size = new System.Drawing.Size(214, 20);
@@ -600,7 +644,7 @@
             // 
             this.cb_syxt_mhxssl.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
             this.cb_syxt_mhxssl.FormattingEnabled = true;
-            this.cb_syxt_mhxssl.Location = new System.Drawing.Point(14, 129);
+            this.cb_syxt_mhxssl.Location = new System.Drawing.Point(14, 106);
             this.cb_syxt_mhxssl.Margin = new System.Windows.Forms.Padding(2);
             this.cb_syxt_mhxssl.Name = "cb_syxt_mhxssl";
             this.cb_syxt_mhxssl.Size = new System.Drawing.Size(214, 20);
@@ -611,7 +655,7 @@
             // label38
             // 
             this.label38.AutoSize = true;
-            this.label38.Location = new System.Drawing.Point(12, 59);
+            this.label38.Location = new System.Drawing.Point(12, 45);
             this.label38.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
             this.label38.Name = "label38";
             this.label38.Size = new System.Drawing.Size(65, 12);
@@ -621,7 +665,7 @@
             // label33
             // 
             this.label33.AutoSize = true;
-            this.label33.Location = new System.Drawing.Point(14, 176);
+            this.label33.Location = new System.Drawing.Point(14, 138);
             this.label33.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
             this.label33.Name = "label33";
             this.label33.Size = new System.Drawing.Size(101, 12);
@@ -631,7 +675,7 @@
             // label42
             // 
             this.label42.AutoSize = true;
-            this.label42.Location = new System.Drawing.Point(12, 115);
+            this.label42.Location = new System.Drawing.Point(12, 92);
             this.label42.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
             this.label42.Name = "label42";
             this.label42.Size = new System.Drawing.Size(77, 12);
@@ -654,7 +698,7 @@
             this.groupBox8.Controls.Add(this.groupBox_px);
             this.groupBox8.Controls.Add(this.ck_kllb_xsmk);
             this.groupBox8.Controls.Add(this.label34);
-            this.groupBox8.Location = new System.Drawing.Point(3, 1253);
+            this.groupBox8.Location = new System.Drawing.Point(3, 1313);
             this.groupBox8.Margin = new System.Windows.Forms.Padding(2);
             this.groupBox8.Name = "groupBox8";
             this.groupBox8.Padding = new System.Windows.Forms.Padding(2);
@@ -663,6 +707,37 @@
             this.groupBox8.TabStop = false;
             this.groupBox8.Text = "颗粒列表";
             // 
+            // numericMin
+            // 
+            this.numericMin.Increment = new decimal(new int[] {
+            10,
+            0,
+            0,
+            0});
+            this.numericMin.Location = new System.Drawing.Point(167, 68);
+            this.numericMin.Maximum = new decimal(new int[] {
+            99999,
+            0,
+            0,
+            0});
+            this.numericMin.Name = "numericMin";
+            this.numericMin.Size = new System.Drawing.Size(72, 21);
+            this.numericMin.TabIndex = 66;
+            this.numericMin.Value = new decimal(new int[] {
+            10,
+            0,
+            0,
+            0});
+            // 
+            // label112121
+            // 
+            this.label112121.AutoSize = true;
+            this.label112121.Location = new System.Drawing.Point(7, 77);
+            this.label112121.Name = "label112121";
+            this.label112121.Size = new System.Drawing.Size(53, 12);
+            this.label112121.TabIndex = 64;
+            this.label112121.Text = "显示数量";
+            // 
             // label_delete_Class
             // 
             this.label_delete_Class.AutoSize = true;
@@ -985,7 +1060,7 @@
             this.groupBox211.Controls.Add(this.label1311);
             this.groupBox211.Controls.Add(this.label1211);
             this.groupBox211.Controls.Add(this.ck_jzwzb_surface);
-            this.groupBox211.Location = new System.Drawing.Point(3, 1787);
+            this.groupBox211.Location = new System.Drawing.Point(3, 1847);
             this.groupBox211.Name = "groupBox211";
             this.groupBox211.Size = new System.Drawing.Size(263, 81);
             this.groupBox211.TabIndex = 8;
@@ -1032,7 +1107,7 @@
             // groupBZ
             // 
             this.groupBZ.Controls.Add(this.textBox_strBZ);
-            this.groupBZ.Location = new System.Drawing.Point(3, 1874);
+            this.groupBZ.Location = new System.Drawing.Point(3, 1934);
             this.groupBZ.Name = "groupBZ";
             this.groupBZ.Size = new System.Drawing.Size(263, 139);
             this.groupBZ.TabIndex = 7;
@@ -1065,7 +1140,7 @@
             this.groupBox9.Controls.Add(this.label3);
             this.groupBox9.Location = new System.Drawing.Point(3, 3);
             this.groupBox9.Name = "groupBox9";
-            this.groupBox9.Size = new System.Drawing.Size(268, 255);
+            this.groupBox9.Size = new System.Drawing.Size(263, 255);
             this.groupBox9.TabIndex = 1;
             this.groupBox9.TabStop = false;
             this.groupBox9.Text = "首页设置信息";
@@ -1089,76 +1164,25 @@
             this.cb_ParticleRange.Size = new System.Drawing.Size(121, 20);
             this.cb_ParticleRange.TabIndex = 76;
             // 
-            // label112121
+            // label11
             // 
-            this.label112121.AutoSize = true;
-            this.label112121.Location = new System.Drawing.Point(7, 77);
-            this.label112121.Name = "label112121";
-            this.label112121.Size = new System.Drawing.Size(53, 12);
-            this.label112121.TabIndex = 64;
-            this.label112121.Text = "显示数量";
+            this.label11.AutoSize = true;
+            this.label11.Location = new System.Drawing.Point(12, 50);
+            this.label11.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
+            this.label11.Name = "label11";
+            this.label11.Size = new System.Drawing.Size(65, 12);
+            this.label11.TabIndex = 58;
+            this.label11.Text = "显示堆叠图";
             // 
-            // numericMin
+            // ck_klcc_xsddt
             // 
-            this.numericMin.Increment = new decimal(new int[] {
-            10,
-            0,
-            0,
-            0});
-            this.numericMin.Location = new System.Drawing.Point(167, 68);
-            this.numericMin.Maximum = new decimal(new int[] {
-            99999,
-            0,
-            0,
-            0});
-            this.numericMin.Name = "numericMin";
-            this.numericMin.Size = new System.Drawing.Size(72, 21);
-            this.numericMin.TabIndex = 66;
-            this.numericMin.Value = new decimal(new int[] {
-            10,
-            0,
-            0,
-            0});
-            // 
-            // label1121ad
-            // 
-            this.label1121ad.AutoSize = true;
-            this.label1121ad.Location = new System.Drawing.Point(12, 48);
-            this.label1121ad.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
-            this.label1121ad.Name = "label1121ad";
-            this.label1121ad.Size = new System.Drawing.Size(65, 12);
-            this.label1121ad.TabIndex = 54;
-            this.label1121ad.Text = "显示大分类";
-            // 
-            // label11zxc
-            // 
-            this.label11zxc.AutoSize = true;
-            this.label11zxc.Location = new System.Drawing.Point(12, 71);
-            this.label11zxc.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
-            this.label11zxc.Name = "label11zxc";
-            this.label11zxc.Size = new System.Drawing.Size(65, 12);
-            this.label11zxc.TabIndex = 55;
-            this.label11zxc.Text = "显示小分类";
-            // 
-            // checkBox1
-            // 
-            this.checkBox1.AutoSize = true;
-            this.checkBox1.Location = new System.Drawing.Point(224, 48);
-            this.checkBox1.Margin = new System.Windows.Forms.Padding(2);
-            this.checkBox1.Name = "checkBox1";
-            this.checkBox1.Size = new System.Drawing.Size(15, 14);
-            this.checkBox1.TabIndex = 56;
-            this.checkBox1.UseVisualStyleBackColor = true;
-            // 
-            // checkBox2
-            // 
-            this.checkBox2.AutoSize = true;
-            this.checkBox2.Location = new System.Drawing.Point(224, 71);
-            this.checkBox2.Margin = new System.Windows.Forms.Padding(2);
-            this.checkBox2.Name = "checkBox2";
-            this.checkBox2.Size = new System.Drawing.Size(15, 14);
-            this.checkBox2.TabIndex = 57;
-            this.checkBox2.UseVisualStyleBackColor = true;
+            this.ck_klcc_xsddt.AutoSize = true;
+            this.ck_klcc_xsddt.Location = new System.Drawing.Point(224, 50);
+            this.ck_klcc_xsddt.Margin = new System.Windows.Forms.Padding(2);
+            this.ck_klcc_xsddt.Name = "ck_klcc_xsddt";
+            this.ck_klcc_xsddt.Size = new System.Drawing.Size(15, 14);
+            this.ck_klcc_xsddt.TabIndex = 59;
+            this.ck_klcc_xsddt.UseVisualStyleBackColor = true;
             // 
             // OTSReport_TemplateDesignerRM
             // 
@@ -1191,6 +1215,7 @@
             this.groupBox7.PerformLayout();
             this.groupBox8.ResumeLayout(false);
             this.groupBox8.PerformLayout();
+            ((System.ComponentModel.ISupportInitialize)(this.numericMin)).EndInit();
             this.groupBox_zt.ResumeLayout(false);
             this.groupBox_zt.PerformLayout();
             this.groupBox_px.ResumeLayout(false);
@@ -1210,7 +1235,6 @@
             this.groupBZ.PerformLayout();
             this.groupBox9.ResumeLayout(false);
             this.groupBox9.PerformLayout();
-            ((System.ComponentModel.ISupportInitialize)(this.numericMin)).EndInit();
             this.ResumeLayout(false);
             this.PerformLayout();
 
@@ -1311,5 +1335,7 @@
         private System.Windows.Forms.CheckBox checkBox1;
         private System.Windows.Forms.Label label11zxc;
         private System.Windows.Forms.Label label1121ad;
+        private System.Windows.Forms.CheckBox ck_klcc_xsddt;
+        private System.Windows.Forms.Label label11;
     }
 }

+ 6 - 1
OTSIncAReportApp/1-UI/OTSTemplateDesigner/OTSReport_TemplateDesignerRM.cs

@@ -238,6 +238,8 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_YMYJ.str_tb_yjwb.ToString(), "M_YMYJ", "str_tb_yjwb");
                 //颗粒分析结果
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLFXJG.b_ck_klcc_xsmk.ToString(), "M_KLFXJG", "b_ck_klcc_xsmk");//是否显示模块
+                xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLFXJG.b_ck_klcc_xsddt.ToString(), "M_KLFXJG", "b_ck_klcc_xsddt");
+                
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLFXJG.index_cb_klcc_jsfs.ToString(), "M_KLFXJG", "index_cb_klcc_jsfs");//计算方式
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLFXJG.str_cb_klcc_jsfs.ToString(), "M_KLFXJG", "str_cb_klcc_jsfs");//计算方式
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLFXJG.index_cb_klcc_ljb.ToString(), "M_KLFXJG", "index_cb_klcc_ljb");//粒级表
@@ -424,6 +426,8 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_YMYJ.str_tb_yjwb.ToString(), "M_YMYJ", "str_tb_yjwb");
                 //颗粒分析结果
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLFXJG.b_ck_klcc_xsmk.ToString(), "M_KLFXJG", "b_ck_klcc_xsmk");//是否显示模块
+                xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLFXJG.b_ck_klcc_xsddt.ToString(), "M_KLFXJG", "b_ck_klcc_xsddt");
+                
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLFXJG.index_cb_klcc_jsfs.ToString(), "M_KLFXJG", "index_cb_klcc_jsfs");//计算方式
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLFXJG.str_cb_klcc_jsfs.ToString(), "M_KLFXJG", "str_cb_klcc_jsfs");//计算方式
                 xmlutil.Write(m_OTSReport_Export.m_mbszclass.M_KLFXJG.index_cb_klcc_ljb.ToString(), "M_KLFXJG", "index_cb_klcc_ljb");//粒级表
@@ -656,7 +660,7 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
             m_OTSReport_Export.m_mbszclass.M_KLFXJG.index_cb_klcc_jsfs = cb_klcc_jsfs.SelectedIndex;
             m_OTSReport_Export.m_mbszclass.M_KLFXJG.str_cb_klcc_ljb = cb_klcc_ljb.Text;//粒级表
             m_OTSReport_Export.m_mbszclass.M_KLFXJG.index_cb_klcc_ljb = cb_klcc_ljb.SelectedIndex;
-
+            m_OTSReport_Export.m_mbszclass.M_KLFXJG.b_ck_klcc_xsddt = ck_klcc_xsddt.Checked;
 
             //是否显示大分类
             m_OTSReport_Export.m_mbszclass.M_KLFXJG.b_ck_klcc_dfl = checkBox1.Checked;
@@ -768,6 +772,7 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
 
             //颗粒分析结果
             ck_klcc_xsmk.Checked = m_OTSReport_Export.m_mbszclass.M_KLFXJG.b_ck_klcc_xsmk;
+            ck_klcc_xsddt.Checked = m_OTSReport_Export.m_mbszclass.M_KLFXJG.b_ck_klcc_xsddt;
             //cb_klcc_ljb.Text = m_OTSReport_Export.m_mbszclass.M_KLFXJG.str_cb_klcc_jsfs;//计算方式
             cb_klcc_jsfs.SelectedIndex = m_OTSReport_Export.m_mbszclass.M_KLFXJG.index_cb_klcc_jsfs;
             //cb_klcc_ljb.Text = m_OTSReport_Export.m_mbszclass.M_KLFXJG.str_cb_klcc_ljb;//粒级表

+ 180 - 28
OTSIncAReportApp/ReportTemplate/OTS_DEVReport.Designer.cs

@@ -39,9 +39,9 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             this.xrLine2 = new DevExpress.XtraReports.UI.XRLine();
             this.dev_yj = new DevExpress.XtraReports.UI.XRLabel();
             this.Detail = new DevExpress.XtraReports.UI.DetailBand();
+            this.xrChart1 = new DevExpress.XtraReports.UI.XRChart();
             this.xrLabel_size_IconQuestion_Subdivision = new DevExpress.XtraReports.UI.XRLabel();
             this.xrChart_ParticelSizeSubdivision = new DevExpress.XtraReports.UI.XRChart();
-            this.xrPageBreak6 = new DevExpress.XtraReports.UI.XRPageBreak();
             this.xrTb_ElementAnalysis = new DevExpress.XtraReports.UI.XRTable();
             this.xrTableRow22 = new DevExpress.XtraReports.UI.XRTableRow();
             this.xrTableCell30 = new DevExpress.XtraReports.UI.XRTableCell();
@@ -179,6 +179,18 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             this.dev_fbt = new DevExpress.XtraReports.UI.XRLabel();
             this.dev_zbt = new DevExpress.XtraReports.UI.XRLabel();
             this.xrPictureBox2 = new DevExpress.XtraReports.UI.XRPictureBox();
+            this.xrTable3 = new DevExpress.XtraReports.UI.XRTable();
+            this.xrTableRow24 = new DevExpress.XtraReports.UI.XRTableRow();
+            this.xrTableCell32 = new DevExpress.XtraReports.UI.XRTableCell();
+            this.xtParticleResultsB = new DevExpress.XtraReports.UI.XRTableCell();
+            this.xtParticleResultsC = new DevExpress.XtraReports.UI.XRTableCell();
+            this.xtParticleResultsD = new DevExpress.XtraReports.UI.XRTableCell();
+            this.xtParticleResultsE = new DevExpress.XtraReports.UI.XRTableCell();
+            this.xtParticleResultsF = new DevExpress.XtraReports.UI.XRTableCell();
+            this.xtParticleResultsG = new DevExpress.XtraReports.UI.XRTableCell();
+            this.xtParticleResultsH = new DevExpress.XtraReports.UI.XRTableCell();
+            this.xtParticleResultsI = new DevExpress.XtraReports.UI.XRTableCell();
+            ((System.ComponentModel.ISupportInitialize)(this.xrChart1)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this.xrChart_ParticelSizeSubdivision)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this.xrTb_ElementAnalysis)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this.xrTable2)).BeginInit();
@@ -190,6 +202,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             ((System.ComponentModel.ISupportInitialize)(this.xrChart_ParticelSizeCalss)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this.xrTa_ParticleSizeTable)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this.xrTable1)).BeginInit();
+            ((System.ComponentModel.ISupportInitialize)(this.xrTable3)).BeginInit();
             ((System.ComponentModel.ISupportInitialize)(this)).BeginInit();
             // 
             // TopMargin
@@ -269,9 +282,10 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             // Detail
             // 
             this.Detail.Controls.AddRange(new DevExpress.XtraReports.UI.XRControl[] {
+            this.xrTable3,
+            this.xrChart1,
             this.xrLabel_size_IconQuestion_Subdivision,
             this.xrChart_ParticelSizeSubdivision,
-            this.xrPageBreak6,
             this.xrTb_ElementAnalysis,
             this.xrTable2,
             this.xrTable_kllb_surface,
@@ -301,12 +315,22 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             this.dev_fbt,
             this.dev_zbt,
             this.xrPictureBox2});
-            this.Detail.HeightF = 4296.916F;
+            this.Detail.HeightF = 4513.333F;
             this.Detail.Name = "Detail";
             // 
+            // xrChart1
+            // 
+            this.xrChart1.BorderColor = System.Drawing.Color.Black;
+            this.xrChart1.Borders = DevExpress.XtraPrinting.BorderSide.None;
+            this.xrChart1.LocationFloat = new DevExpress.Utils.PointFloat(0F, 1077F);
+            this.xrChart1.Name = "xrChart1";
+            this.xrChart1.SeriesSerializable = new DevExpress.XtraCharts.Series[0];
+            this.xrChart1.SizeF = new System.Drawing.SizeF(688F, 387.4999F);
+            this.xrChart1.Visible = false;
+            // 
             // xrLabel_size_IconQuestion_Subdivision
             // 
-            this.xrLabel_size_IconQuestion_Subdivision.LocationFloat = new DevExpress.Utils.PointFloat(30.41687F, 1483.25F);
+            this.xrLabel_size_IconQuestion_Subdivision.LocationFloat = new DevExpress.Utils.PointFloat(30.41636F, 2159.292F);
             this.xrLabel_size_IconQuestion_Subdivision.Multiline = true;
             this.xrLabel_size_IconQuestion_Subdivision.Name = "xrLabel_size_IconQuestion_Subdivision";
             this.xrLabel_size_IconQuestion_Subdivision.Padding = new DevExpress.XtraPrinting.PaddingInfo(2, 2, 0, 0, 100F);
@@ -321,7 +345,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             this.xrChart_ParticelSizeSubdivision.BorderColor = System.Drawing.Color.Black;
             this.xrChart_ParticelSizeSubdivision.Borders = DevExpress.XtraPrinting.BorderSide.None;
             this.xrChart_ParticelSizeSubdivision.Legend.Name = "Default Legend";
-            this.xrChart_ParticelSizeSubdivision.LocationFloat = new DevExpress.Utils.PointFloat(30.41662F, 1506.25F);
+            this.xrChart_ParticelSizeSubdivision.LocationFloat = new DevExpress.Utils.PointFloat(30.41611F, 2182.292F);
             this.xrChart_ParticelSizeSubdivision.Name = "xrChart_ParticelSizeSubdivision";
             this.xrChart_ParticelSizeSubdivision.PaletteName = "Palette 1";
             this.xrChart_ParticelSizeSubdivision.PaletteRepository.Add("Palette 1", new DevExpress.XtraCharts.Palette("Palette 1", DevExpress.XtraCharts.PaletteScaleMode.Repeat, new DevExpress.XtraCharts.PaletteEntry[] {
@@ -348,19 +372,13 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             this.xrChart_ParticelSizeSubdivision.SizeF = new System.Drawing.SizeF(630F, 478.3333F);
             this.xrChart_ParticelSizeSubdivision.Visible = false;
             // 
-            // xrPageBreak6
-            // 
-            this.xrPageBreak6.LocationFloat = new DevExpress.Utils.PointFloat(0F, 2109.292F);
-            this.xrPageBreak6.Name = "xrPageBreak6";
-            this.xrPageBreak6.Visible = false;
-            // 
             // xrTb_ElementAnalysis
             // 
             this.xrTb_ElementAnalysis.Borders = ((DevExpress.XtraPrinting.BorderSide)((((DevExpress.XtraPrinting.BorderSide.Left | DevExpress.XtraPrinting.BorderSide.Top) 
             | DevExpress.XtraPrinting.BorderSide.Right) 
             | DevExpress.XtraPrinting.BorderSide.Bottom)));
             this.xrTb_ElementAnalysis.BorderWidth = 0.5F;
-            this.xrTb_ElementAnalysis.LocationFloat = new DevExpress.Utils.PointFloat(10.0001F, 2125.959F);
+            this.xrTb_ElementAnalysis.LocationFloat = new DevExpress.Utils.PointFloat(10.0001F, 2779.084F);
             this.xrTb_ElementAnalysis.Name = "xrTb_ElementAnalysis";
             this.xrTb_ElementAnalysis.Padding = new DevExpress.XtraPrinting.PaddingInfo(2, 2, 0, 0, 96F);
             this.xrTb_ElementAnalysis.Rows.AddRange(new DevExpress.XtraReports.UI.XRTableRow[] {
@@ -407,7 +425,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             // 
             // xrTable2
             // 
-            this.xrTable2.LocationFloat = new DevExpress.Utils.PointFloat(0F, 3858.25F);
+            this.xrTable2.LocationFloat = new DevExpress.Utils.PointFloat(0F, 4403.333F);
             this.xrTable2.Name = "xrTable2";
             this.xrTable2.Padding = new DevExpress.XtraPrinting.PaddingInfo(2, 2, 0, 0, 96F);
             this.xrTable2.Rows.AddRange(new DevExpress.XtraReports.UI.XRTableRow[] {
@@ -708,7 +726,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             | DevExpress.XtraPrinting.BorderSide.Right) 
             | DevExpress.XtraPrinting.BorderSide.Bottom)));
             this.xrTable_kllb_surface.BorderWidth = 0.5F;
-            this.xrTable_kllb_surface.LocationFloat = new DevExpress.Utils.PointFloat(0F, 3274.917F);
+            this.xrTable_kllb_surface.LocationFloat = new DevExpress.Utils.PointFloat(0F, 3858.858F);
             this.xrTable_kllb_surface.Name = "xrTable_kllb_surface";
             this.xrTable_kllb_surface.Padding = new DevExpress.XtraPrinting.PaddingInfo(2, 2, 0, 0, 96F);
             this.xrTable_kllb_surface.Rows.AddRange(new DevExpress.XtraReports.UI.XRTableRow[] {
@@ -755,7 +773,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             // 
             // xrLabel_inca_pic_subdivision
             // 
-            this.xrLabel_inca_pic_subdivision.LocationFloat = new DevExpress.Utils.PointFloat(30.41687F, 2750.958F);
+            this.xrLabel_inca_pic_subdivision.LocationFloat = new DevExpress.Utils.PointFloat(30.41636F, 3357.528F);
             this.xrLabel_inca_pic_subdivision.Multiline = true;
             this.xrLabel_inca_pic_subdivision.Name = "xrLabel_inca_pic_subdivision";
             this.xrLabel_inca_pic_subdivision.Padding = new DevExpress.XtraPrinting.PaddingInfo(2, 2, 0, 0, 100F);
@@ -770,7 +788,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             this.xrChart_incaSubdivision.BorderColor = System.Drawing.Color.Black;
             this.xrChart_incaSubdivision.Borders = DevExpress.XtraPrinting.BorderSide.None;
             this.xrChart_incaSubdivision.Legend.Name = "Default Legend";
-            this.xrChart_incaSubdivision.LocationFloat = new DevExpress.Utils.PointFloat(30.41687F, 2773.958F);
+            this.xrChart_incaSubdivision.LocationFloat = new DevExpress.Utils.PointFloat(30.41636F, 3380.528F);
             this.xrChart_incaSubdivision.Name = "xrChart_incaSubdivision";
             this.xrChart_incaSubdivision.SeriesSerializable = new DevExpress.XtraCharts.Series[0];
             this.xrChart_incaSubdivision.SizeF = new System.Drawing.SizeF(630F, 478.33F);
@@ -778,7 +796,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             // 
             // xrLabel_inca_pic_class
             // 
-            this.xrLabel_inca_pic_class.LocationFloat = new DevExpress.Utils.PointFloat(30.41662F, 2327.958F);
+            this.xrLabel_inca_pic_class.LocationFloat = new DevExpress.Utils.PointFloat(30.41636F, 2934.528F);
             this.xrLabel_inca_pic_class.Multiline = true;
             this.xrLabel_inca_pic_class.Name = "xrLabel_inca_pic_class";
             this.xrLabel_inca_pic_class.Padding = new DevExpress.XtraPrinting.PaddingInfo(2, 2, 0, 0, 100F);
@@ -793,7 +811,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             this.xrChart_incaClass.BorderColor = System.Drawing.Color.Black;
             this.xrChart_incaClass.Borders = DevExpress.XtraPrinting.BorderSide.None;
             this.xrChart_incaClass.Legend.Name = "Default Legend";
-            this.xrChart_incaClass.LocationFloat = new DevExpress.Utils.PointFloat(30.41687F, 2350.958F);
+            this.xrChart_incaClass.LocationFloat = new DevExpress.Utils.PointFloat(30.41636F, 2957.528F);
             this.xrChart_incaClass.Name = "xrChart_incaClass";
             this.xrChart_incaClass.SeriesSerializable = new DevExpress.XtraCharts.Series[0];
             this.xrChart_incaClass.SizeF = new System.Drawing.SizeF(630F, 400F);
@@ -801,7 +819,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             // 
             // xrPageBreak5
             // 
-            this.xrPageBreak5.LocationFloat = new DevExpress.Utils.PointFloat(0F, 2325.958F);
+            this.xrPageBreak5.LocationFloat = new DevExpress.Utils.PointFloat(0F, 2913.458F);
             this.xrPageBreak5.Name = "xrPageBreak5";
             // 
             // xr_tbAreaOfInclusion
@@ -810,7 +828,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             | DevExpress.XtraPrinting.BorderSide.Right) 
             | DevExpress.XtraPrinting.BorderSide.Bottom)));
             this.xr_tbAreaOfInclusion.BorderWidth = 0.5F;
-            this.xr_tbAreaOfInclusion.LocationFloat = new DevExpress.Utils.PointFloat(10.0001F, 2263.374F);
+            this.xr_tbAreaOfInclusion.LocationFloat = new DevExpress.Utils.PointFloat(10.0001F, 2863.458F);
             this.xr_tbAreaOfInclusion.Name = "xr_tbAreaOfInclusion";
             this.xr_tbAreaOfInclusion.Padding = new DevExpress.XtraPrinting.PaddingInfo(2, 2, 0, 0, 96F);
             this.xr_tbAreaOfInclusion.Rows.AddRange(new DevExpress.XtraReports.UI.XRTableRow[] {
@@ -889,7 +907,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             // 
             // xrPageBreak4
             // 
-            this.xrPageBreak4.LocationFloat = new DevExpress.Utils.PointFloat(0F, 2261.374F);
+            this.xrPageBreak4.LocationFloat = new DevExpress.Utils.PointFloat(0F, 2844.707F);
             this.xrPageBreak4.Name = "xrPageBreak4";
             // 
             // xrTb_ElementAnalysisTable
@@ -898,7 +916,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             | DevExpress.XtraPrinting.BorderSide.Right) 
             | DevExpress.XtraPrinting.BorderSide.Bottom)));
             this.xrTb_ElementAnalysisTable.BorderWidth = 0.5F;
-            this.xrTb_ElementAnalysisTable.LocationFloat = new DevExpress.Utils.PointFloat(0F, 2017.542F);
+            this.xrTb_ElementAnalysisTable.LocationFloat = new DevExpress.Utils.PointFloat(0F, 2686.375F);
             this.xrTb_ElementAnalysisTable.Name = "xrTb_ElementAnalysisTable";
             this.xrTb_ElementAnalysisTable.Padding = new DevExpress.XtraPrinting.PaddingInfo(2, 2, 0, 0, 96F);
             this.xrTb_ElementAnalysisTable.Rows.AddRange(new DevExpress.XtraReports.UI.XRTableRow[] {
@@ -1058,12 +1076,12 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             // 
             // xrPageBreak3
             // 
-            this.xrPageBreak3.LocationFloat = new DevExpress.Utils.PointFloat(0F, 1999.917F);
+            this.xrPageBreak3.LocationFloat = new DevExpress.Utils.PointFloat(0F, 2673.875F);
             this.xrPageBreak3.Name = "xrPageBreak3";
             // 
             // xrLabel_size_IconQuestion_Class
             // 
-            this.xrLabel_size_IconQuestion_Class.LocationFloat = new DevExpress.Utils.PointFloat(30.41662F, 1060.25F);
+            this.xrLabel_size_IconQuestion_Class.LocationFloat = new DevExpress.Utils.PointFloat(30.41611F, 1736.292F);
             this.xrLabel_size_IconQuestion_Class.Multiline = true;
             this.xrLabel_size_IconQuestion_Class.Name = "xrLabel_size_IconQuestion_Class";
             this.xrLabel_size_IconQuestion_Class.Padding = new DevExpress.XtraPrinting.PaddingInfo(2, 2, 0, 0, 100F);
@@ -1078,7 +1096,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             this.xrChart_ParticelSizeCalss.BorderColor = System.Drawing.Color.Black;
             this.xrChart_ParticelSizeCalss.Borders = DevExpress.XtraPrinting.BorderSide.None;
             this.xrChart_ParticelSizeCalss.Legend.Name = "Default Legend";
-            this.xrChart_ParticelSizeCalss.LocationFloat = new DevExpress.Utils.PointFloat(30.41662F, 1083.25F);
+            this.xrChart_ParticelSizeCalss.LocationFloat = new DevExpress.Utils.PointFloat(30.41611F, 1759.292F);
             this.xrChart_ParticelSizeCalss.Name = "xrChart_ParticelSizeCalss";
             this.xrChart_ParticelSizeCalss.SeriesSerializable = new DevExpress.XtraCharts.Series[0];
             this.xrChart_ParticelSizeCalss.SizeF = new System.Drawing.SizeF(630F, 400F);
@@ -1086,7 +1104,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             // 
             // xrPageBreak2
             // 
-            this.xrPageBreak2.LocationFloat = new DevExpress.Utils.PointFloat(0F, 1058.25F);
+            this.xrPageBreak2.LocationFloat = new DevExpress.Utils.PointFloat(0F, 1721.792F);
             this.xrPageBreak2.Name = "xrPageBreak2";
             // 
             // xrTa_ParticleSizeTable
@@ -1680,12 +1698,133 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             // xrPictureBox2
             // 
             this.xrPictureBox2.ImageAlignment = DevExpress.XtraPrinting.ImageAlignment.MiddleCenter;
-            this.xrPictureBox2.LocationFloat = new DevExpress.Utils.PointFloat(0F, 3357.208F);
+            this.xrPictureBox2.LocationFloat = new DevExpress.Utils.PointFloat(0F, 3918.858F);
             this.xrPictureBox2.Name = "xrPictureBox2";
             this.xrPictureBox2.SizeF = new System.Drawing.SizeF(688F, 484.4744F);
             this.xrPictureBox2.Sizing = DevExpress.XtraPrinting.ImageSizeMode.Squeeze;
             this.xrPictureBox2.Visible = false;
             // 
+            // xrTable3
+            // 
+            this.xrTable3.Borders = ((DevExpress.XtraPrinting.BorderSide)((((DevExpress.XtraPrinting.BorderSide.Left | DevExpress.XtraPrinting.BorderSide.Top) 
+            | DevExpress.XtraPrinting.BorderSide.Right) 
+            | DevExpress.XtraPrinting.BorderSide.Bottom)));
+            this.xrTable3.LocationFloat = new DevExpress.Utils.PointFloat(10.0001F, 1039.917F);
+            this.xrTable3.Name = "xrTable3";
+            this.xrTable3.Padding = new DevExpress.XtraPrinting.PaddingInfo(2, 2, 0, 0, 96F);
+            this.xrTable3.Rows.AddRange(new DevExpress.XtraReports.UI.XRTableRow[] {
+            this.xrTableRow24});
+            this.xrTable3.SizeF = new System.Drawing.SizeF(667.9998F, 25F);
+            this.xrTable3.StylePriority.UseBorders = false;
+            this.xrTable3.Visible = false;
+            // 
+            // xrTableRow24
+            // 
+            this.xrTableRow24.Cells.AddRange(new DevExpress.XtraReports.UI.XRTableCell[] {
+            this.xrTableCell32,
+            this.xtParticleResultsB,
+            this.xtParticleResultsC,
+            this.xtParticleResultsD,
+            this.xtParticleResultsE,
+            this.xtParticleResultsF,
+            this.xtParticleResultsG,
+            this.xtParticleResultsH,
+            this.xtParticleResultsI});
+            this.xrTableRow24.Name = "xrTableRow24";
+            this.xrTableRow24.Weight = 1D;
+            // 
+            // xrTableCell32
+            // 
+            this.xrTableCell32.Borders = ((DevExpress.XtraPrinting.BorderSide)(((DevExpress.XtraPrinting.BorderSide.Left | DevExpress.XtraPrinting.BorderSide.Right) 
+            | DevExpress.XtraPrinting.BorderSide.Bottom)));
+            this.xrTableCell32.Multiline = true;
+            this.xrTableCell32.Name = "xrTableCell32";
+            this.xrTableCell32.StylePriority.UseBorders = false;
+            this.xrTableCell32.StylePriority.UseTextAlignment = false;
+            this.xrTableCell32.Text = "总数量";
+            this.xrTableCell32.TextAlignment = DevExpress.XtraPrinting.TextAlignment.TopCenter;
+            this.xrTableCell32.Weight = 1.1360665286429279D;
+            // 
+            // xtParticleResultsB
+            // 
+            this.xtParticleResultsB.Borders = ((DevExpress.XtraPrinting.BorderSide)(((DevExpress.XtraPrinting.BorderSide.Left | DevExpress.XtraPrinting.BorderSide.Right) 
+            | DevExpress.XtraPrinting.BorderSide.Bottom)));
+            this.xtParticleResultsB.Multiline = true;
+            this.xtParticleResultsB.Name = "xtParticleResultsB";
+            this.xtParticleResultsB.StylePriority.UseBorders = false;
+            this.xtParticleResultsB.Text = "xtParticleResultsB";
+            this.xtParticleResultsB.Weight = 0.31241855456998036D;
+            // 
+            // xtParticleResultsC
+            // 
+            this.xtParticleResultsC.Borders = ((DevExpress.XtraPrinting.BorderSide)(((DevExpress.XtraPrinting.BorderSide.Left | DevExpress.XtraPrinting.BorderSide.Right) 
+            | DevExpress.XtraPrinting.BorderSide.Bottom)));
+            this.xtParticleResultsC.Multiline = true;
+            this.xtParticleResultsC.Name = "xtParticleResultsC";
+            this.xtParticleResultsC.StylePriority.UseBorders = false;
+            this.xtParticleResultsC.Text = "xtParticleResultsC";
+            this.xtParticleResultsC.Weight = 0.33513938981554842D;
+            // 
+            // xtParticleResultsD
+            // 
+            this.xtParticleResultsD.Borders = ((DevExpress.XtraPrinting.BorderSide)(((DevExpress.XtraPrinting.BorderSide.Left | DevExpress.XtraPrinting.BorderSide.Right) 
+            | DevExpress.XtraPrinting.BorderSide.Bottom)));
+            this.xtParticleResultsD.Multiline = true;
+            this.xtParticleResultsD.Name = "xtParticleResultsD";
+            this.xtParticleResultsD.StylePriority.UseBorders = false;
+            this.xtParticleResultsD.Text = "xtParticleResultsD";
+            this.xtParticleResultsD.Weight = 0.33513938981554842D;
+            // 
+            // xtParticleResultsE
+            // 
+            this.xtParticleResultsE.Borders = ((DevExpress.XtraPrinting.BorderSide)(((DevExpress.XtraPrinting.BorderSide.Left | DevExpress.XtraPrinting.BorderSide.Right) 
+            | DevExpress.XtraPrinting.BorderSide.Bottom)));
+            this.xtParticleResultsE.Multiline = true;
+            this.xtParticleResultsE.Name = "xtParticleResultsE";
+            this.xtParticleResultsE.StylePriority.UseBorders = false;
+            this.xtParticleResultsE.Text = "xtParticleResultsE";
+            this.xtParticleResultsE.Weight = 0.33513938981554842D;
+            // 
+            // xtParticleResultsF
+            // 
+            this.xtParticleResultsF.Borders = ((DevExpress.XtraPrinting.BorderSide)(((DevExpress.XtraPrinting.BorderSide.Left | DevExpress.XtraPrinting.BorderSide.Right) 
+            | DevExpress.XtraPrinting.BorderSide.Bottom)));
+            this.xtParticleResultsF.Multiline = true;
+            this.xtParticleResultsF.Name = "xtParticleResultsF";
+            this.xtParticleResultsF.StylePriority.UseBorders = false;
+            this.xtParticleResultsF.Text = "xtParticleResultsF";
+            this.xtParticleResultsF.Weight = 0.33513938981554842D;
+            // 
+            // xtParticleResultsG
+            // 
+            this.xtParticleResultsG.Borders = ((DevExpress.XtraPrinting.BorderSide)(((DevExpress.XtraPrinting.BorderSide.Left | DevExpress.XtraPrinting.BorderSide.Right) 
+            | DevExpress.XtraPrinting.BorderSide.Bottom)));
+            this.xtParticleResultsG.Multiline = true;
+            this.xtParticleResultsG.Name = "xtParticleResultsG";
+            this.xtParticleResultsG.StylePriority.UseBorders = false;
+            this.xtParticleResultsG.Text = "xtParticleResultsG";
+            this.xtParticleResultsG.Weight = 0.33513938981554842D;
+            // 
+            // xtParticleResultsH
+            // 
+            this.xtParticleResultsH.Borders = ((DevExpress.XtraPrinting.BorderSide)(((DevExpress.XtraPrinting.BorderSide.Left | DevExpress.XtraPrinting.BorderSide.Right) 
+            | DevExpress.XtraPrinting.BorderSide.Bottom)));
+            this.xtParticleResultsH.Multiline = true;
+            this.xtParticleResultsH.Name = "xtParticleResultsH";
+            this.xtParticleResultsH.StylePriority.UseBorders = false;
+            this.xtParticleResultsH.Text = "xtParticleResultsH";
+            this.xtParticleResultsH.Weight = 0.33513938981554842D;
+            // 
+            // xtParticleResultsI
+            // 
+            this.xtParticleResultsI.Borders = ((DevExpress.XtraPrinting.BorderSide)(((DevExpress.XtraPrinting.BorderSide.Left | DevExpress.XtraPrinting.BorderSide.Right) 
+            | DevExpress.XtraPrinting.BorderSide.Bottom)));
+            this.xtParticleResultsI.Multiline = true;
+            this.xtParticleResultsI.Name = "xtParticleResultsI";
+            this.xtParticleResultsI.StylePriority.UseBorders = false;
+            this.xtParticleResultsI.Text = "xtParticleResultsI";
+            this.xtParticleResultsI.Weight = 0.33513938981554842D;
+            // 
             // OTS_DEVReport
             // 
             this.Bands.AddRange(new DevExpress.XtraReports.UI.Band[] {
@@ -1695,6 +1834,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             this.Font = new System.Drawing.Font("Arial", 9.75F);
             this.Margins = new System.Drawing.Printing.Margins(77, 85, 73, 55);
             this.Version = "21.2";
+            ((System.ComponentModel.ISupportInitialize)(this.xrChart1)).EndInit();
             ((System.ComponentModel.ISupportInitialize)(this.xrChart_ParticelSizeSubdivision)).EndInit();
             ((System.ComponentModel.ISupportInitialize)(this.xrTb_ElementAnalysis)).EndInit();
             ((System.ComponentModel.ISupportInitialize)(this.xrTable2)).EndInit();
@@ -1706,6 +1846,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             ((System.ComponentModel.ISupportInitialize)(this.xrChart_ParticelSizeCalss)).EndInit();
             ((System.ComponentModel.ISupportInitialize)(this.xrTa_ParticleSizeTable)).EndInit();
             ((System.ComponentModel.ISupportInitialize)(this.xrTable1)).EndInit();
+            ((System.ComponentModel.ISupportInitialize)(this.xrTable3)).EndInit();
             ((System.ComponentModel.ISupportInitialize)(this)).EndInit();
 
         }
@@ -1859,7 +2000,18 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
         private DevExpress.XtraReports.UI.XRTableCell xrTableCell30;
         private DevExpress.XtraReports.UI.XRTableRow xrTableRow23;
         private DevExpress.XtraReports.UI.XRTableCell xrTableCell31;
-        private DevExpress.XtraReports.UI.XRPageBreak xrPageBreak6;
         private DevExpress.XtraReports.UI.XRLabel xrLabel_pageinfo;
+        private DevExpress.XtraReports.UI.XRChart xrChart1;
+        private DevExpress.XtraReports.UI.XRTable xrTable3;
+        private DevExpress.XtraReports.UI.XRTableRow xrTableRow24;
+        private DevExpress.XtraReports.UI.XRTableCell xrTableCell32;
+        private DevExpress.XtraReports.UI.XRTableCell xtParticleResultsB;
+        private DevExpress.XtraReports.UI.XRTableCell xtParticleResultsC;
+        private DevExpress.XtraReports.UI.XRTableCell xtParticleResultsD;
+        private DevExpress.XtraReports.UI.XRTableCell xtParticleResultsE;
+        private DevExpress.XtraReports.UI.XRTableCell xtParticleResultsF;
+        private DevExpress.XtraReports.UI.XRTableCell xtParticleResultsG;
+        private DevExpress.XtraReports.UI.XRTableCell xtParticleResultsH;
+        private DevExpress.XtraReports.UI.XRTableCell xtParticleResultsI;
     }
 }

+ 174 - 52
OTSIncAReportApp/ReportTemplate/OTS_DEVReport.cs

@@ -1,4 +1,5 @@
-using DevExpress.XtraCharts;
+using DevExpress.Utils;
+using DevExpress.XtraCharts;
 using DevExpress.XtraPrinting.Drawing;
 using DevExpress.XtraReports.UI;
 using OTSIncAReportApp.OTSTemplateDesigner;
@@ -168,7 +169,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
         /// </summary>
         /// <param name="a_pieSeriesClass">大分类</param>
         /// <param name="a_pieSeries">小分类</param>
-        public void setParticleSizeTable(bool a_pieSeriesClass,bool a_pieSeries)
+        public void setParticleSizeTable(bool a_pieSeriesClass,bool a_pieSeries,bool isStacking)
         {
             export_ReportTemplate.ParticleSizeTable(TemplateClass, out DataTable surface_dt, out DataTable ls_partsize_dt, out DataTable class_dt, out DataTable subdivde_dt,out DataTable colid_data);
             for (int i=0;i< class_dt.Rows.Count;i++)
@@ -244,7 +245,59 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
                 xrTa_ParticleSizeTable.Rows.Add(row);
 
             }
+            xrTable3.Visible = true;
+            xrTable3.LocationF = new PointF(xrTa_ParticleSizeTable.LocationF.X, xrTa_ParticleSizeTable.LocationF.Y + xrTa_ParticleSizeTable.HeightF);
+            DataTable surface_dt2 = export_ReportTemplate.ParticleResults(TemplateClass);
+            List<int> vs = new List<int>();
+            vs.Add(0);
+            vs.Add(0);
+            vs.Add(0);
+            vs.Add(0);
+            vs.Add(0);
+            vs.Add(0);
+            vs.Add(0);
+            vs.Add(0);
+            vs.Add(0);
+            vs.Add(0);
+            int total = 0;
+            for (int i = 0; i < surface_dt2.Rows.Count; i++)
+            {
+                for (int a = 1; a < 11; a++)
+                {
+                    if (surface_dt2.Rows[i]["c" + a.ToString()] != " " && surface_dt2.Rows[i]["c" + a.ToString()] != "" && surface_dt2.Rows[i]["c" + a.ToString()] != null)
+                    {
+                        bool isNumeric = double.TryParse(surface_dt2.Rows[i]["c" + a.ToString()].ToString(), out double result);
+                        if (isNumeric)
+                            vs[a - 1] += Convert.ToInt32(result);
 
+
+                    }
+                }
+                total += Convert.ToInt32(surface_dt2.Rows[i]["total"]);
+            }
+            
+            xtParticleResultsB.Text = total.ToString();
+            xtParticleResultsB.TextAlignment = DevExpress.XtraPrinting.TextAlignment.MiddleCenter;
+            xtParticleResultsC.Text = vs[0].ToString();
+            xtParticleResultsC.TextAlignment = DevExpress.XtraPrinting.TextAlignment.MiddleCenter;
+            xtParticleResultsD.Text = vs[1].ToString();
+            xtParticleResultsD.TextAlignment = DevExpress.XtraPrinting.TextAlignment.MiddleCenter;
+            xtParticleResultsE.Text = vs[2].ToString();
+            xtParticleResultsE.TextAlignment = DevExpress.XtraPrinting.TextAlignment.MiddleCenter;
+            xtParticleResultsF.Text = vs[3].ToString();
+            xtParticleResultsF.TextAlignment = DevExpress.XtraPrinting.TextAlignment.MiddleCenter;
+            xtParticleResultsG.Text = vs[4].ToString();
+            xtParticleResultsG.TextAlignment = DevExpress.XtraPrinting.TextAlignment.MiddleCenter;
+            xtParticleResultsH.Text = vs[5].ToString();
+            xtParticleResultsH.TextAlignment = DevExpress.XtraPrinting.TextAlignment.MiddleCenter;
+            xtParticleResultsI.Text = vs[6].ToString();
+            xtParticleResultsI.TextAlignment = DevExpress.XtraPrinting.TextAlignment.MiddleCenter;
+            if (isStacking)
+            {
+                xrChart1.Visible = true;
+                HistogramChart();
+            }
+                
             #region 大分类chart图
             if (a_pieSeriesClass)
             {
@@ -282,12 +335,13 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             {
                 if (!a_pieSeriesClass)
                 {
+
+                    xrChart_ParticelSizeSubdivision.LocationF = xrChart_ParticelSizeCalss.LocationF;
                     xrLabel_size_IconQuestion_Subdivision.LocationF = xrLabel_size_IconQuestion_Class.LocationF;
                     
-                    xrChart_ParticelSizeSubdivision.LocationF = xrChart_ParticelSizeCalss.LocationF;
                 }
 
-                xrLabel_size_IconQuestion_Subdivision.Visible = false;
+                xrLabel_size_IconQuestion_Subdivision.Visible = true;
                 DataView dv2 = subdivde_dt.DefaultView;
                 dv2.Sort = "total DESC";
                 DataTable dt_subdivde_dt = dv2.ToTable();
@@ -319,6 +373,63 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             #endregion
             #endregion
         }
+
+        public void HistogramChart()
+        {
+
+            List<Series> seriesList = new List<Series>();
+            DataTable dataTable = export_ReportTemplate.ParticleResults(TemplateClass);
+            DataTable TypeRange = export_ReportTemplate.TypeRange();
+            DataTable dt = new DataTable();
+            dt.Columns.Add("name");
+            dt.Columns.Add("range");
+            dt.Columns.Add("num");
+            for (int i = 0; i < dataTable.Rows.Count; i++)
+            {
+                for (int a = 1; a < 11; a++)
+                {
+                    if (string.IsNullOrEmpty(TypeRange.Rows[0][a].ToString()))
+                        continue;
+                    DataRow dr = dt.NewRow();
+                    dr["name"] = subscript.Getsubscriptstring(dataTable.Rows[i]["Name"].ToString());
+                    dr["range"] = TypeRange.Rows[0][a];
+                    if (double.TryParse(dataTable.Rows[i]["c" + a.ToString()].ToString(), out double result))
+                    {
+                        dr["num"] = result;
+                    }
+                    else
+                    {
+                        dr["num"] = 0;
+                    }
+                    dt.Rows.Add(dr);
+                }
+            }
+
+            //DataTable dt = export_ReportTemplate.ParticleResults(TemplateClass);
+            foreach (DataRow dr in dt.DefaultView.ToTable(true, "name").Rows)
+            {
+                Series s = new Series(dr["name"].ToString(), ViewType.StackedBar)
+                {
+                    LegendTextPattern = dr["name"].ToString(),
+                    ArgumentScaleType = ScaleType.Qualitative,
+                };
+                foreach (DataRow drl in dt.Select("name='" + dr["name"].ToString() + "'"))
+                    s.Points.Add(new SeriesPoint(drl["range"].ToString(), int.Parse(drl["num"].ToString())));
+                s.LabelsVisibility = DefaultBoolean.False;
+                seriesList.Add(s);
+            }
+            foreach (Series sr in seriesList.ToArray())
+                xrChart1.Series.Add(sr);
+            ((XYDiagram)xrChart1.Diagram).AxisY.Title.Text = "";
+            ((XYDiagram)xrChart1.Diagram).AxisX.Title.Text = "";
+            ((XYDiagram)xrChart1.Diagram).AxisY.Title.Visibility = DefaultBoolean.True;
+            ((XYDiagram)xrChart1.Diagram).AxisX.Title.Visibility = DefaultBoolean.True;
+            ((XYDiagram)xrChart1.Diagram).AxisY.Title.Font = new Font("Tahoma", 9);
+            ((XYDiagram)xrChart1.Diagram).AxisX.Title.Font = new Font("Tahoma", 9);
+            ((XYDiagram)xrChart1.Diagram).AxisY.Title.Alignment = StringAlignment.Far;
+            ((XYDiagram)xrChart1.Diagram).AxisX.Title.Alignment = StringAlignment.Far;
+
+        }
         /// <summary>
         /// 设置插入元素分析表数据
         /// </summary>
@@ -409,7 +520,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
 
 
             xrTb_ElementAnalysis.Visible = true;
-            xrPageBreak6.Visible = true;
+            //xrPageBreak6.Visible = true;
             for (int i=0;i< allElement_dt.Rows.Count;i++)
             {
                 double quantity = 0;
@@ -674,7 +785,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             xrTable_kllb_surface.LocationF = new PointF(0, NeueStartposition + 5);
             xrTable_kllb_surface.Visible = true;
             NeueStartposition = xrTable_kllb_surface.LocationF.Y + xrTable_kllb_surface.SizeF.Height;
-
+            xrTableCell2.Text = "Selected particles based on:" + TemplateClass.M_KLLBXX.str_cb_kllb_sort_p1.ToString() + ", Descending";
             DataTable dataTable = export_ReportTemplate.Get_dev_kllb_data(TemplateClass);
 
             for (int i = 0; i < dataTable.Rows.Count; i++)
@@ -1021,10 +1132,11 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
 
             XRTableRow Template_Rows_5 = new XRTableRow();
             XRTableCell Template_Rows5_Cell_1 = new XRTableCell();
+            XRTableCell Template_Rows5_Cell_2 = new XRTableCell();
 
             Template.TextAlignment = DevExpress.XtraPrinting.TextAlignment.MiddleCenter;
         
-            Template_Rows1_Cell_1.WidthF = 115.67f;
+            //Template_Rows1_Cell_1.WidthF = 115.67f;
             Template_Rows1_Cell_2.WidthF = 57.22f;
             Template_Rows1_Cell_3.WidthF = 256f;
             Template_Rows1_Cell_4.WidthF = 85.85f;
@@ -1032,7 +1144,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             Template_Rows1_Cell_6.WidthF = 85.85f;
 
 
-            Template_Rows_1.Controls.Add(Template_Rows1_Cell_1);
+            //Template_Rows_1.Controls.Add(Template_Rows1_Cell_1);
             Template_Rows_1.Controls.Add(Template_Rows1_Cell_2);
             Template_Rows_1.Controls.Add(Template_Rows1_Cell_3);
             Template_Rows_1.Controls.Add(Template_Rows1_Cell_4);
@@ -1041,7 +1153,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
 
 
 
-            Template_Rows2_Cell_1.WidthF = 115.67f;
+            //Template_Rows2_Cell_1.WidthF = 115.67f;
             Template_Rows2_Cell_2.WidthF = 57.22f;
             Template_Rows2_Cell_3.WidthF = 256f;
             Template_Rows2_Cell_4.WidthF = 85.85f;
@@ -1049,14 +1161,14 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             Template_Rows2_Cell_6.WidthF = 85.85f;
 
 
-            Template_Rows_2.Controls.Add(Template_Rows2_Cell_1);
+            //Template_Rows_2.Controls.Add(Template_Rows2_Cell_1);
             Template_Rows_2.Controls.Add(Template_Rows2_Cell_2);
             Template_Rows_2.Controls.Add(Template_Rows2_Cell_3);
             Template_Rows_2.Controls.Add(Template_Rows2_Cell_4);
             Template_Rows_2.Controls.Add(Template_Rows2_Cell_5);
             Template_Rows_2.Controls.Add(Template_Rows2_Cell_6);
 
-            Template_Rows3_Cell_1.WidthF = 115.67f;
+            //Template_Rows3_Cell_1.WidthF = 115.67f;
             Template_Rows3_Cell_2.WidthF = 57.23f;//63.59f
             Template_Rows3_Cell_3.WidthF = 57.23f;
             Template_Rows3_Cell_4.WidthF = 57.23f;
@@ -1068,7 +1180,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             Template_Rows3_Cell_10.WidthF = 57.23f;
             Template_Rows3_Cell_11.WidthF = 57.23f;
 
-            Template_Rows_3.Controls.Add(Template_Rows3_Cell_1);
+            //Template_Rows_3.Controls.Add(Template_Rows3_Cell_1);
             Template_Rows_3.Controls.Add(Template_Rows3_Cell_2);
             Template_Rows_3.Controls.Add(Template_Rows3_Cell_3);
             Template_Rows_3.Controls.Add(Template_Rows3_Cell_4);
@@ -1080,7 +1192,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             Template_Rows_3.Controls.Add(Template_Rows3_Cell_10);
             Template_Rows_3.Controls.Add(Template_Rows3_Cell_11);
 
-            Template_Rows4_Cell_1.WidthF = 115.67f;
+            //Template_Rows4_Cell_1.WidthF = 115.67f;
             Template_Rows4_Cell_2.WidthF = 57.23f;//63.59f
             Template_Rows4_Cell_3.WidthF = 57.23f;
             Template_Rows4_Cell_4.WidthF = 57.23f;
@@ -1094,7 +1206,7 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
 
 
 
-            Template_Rows_4.Controls.Add(Template_Rows4_Cell_1);
+            //Template_Rows_4.Controls.Add(Template_Rows4_Cell_1);
             Template_Rows_4.Controls.Add(Template_Rows4_Cell_2);
             Template_Rows_4.Controls.Add(Template_Rows4_Cell_3);
             Template_Rows_4.Controls.Add(Template_Rows4_Cell_4);
@@ -1106,8 +1218,11 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             Template_Rows_4.Controls.Add(Template_Rows4_Cell_10);
             Template_Rows_4.Controls.Add(Template_Rows4_Cell_11);
 
-            Template_Rows_5.Controls.Add(Template_Rows5_Cell_1);
 
+            Template_Rows5_Cell_1.WidthF = 115.67f;
+            Template_Rows5_Cell_2.WidthF = 572.33f;
+            Template_Rows_5.Controls.Add(Template_Rows5_Cell_1);
+            Template_Rows_5.Controls.Add(Template_Rows5_Cell_2);
             Template.Rows.Add(Template_Rows_1);
             Template.Rows.Add(Template_Rows_2);
             Template.Rows.Add(Template_Rows_3);
@@ -1122,18 +1237,18 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
 
             Template.Rows[0].BackColor = Color.DarkGray;
             Template.Rows[2].BackColor = Color.DarkGray;
-            Template.Rows[0].Cells[0].BackColor = Color.Transparent;
-            Template.Rows[2].Cells[0].BackColor = Color.Transparent;
+            //Template.Rows[0].Cells[0].BackColor = Color.Transparent;
+            //Template.Rows[2].Cells[0].BackColor = Color.Transparent;
             Template.Rows[2].BackColor = Color.DarkGray;
 
             
 
 
             Template.Borders = DevExpress.XtraPrinting.BorderSide.All;
-            Template.Rows[0].Cells[0].Borders = DevExpress.XtraPrinting.BorderSide.Left | DevExpress.XtraPrinting.BorderSide.Top;
-            Template.Rows[1].Cells[0].Borders = DevExpress.XtraPrinting.BorderSide.Left;
-            Template.Rows[2].Cells[0].Borders = DevExpress.XtraPrinting.BorderSide.Left;
-            Template.Rows[3].Cells[0].Borders = DevExpress.XtraPrinting.BorderSide.Left | DevExpress.XtraPrinting.BorderSide.Bottom;
+            //Template.Rows[0].Cells[0].Borders = DevExpress.XtraPrinting.BorderSide.Left | DevExpress.XtraPrinting.BorderSide.Top;
+            //Template.Rows[1].Cells[0].Borders = DevExpress.XtraPrinting.BorderSide.Left;
+            //Template.Rows[2].Cells[0].Borders = DevExpress.XtraPrinting.BorderSide.Left;
+            //Template.Rows[3].Cells[0].Borders = DevExpress.XtraPrinting.BorderSide.Left | DevExpress.XtraPrinting.BorderSide.Bottom;
 
             return Template;
         }
@@ -1142,41 +1257,46 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             XRTable table = new XRTable();
             table = xRTable;
             table.Name = "table_kllb_" + position.ToString();
-            table.Rows[0].Cells[1].Text = "ID";
-            table.Rows[0].Cells[2].Text = "Class";
-            table.Rows[0].Cells[3].Text = TemplateClass.M_KLLBXX.str_cb_kllb_sort_p1.ToString();
-            table.Rows[0].Cells[4].Text = TemplateClass.M_KLLBXX.str_cb_kllb_sort_p2.ToString();
-            table.Rows[0].Cells[5].Text = TemplateClass.M_KLLBXX.str_cb_kllb_sort_p3.ToString();
-
-            table.Rows[1].Cells[1].Text = dataTable.Rows[position]["pid"].ToString();
-            table.Rows[1].Cells[2].Text = dataTable.Rows[position]["Class"].ToString();
-            table.Rows[1].Cells[3].Text = dataTable.Rows[position]["Size"].ToString();
-            table.Rows[1].Cells[4].Text = dataTable.Rows[position]["DMAX"].ToString();
-            table.Rows[1].Cells[5].Text = dataTable.Rows[position]["DMIN"].ToString();
-
-            for (int i = 1; i < 11; i++)
+            table.Rows[0].Cells[0].Text = "ID";
+            table.Rows[0].Cells[1].Text = "Class";
+            table.Rows[0].Cells[2].Text = TemplateClass.M_KLLBXX.str_cb_kllb_sort_p1.ToString();
+            table.Rows[0].Cells[3].Text = TemplateClass.M_KLLBXX.str_cb_kllb_sort_p2.ToString();
+            table.Rows[0].Cells[4].Text = TemplateClass.M_KLLBXX.str_cb_kllb_sort_p3.ToString();
+
+            table.Rows[1].Cells[0].Text = dataTable.Rows[position]["pid"].ToString();
+            table.Rows[1].Cells[1].Text = dataTable.Rows[position]["Class"].ToString();
+            table.Rows[1].Cells[2].Text = dataTable.Rows[position]["Size"].ToString();
+            table.Rows[1].Cells[3].Text = dataTable.Rows[position]["DMAX"].ToString();
+            table.Rows[1].Cells[4].Text = dataTable.Rows[position]["DMIN"].ToString();
+
+            for (int i = 0; i < 10; i++)
             {
-                table.Rows[2].Cells[i].Text = dataTable.Rows[position]["ColName" + i.ToString()].ToString();
+                table.Rows[2].Cells[i].Text = dataTable.Rows[position]["ColName" + (i+1).ToString()].ToString();
                 string str_ColVal = "";
-                if (dataTable.Rows[position]["ColVal" + i.ToString()].ToString() == "0")
+                if (dataTable.Rows[position]["ColVal" + (i+1).ToString()].ToString() == "0")
                 {
                     str_ColVal = "";
                 }
                 else
                 {
-                    str_ColVal = dataTable.Rows[position]["ColVal" + i.ToString()].ToString();
+                    str_ColVal = dataTable.Rows[position]["ColVal" + (i+1).ToString()].ToString();
                 }
                 table.Rows[3].Cells[i].Text = str_ColVal;
             }
 
            
-            table.Rows[4].Cells[0].BackColor = Color.DarkGray;
-            table.Rows[4].Cells[0].TextAlignment = DevExpress.XtraPrinting.TextAlignment.MiddleCenter;
+            //table.Rows[4].Cells[0].BackColor = Color.DarkGray;
+            //table.Rows[4].Cells[0].TextAlignment = DevExpress.XtraPrinting.TextAlignment.MiddleCenter;
             XRPictureBox xRPicture2 = new XRPictureBox();
-            xRPicture2.ImageSource = new ImageSource((Bitmap)dataTable.Rows[position]["p3"]);
             xRPicture2.Sizing = DevExpress.XtraPrinting.ImageSizeMode.AutoSize;
-            table.Rows[4].Cells[0].Controls.Add(xRPicture2);
-
+            xRPicture2.ImageSource = new ImageSource((Bitmap)dataTable.Rows[position]["p3"]);
+            XRPictureBox xRPicture3 = new XRPictureBox();
+            xRPicture3.ImageSource = new ImageSource((Bitmap)dataTable.Rows[position]["p1"]);
+            xRPicture3.SizeF = new SizeF(117f, 121f);
+            xRPicture3.Sizing = DevExpress.XtraPrinting.ImageSizeMode.Squeeze;
+            
+            table.Rows[4].Cells[0].Controls.Add(xRPicture3);
+            table.Rows[4].Cells[1].Controls.Add(xRPicture2);
             table.Visible = true;
             table.LocationF = new PointF(0, NeueStartposition);
             table.SendToBack();
@@ -1185,16 +1305,18 @@ namespace OTSIncAReportApp._1_UI.OTSTemplateDesigner
             table.BorderWidth = 0.5f;
 
             this.Detail.Controls.Add(table);
-            XRPictureBox xRPicture_pic = new XRPictureBox();
-            xRPicture_pic.Name = "Picture_kllb_" + position.ToString();
-            xRPicture_pic.ImageSource = new ImageSource((Image)dataTable.Rows[position]["p1"]);
-            xRPicture_pic.LocationF = new PointF(1, NeueStartposition);
-            xRPicture_pic.Visible = true;
-            xRPicture_pic.BackColor = Color.DarkGray;
-            xRPicture_pic.Sizing = DevExpress.XtraPrinting.ImageSizeMode.Squeeze;
-            xRPicture_pic.SizeF = new SizeF(115f, 96.88f);
-            xRPicture_pic.BringToFront();
-            this.Detail.Controls.Add(xRPicture_pic);
+
+
+            //XRPictureBox xRPicture_pic = new XRPictureBox();
+            //xRPicture_pic.Name = "Picture_kllb_" + position.ToString();
+            //xRPicture_pic.ImageSource = new ImageSource((Image)dataTable.Rows[position]["p1"]);
+            //xRPicture_pic.LocationF = new PointF(1, NeueStartposition);
+            //xRPicture_pic.Visible = true;
+            //xRPicture_pic.BackColor = Color.DarkGray;
+            //xRPicture_pic.Sizing = DevExpress.XtraPrinting.ImageSizeMode.Squeeze;
+            //xRPicture_pic.SizeF = new SizeF(115f, 96.88f);
+            //xRPicture_pic.BringToFront();
+            //this.Detail.Controls.Add(xRPicture_pic);
 
             //NeueStartposition = table.SizeF.Height + NeueStartposition+5;
             NeueStartposition = table.SizeF.Height + NeueStartposition;