Procházet zdrojové kódy

报告程序目测没有遗漏的中文(OTS中英文)

zhangjiaxin před 4 roky
rodič
revize
24aa5b44c9

+ 94 - 6
Bin/x64/Debug/Resources/XMLData/AppResource_EN.xml

@@ -370,6 +370,69 @@
 	  <Control name="label4" text="DataSource" />
 	   <Control name="btn_preview" text="OpenReport" />
 	  <Control name="OTSReport_Export" text="ReportingProgramOutput" />
+	  
+	  <Control name="MessageBox1" text="Exporting report, please wait!" />
+	  <Control name="MessageBox2" text="Later" />
+	  <Control name="MessageBox3" text="The report has been opened, please close it first!" />
+	  <Control name="MessageBox4" text="Tips" />
+	  <Control name="MessageBox5" text="[yes] directly open the report, [no] regenerate the report, [canonical] cancel the operation" />
+	  <Control name="MessageBox6" text="The report has generated data, please select an operation" />
+	  <Control name="MessageBox7" text="Report template database file already exists, open it directly" />
+	  <Control name="RictBox1" text="Start export operation" />
+	  <Control name="RictBox2" text="no files found" />
+	  <Control name="RictBox3" text=", was it not exported?" />
+	  <Control name="RictBox4" text="The settings in the obtained template are:" />
+	  
+	  <Control name="RictBox5" text="Load the measurement result information table module" />
+	  <Control name="RictBox6" text="Loading: measurement result information table" />
+	  <Control name="RictBox7" text="wait for" />
+	  <Control name="RictBox8" text="Loading the measurement result information table module is completed" />
+	  <Control name="RictBox9" text="Load granule list module..." />
+	  <Control name="RictBox10" text="Loading: Particle List" />
+	  <Control name="RictBox11" text="measurement result information table" />
+	  <Control name="RictBox12" text="Loading:" />
+	  <Control name="RictBox13" text="Particle List" />
+	  <Control name="RictBox14" text="Loading granule list module complete" />
+	  
+	  <Control name="RictBox15" text="Load Average Element Content Table module..." />
+	  <Control name="RictBox16" text="Loading: Average Element Content Table" />
+	  <Control name="RictBox17" text="Loading Average Element Content Table Module Completed" />
+	  <Control name="RictBox18" text="Average Element Content Table" />
+	  
+	  <Control name="RictBox19" text="Loading in the particle size table module...." />
+	  <Control name="RictBox20" text="Loading: particle size table" />
+	  <Control name="RictBox21" text="Loading the particle size table module is complete" />
+	  <Control name="RictBox22" text="particle size table" />
+	  
+	  <Control name="RictBox23" text="Loading Particle Composition Diagram Module...." />
+	  <Control name="RictBox24" text="Loading: Particle composition diagram" />
+	  <Control name="RictBox25" text="Loading Particle Composition Diagram Module Completed" />
+	  <Control name="RictBox26" text="Particle composition diagram" />
+	  
+	  <Control name="RictBox27" text="Loading Element Component Diagram Module...." />
+	  <Control name="RictBox28" text="Loading: Elemental composition diagram" />
+	  <Control name="RictBox29" text="Loading Element Component Diagram Module Completed" />
+	  <Control name="RictBox30" text="Elemental composition diagram" />
+	  
+	  <Control name="RictBox31" text="Loading a ternary phase diagram module...." />
+	  <Control name="RictBox32" text="Loading: Ternary Phase Diagram" />
+	  <Control name="RictBox33" text="Loading ternary phase diagram module complete" />
+	  <Control name="RictBox34" text="Ternary Phase Diagram" />
+	  
+	  <Control name="RictBox35" text="Generate Template Template Database File...." />
+	  <Control name="RictBox36" text="Loading: Generate Template Template Database File" />
+	  <Control name="RictBox37" text="Template Temporary Database File Completion" />
+	  <Control name="RictBox38" text="Generate Template Template Database File" />
+	  
+	  <Control name="RictBox39" text="Importing into report template, completed" />
+	  <Control name="RictBox40" text="Null" />
+	  
+	  <Control name="RictBox41" text="Exported:" />
+	  <Control name="RictBox42" text="surface" />
+	  <Control name="RictBox43" text="Export complete!" />
+	  
+	  <Control name="RictBox44" text="The report template has been opened. Please close it first!" />
+	  <Control name="RictBox45" text="Tips" />
     </Controls>
  </Form>
 <Form>
@@ -459,6 +522,22 @@
 	  <Control name="label37" text="CalculationMethod" />
 	  <Control name="button6" text="Save" />
 	  <Control name="OTSReport_TemplateDesignerRM" text="Report preview information settings" />
+	  
+	  <Control name="report1" text="Pie chart" />
+	  <Control name="report2" text="Circle graph" />
+	  <Control name="report3" text="Column chart" />
+	  <Control name="report4" text="Linear graph" />
+	  <Control name="report5" text="Stacking diagram" />
+	  
+	  <Control name="report10" text="Ternary phase diagram template selection requires 2 integral multiples, please re select!" />
+	  <Control name="report11" text="Ternary phase diagram template selection requires 3 integral multiples, please re select!" />
+	  <Control name="report12" text="Tips" />
+	  
+	  <Control name="groupBox9" text="Home page setting information" />
+	  <Control name="label39" text="Template settings" />
+	  <Control name="label38" text="Particle size table information" />
+	  <Control name="label12" text="Particle size table information" />
+	  <Control name="label15" text="Particle size table information" />
     </Controls>
  </Form>
  <Form>
@@ -690,6 +769,11 @@
       <Control name="partcletype7" text="NOT_IDENTIFIED_SIC" />
 	  <Control name="partcletype8" text="NOT_IDENTIFIED_FEO" />
 	  <Control name="partcletype9" text="NOT_IDENTIFIED" />
+	  <Control name="str20" text="spinel" />
+	  <Control name="str21" text="oxide" />
+	  <Control name="str22" text="SulfurOxide" />
+	  <Control name="str23" text="nitrides" />
+	  <Control name="str24" text="sulfide" />
     </Controls>
  </Form>
   <Form>
@@ -824,6 +908,14 @@
 	  <Control name="str8" text="Copy Image" />
 	  <Control name="str9" text="Move SEM to current position" />
 	  <Control name="str10" text="Move SEM to particle view position" />
+	  
+	  <Control name="MouseMove1" text="Particle SEM location:" />
+	  <Control name="MouseMove2" text="Grayscale#" />
+	  
+	  <Control name="BSEOriginal" text="BSE original"/>
+	  <Control name="ClassifiedDisplay" text="Classified display"/>
+	  <Control name="OriginalSplicing" text="Original splicing"/>
+	  <Control name="OriginalDistribution" text="Original distribution"/>
     </Controls>
  </Form>
  <Form>
@@ -1279,12 +1371,8 @@
       <Control name="partcletype7" text="NOT_IDENTIFIED_SIC" />
 	  <Control name="partcletype8" text="NOT_IDENTIFIED_FEO" />
 	  <Control name="partcletype9" text="NOT_IDENTIFIED" />
-	  <Control name="label_Condition" text="Query Conditions:" />
-	  <Control name="label_Area" text="Area" />
-	  <Control name="label_Dmax" text="Dmax" />
-	  <Control name="label_ParticleName" text="ParticleName" />
-	  <Control name="btn_Sel" text="Query" />
-	  <Control name="label_order" text="SortingMode:" />
+	  
+	 
 	  
 	  <Control name="str21" text="Areaμm²" />
 	  <Control name="str22" text="Equivalent circle diameterμm" />

+ 97 - 1
Bin/x64/Debug/Resources/XMLData/AppResource_ZH.xml

@@ -365,7 +365,70 @@
 	  <Control name="btn_TempDes" text="编辑模板" />
 	  <Control name="label4" text="数 据 源" />
 	  <Control name="btn_preview" text="打开报表" />
-	  <Control name="OTSReport_Export" text="报告程序输出界面" />
+	  <Control name="OTSReport_Export" text="报告程序输`界面" />
+	  
+	  <Control name="MessageBox1" text="正在导出报告,请稍候!" />
+	  <Control name="MessageBox2" text="请稍候" />
+	  <Control name="MessageBox3" text="报告已打开,请先关闭!" />
+	  <Control name="MessageBox4" text="提示" />
+	  <Control name="MessageBox5" text="[Yes]直接打开报表,[No]重新生成报表,[Cancal]取消操作" />
+	  <Control name="MessageBox6" text="报表已有生成数据,请选择操作" />
+	  <Control name="MessageBox7" text="报表模板数据库文件已存在,直接打开" />
+	  <Control name="RictBox1" text="开始执行导出操作" />
+	  <Control name="RictBox2" text="未找到文件" />
+	  <Control name="RictBox3" text=",是否未导出?" />
+	  <Control name="RictBox4" text="已获取模板中设置内容为:" />
+	  
+	  <Control name="RictBox5" text="加载测量结果信息表模块中...." />
+	  <Control name="RictBox6" text="加载:测量结果信息表" />
+	  <Control name="RictBox7" text="等待" />
+	  <Control name="RictBox8" text="加载测量结果信息表模块完成" />
+	  <Control name="RictBox9" text="加载颗粒列表模块中...." />
+	  <Control name="RictBox10" text="加载:颗粒列表" />
+	  <Control name="RictBox11" text="测量结果信息表" />
+	  <Control name="RictBox12" text="加载:" />
+	  <Control name="RictBox13" text="颗粒列表" />
+	  <Control name="RictBox14" text="加载颗粒列表模块完成" />
+	  
+	  <Control name="RictBox15" text="加载平均元素含量表模块中...." />
+	  <Control name="RictBox16" text="加载:平均元素含量表" />
+	  <Control name="RictBox17" text="加载平均元素含量表模块完成" />
+	  <Control name="RictBox18" text="平均元素含量表" />
+	  
+	  <Control name="RictBox19" text="加载颗粒尺寸表模块中...." />
+	  <Control name="RictBox20" text="加载:颗粒尺寸表" />
+	  <Control name="RictBox21" text="加载颗粒尺寸表模块完成" />
+	  <Control name="RictBox22" text="颗粒尺寸表" />
+	  
+	  <Control name="RictBox23" text="加载颗粒成份图模块中...." />
+	  <Control name="RictBox24" text="加载:颗粒成份图" />
+	  <Control name="RictBox25" text="加载颗粒成份图模块完成" />
+	  <Control name="RictBox26" text="颗粒成份图" />
+	  
+	  <Control name="RictBox27" text="加载元素成份图模块中...." />
+	  <Control name="RictBox28" text="加载:元素成份图" />
+	  <Control name="RictBox29" text="加载元素成份图模块完成" />
+	  <Control name="RictBox30" text="元素成份图" />
+	  
+	  <Control name="RictBox31" text="加载三元相图模块中...." />
+	  <Control name="RictBox32" text="加载:三元相图" />
+	  <Control name="RictBox33" text="加载三元相图模块完成" />
+	  <Control name="RictBox34" text="三元相图" />
+	  
+	  <Control name="RictBox35" text="生成模板临时数据库文件...." />
+	  <Control name="RictBox36" text="加载:生成模板临时数据库文件" />
+	  <Control name="RictBox37" text="模板临时数据库文件完成" />
+	  <Control name="RictBox38" text="生成模板临时数据库文件" />
+	  
+	  <Control name="RictBox39" text="正在导入到报告模板中,已经完成:" />
+	  <Control name="RictBox40" text="无" />
+	  
+	  <Control name="RictBox41" text="导出了:" />
+	  <Control name="RictBox42" text="表" />
+	  <Control name="RictBox43" text="导出完成!" />
+	  
+	  <Control name="RictBox44" text="报告模板已打开,请先关闭!" />
+	  <Control name="RictBox45" text="提示" />
     </Controls>
  </Form>
 <Form>
@@ -455,6 +518,22 @@
 	  <Control name="label37" text="计算方式" />
 	  <Control name="button6" text="保存" />
 	  <Control name="OTSReport_TemplateDesignerRM" text="报告预览信息设置" />
+	  
+	  <Control name="report1" text="饼图" />
+	  <Control name="report2" text="圈图" />
+	  <Control name="report3" text="柱形图" />
+	  <Control name="report4" text="线状图" />
+	  <Control name="report5" text="堆叠图" />
+	  
+	  <Control name="report10" text="三元相图模板选择项需2整倍数,请重新选择!" />
+	  <Control name="report11" text="三元相图模板选择项需3整倍数,请重新选择!" />
+	  <Control name="report12" text="提示" />
+	  
+	  <Control name="groupBox9" text="首页设置信息" />
+	  <Control name="label39" text="模板设置" />
+	  <Control name="label38" text="粒级表信息" />
+	  <Control name="label12" text="粒级表信息" />
+	  <Control name="label15" text="粒级表信息" />
     </Controls>
  </Form>
  <Form>
@@ -686,6 +765,11 @@
       <Control name="partcletype7" text="非夹杂物颗粒SiC" />
 	  <Control name="partcletype8" text="非夹杂物颗粒FeO" />
 	  <Control name="partcletype9" text="未识别颗粒" />
+	  <Control name="str20" text="尖晶石" />
+	  <Control name="str21" text="氧化物" />
+	  <Control name="str22" text="硫氧化物" />
+	  <Control name="str23" text="氮化物" />
+	  <Control name="str24" text="硫化物" />
     </Controls>
  </Form>
  <Form>
@@ -820,6 +904,15 @@
 	  <Control name="str8" text="复制图像" />
 	  <Control name="str9" text="移动SEM到当前位置" />
 	  <Control name="str10" text="移动SEM到颗粒视域位置" />
+	  
+	  <Control name="MouseMove1" text="颗粒SEM位置:" />
+	  <Control name="MouseMove2" text="灰度#" />
+	  
+	   <Control name="BSEOriginal" text="BSE原图" />
+	  <Control name="ClassifiedDisplay" text="分类显示" />
+	  <Control name="OriginalSplicing" text="原图拼接" />
+	  <Control name="OriginalDistribution" text="原图颗粒分布" />
+	  
     </Controls>
  </Form>
  <Form>
@@ -1471,4 +1564,7 @@
 	  <Control name="button1" text="确  定" />
     </Controls>
  </Form>
+ 
+
+ 
 </Resource>

+ 20 - 14
OTSIncAReportApp/1-UI/Control_ECharts/EChart_ParticlesComposition.cs

@@ -19,6 +19,7 @@ namespace OTSIncAReportApp.Control_ECharts
     /// </summary>
     public partial class EChart_ParticlesComposition : UserControl
     {
+        Hashtable table;
 
         #region 图表相关变量
         //y轴名称
@@ -51,13 +52,13 @@ namespace OTSIncAReportApp.Control_ECharts
             m_conditionChoose = ReportApp.m_conditionChoose;
             m_DataMgr = ReportApp.m_DataMgrFun;
             InitializeComponent();
-
+            //国际化
+            Language lan = new Language();
+            table = lan.GetNameTable("CompositionDistributionGrid");
         }
         private void EChart_ParticlesComposition_Load(object sender, EventArgs e)
         {
-            //国际化
-            Language lan = new Language();
-            Hashtable table = lan.GetNameTable("CompositionDistributionGrid");
+            
 
             NameList = new List<string>() { table["partcletype0"].ToString(), table["partcletype1"].ToString(), table["partcletype2"].ToString(), table["partcletype4"].ToString(), table["partcletype6"].ToString(), table["partcletype7"].ToString(), table["partcletype8"].ToString(), table["partcletype9"].ToString() };
 
@@ -105,6 +106,11 @@ namespace OTSIncAReportApp.Control_ECharts
         #region 获取单数据源
         private Chartdate GetCommonlyUsedClassifyData(string path)
         {
+            string spinel = table["str20"].ToString();
+            string oxide = table["str21"].ToString();
+            string SulfurOxide = table["str22"].ToString();
+            string nitrides = table["str23"].ToString();
+            string sulfide = table["str24"].ToString();
             DataOperation.DataAccess.ParticleData particledata = new DataOperation.DataAccess.ParticleData(path);
             //创建新的图形数据源
             Chartdate chart = new Chartdate();
@@ -133,11 +139,11 @@ namespace OTSIncAReportApp.Control_ECharts
 
             //设置标签名称
             List<string> listName = new List<string>();
-            listName.Add("尖晶石");
-            listName.Add("氧化物");
-            listName.Add("硫氧化物");
-            listName.Add("氮化物");
-            listName.Add("硫化物");
+            listName.Add(spinel);
+            listName.Add(oxide);
+            listName.Add(SulfurOxide);
+            listName.Add(nitrides);
+            listName.Add(sulfide);
             chart.ListName = listName;
 
             //设置数据
@@ -150,31 +156,31 @@ namespace OTSIncAReportApp.Control_ECharts
                     Item item_SPINEL = new Item()
                     {
                         value = decimal.Round(decimal.Parse(dt.Rows[k]["SPINEL"].ToString()), 2).ToString(),
-                        name = "尖晶石"
+                        name = spinel
                     };
                     listData.Add(item_SPINEL);
                     Item item_OXIDE = new Item()
                     {
                         value = decimal.Round(decimal.Parse(dt.Rows[k]["OXIDE"].ToString()), 2).ToString(),
-                        name = "氧化物"
+                        name = oxide
                     };
                     listData.Add(item_OXIDE);
                     Item item_SULFIDE_OXIDE = new Item()
                     {
                         value = decimal.Round(decimal.Parse(dt.Rows[k]["SULFIDE_OXIDE"].ToString()), 2).ToString(),
-                        name = "硫氧化物"
+                        name = SulfurOxide
                     };
                     listData.Add(item_SULFIDE_OXIDE);
                     Item item_NITRIDE = new Item()
                     {
                         value = decimal.Round(decimal.Parse(dt.Rows[k]["NITRIDE"].ToString()), 2).ToString(),
-                        name = "氮化物"
+                        name = nitrides
                     };
                     listData.Add(item_NITRIDE);
                     Item item_SULFIDE = new Item()
                     {
                         value = decimal.Round(decimal.Parse(dt.Rows[k]["SULFIDE"].ToString()), 2).ToString(),
-                        name = "硫化物"
+                        name = sulfide
                     };
                     listData.Add(item_SULFIDE);
                 }

+ 3 - 1
OTSIncAReportApp/1-UI/Control_ECharts/EChart_Trianglediagram.cs

@@ -70,6 +70,8 @@ namespace OTSIncAReportApp.Control_ECharts
             m_old_list_string_sizelevel = new List<string>();
             Template = Templates;
             m_ReportApp = ReportApp;
+            m_condition = ReportApp.m_conditionChoose;
+            m_DataMgr = ReportApp.m_DataMgrFun;
 
             InitializeComponent();
         }
@@ -105,7 +107,7 @@ namespace OTSIncAReportApp.Control_ECharts
             //将所有的测量结果名添加到list中
             m_list_string_samplename.Clear();
 
-            string sou = m_condition.m_SourceGridData.GetPropItemValueByPropItemName(OTS_REPORT_PROP_GRID_ITEMS.DATA_SOURCE).ToString();
+            string sou = m_condition.m_CurrentConditions[OTS_REPORT_PROP_GRID_ITEMS.DATA_SOURCE].itemDisplayVal.ToString();
             if (sou.Contains("+"))
             {
                 if (m_ReportApp.more)

+ 11 - 7
OTSIncAReportApp/1-UI/Control_Graph/Controls/Control_DrawDistrbutionImageAndBSE.cs

@@ -1018,7 +1018,7 @@ namespace OTSIncAReportGraph.Controls
                                 ShowXRay(dp);
 
                             //m_sem_mouse_now_point = new Point(dp.SEMPosX, dp.SEMPosY);
-                            m_str_mouseshow_left = "颗粒SEM位置:" + dp.SEMPosX.ToString() + ":" + dp.SEMPosY.ToString();
+                            m_str_mouseshow_left = table["mousemove1"].ToString() + dp.SEMPosX.ToString() + ":" + dp.SEMPosY.ToString();
                         }
                         else
                         {
@@ -1046,7 +1046,7 @@ namespace OTSIncAReportGraph.Controls
 
             //获取颜色方法1,使用API来获取当前鼠标指向位置的颜色值-----------------------------------------------------
             Color ls_c = GetColorByMousePoint(e.X, e.Y);
-            m_str_mouseshow_right = "灰度#" + ls_c.R.ToString();
+            m_str_mouseshow_right = table["mousemove2"].ToString() + ls_c.R.ToString();
 
           
 
@@ -1265,8 +1265,8 @@ namespace OTSIncAReportGraph.Controls
                         m_sem_mouse_now_point = new Point(dp.SEMPosX, dp.SEMPosY);
                         //获取颜色方法1,使用API来获取当前鼠标指向位置的颜色值-----------------------------------------------------
                         Color ls_c = GetColorByMousePoint(e.X, e.Y);
-                        m_str_mouseshow_right = "灰度#" + ls_c.R.ToString();
-                        m_str_mouseshow_left = "颗粒SEM位置:" + dp.SEMPosX.ToString() + ":" + dp.SEMPosY.ToString();
+                        m_str_mouseshow_right = table["mousemove2"].ToString() + ls_c.R.ToString();
+                        m_str_mouseshow_left = table["mousemove1"].ToString() + ":" + dp.SEMPosY.ToString();
 
                         m_ReportApp.mouseMatter.Text = m_str_mouseshow_right;
                         m_ReportApp.RSGrayVal.Text = m_str_mouseshow_left;
@@ -1949,7 +1949,11 @@ namespace OTSIncAReportGraph.Controls
         /// <param name="a_type">false为显示原bse图像,true为显示带有标准库代表色的图像</param>
         public void ShowMode(string a_type)
         {
-            if (a_type == "BSE")
+            string BSEOriginal = table["bseoriginal"].ToString();//BSE原图
+            string ClassifiedDisplay = table["classifieddisplay"].ToString();//分类显示
+            string OriginalSplicing = table["originalsplicing"].ToString();//原图拼接
+            string OriginalDistribution = table["originaldistribution"].ToString();//原图颗粒分布
+            if (a_type == BSEOriginal)
             {
                 OriginalBackground = false;
                 //bse图时,显示背景图为白色
@@ -1963,7 +1967,7 @@ namespace OTSIncAReportGraph.Controls
                 }
                 FullGraphMatch();
             }
-            else if (a_type== "Original")
+            else if (a_type== OriginalSplicing)
             {
                 OriginalBackground = true;
                 foreach (DisplayParticle ls_dp in m_list_allDPart)
@@ -1975,7 +1979,7 @@ namespace OTSIncAReportGraph.Controls
                 }
                 FullGraphMatch();
             }
-            else if(a_type== "原图颗粒分布")
+            else if(a_type== OriginalDistribution)
             {
                 OriginalBackground = true;
                 foreach (DisplayParticle ls_dp in m_list_allDPart)

+ 2 - 2
OTSIncAReportApp/1-UI/Control_Grids/ParticlesGridDevidePage.cs

@@ -1500,7 +1500,7 @@ namespace OTSIncAReportGrids
         {
             //将所有的数据导出到EXCEL中
             SaveFileDialog sfd = new SaveFileDialog();
-            sfd.Filter = "Excel文件(*.xls)|*.xls";
+            sfd.Filter = "Excel File(*.xls)|*.xls";
             //设置默认文件类型显示顺序
             sfd.FilterIndex = 1;
 
@@ -1601,7 +1601,7 @@ namespace OTSIncAReportGrids
                 workbook.Write(file);
                 file.Close();
 
-                MessageBox.Show("导出完成!");
+                MessageBox.Show("Export complete!");
 
                 //导出完成后,打开Excel文件
                 if (File.Exists(sfd.FileName))

+ 1 - 1
OTSIncAReportApp/1-UI/OTSDisplaySourceGridData/OTSSourceGrid.cs

@@ -100,7 +100,7 @@ namespace OTSIncAReportApp.OTSDataMgrFunction
         /// <summary>
         /// 通用参数组的标题名
         /// </summary>
-        public String m_Display_Mode_Name = "参数";
+        public String m_Display_Mode_Name = "parameter";
 
         /// <summary>
         /// 通用参数组的GRID行数

+ 5 - 5
OTSIncAReportApp/1-UI/OTSMgrInfo/Triangulation_Edit.cs

@@ -116,11 +116,11 @@ namespace OTSIncAReportApp.OTSMgrInfo
                 bool ret = DataOperation.DataAccess.XMLoperate.UpdateByAttribute(pathe, AttributeName, Value);
                 if (ret)
                 {
-                    MessageBox.Show("保存成功!");
+                    MessageBox.Show("Saved successfully!");
                 }
                 else
                 {
-                    MessageBox.Show("保存失败!");
+                    MessageBox.Show("Save failed!");
                 }
             }
             else
@@ -131,15 +131,15 @@ namespace OTSIncAReportApp.OTSMgrInfo
                 int ret = DataOperation.DataAccess.XMLoperate.InsertAttribute(pathe, AttributeName, Value, "Member");
                 if (ret == -1)
                 {
-                    MessageBox.Show(TemplateName + "模板已经存在,不可重复添加!");
+                    MessageBox.Show(TemplateName + "The template already exists and cannot be added repeatedly!");
                 }
                 else if (ret == 0)
                 {
-                    MessageBox.Show("保存失败!");
+                    MessageBox.Show("Save failed!");
                 }
                 else
                 {
-                    MessageBox.Show("保存成功!");
+                    MessageBox.Show("Saved successfully!");
                 }
             }
 

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

@@ -529,7 +529,7 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
                     }
 
                     //total,不为空行,和不能是总计行
-                    if (dr2["SName"].ToString() != "" && dr2["SName"].ToString().IndexOf("个数") < 0)
+                    if (dr2["SName"].ToString() != "" && dr2["SName"].ToString().IndexOf("number") < 0)
                     {
                         dr2["total"] = "0"; //求合
                         double d_total = 0;

+ 74 - 190
OTSIncAReportApp/1-UI/OTSTemplateDesigner/OTSReport_Export.cs

@@ -28,7 +28,7 @@ namespace OTSIncAReportApp
         public string m_strDBpath = "";                                 //报表模板数据库文件
         public string m_strDBpathGB = "";                               //报告国标导出
         public string m_strDBpath_ParticleList = "";                    //报表模板,颗粒列表数据库文件
-
+        System.Collections.Hashtable table;
         public frmReportApp m_ReportApp = null;                         //报告项目总进程对象
         public string m_export_type = "Excel";                          //导出文件的格式类型Excel,Word,Pdf
 
@@ -502,6 +502,7 @@ namespace OTSIncAReportApp
 
             #region 国际化语言
             Language lan = new Language(this);
+            table = lan.GetNameTable(this.Name);
             #endregion
 
         }
@@ -704,126 +705,8 @@ namespace OTSIncAReportApp
                 }
             }
         }
-        /// <summary>
-        /// 初始化模板条件编辑界面默认的值
-        /// </summary>
-        private void InitMBSZClass()
-        {
-            m_mbszclass = new MBSZClass();
-            //首页
-            m_mbszclass.M_SY.str_tb_ZBT = "夹杂物分析报告";
-            m_mbszclass.M_SY.str_tb_FBT = "XXX有限公司";
-            m_mbszclass.M_SY.str_tb_YPBH = "A009412030003";
-            m_mbszclass.M_SY.str_tb_CKBZ = "GB/T30834-2014";
-            m_mbszclass.M_SY.b_ck_ypsm = true;
-            m_mbszclass.M_SY.b_ck_jggk = true;
-
-            //页眉页脚
-            m_mbszclass.M_YMYJ.str_tb_ymwb = "夹杂物分析报告";
-            m_mbszclass.M_YMYJ.str_tb_KHH = "Copi0000123012";
-            m_mbszclass.M_YMYJ.b_ck_ym = true;
-            m_mbszclass.M_YMYJ.str_tb_yjwb = "OTS-IncA Report System";
-
-            //颗粒分析结果
-            m_mbszclass.M_KLFXJG.b_ck_klcc_xsmk = true;
-            //计算方式
-            m_mbszclass.M_KLFXJG.index_cb_klcc_jsfs = 0;
-            //粒级表
-            m_mbszclass.M_KLFXJG.index_cb_klcc_ljb = 0;
-            //颗粒范围
-            m_mbszclass.M_KLFXJG.index_cb_klcc_klfw = 0;
-
-            m_mbszclass.M_KLFXJG.b_cb_jzwfl_xsmk = true;
-            //选择图像
-            m_mbszclass.M_KLFXJG.index_cb_jzwfl_xstx = 2;//柱状图
-            //计算方式
-            m_mbszclass.M_KLFXJG.index_cb_jzwfl_jsfs = 0;
-            //粒级表
-            m_mbszclass.M_KLFXJG.index_cb_jzwfl_ljb = 0;
-            //颗粒范围
-            m_mbszclass.M_KLFXJG.index_cb_jzwfl_klfw = 0;
-
-            //元素分析结果
-            m_mbszclass.M_YSFXJG.b_ck_ysfx_xsmk = true;
-            //计算方式
-            m_mbszclass.M_YSFXJG.index_cb_yxfx_jsfs = 0;
-            //颗粒范围
-            m_mbszclass.M_YSFXJG.index_cb_ysfx_klfw = 0;
-            m_mbszclass.M_YSFXJG.str_tb_ysfx_xsys = "O,Al,Mg,Ca,Ti,Si,S,Mn,N";//显示元素
-            m_mbszclass.M_YSFXJG.list_str_tb_ysfx_xsys.Add("O");
-            m_mbszclass.M_YSFXJG.list_str_tb_ysfx_xsys.Add("Al");
-            m_mbszclass.M_YSFXJG.list_str_tb_ysfx_xsys.Add("Mg");
-            m_mbszclass.M_YSFXJG.list_str_tb_ysfx_xsys.Add("Ca");
-            m_mbszclass.M_YSFXJG.list_str_tb_ysfx_xsys.Add("Ti");
-            m_mbszclass.M_YSFXJG.list_str_tb_ysfx_xsys.Add("Si");
-            m_mbszclass.M_YSFXJG.list_str_tb_ysfx_xsys.Add("S");
-            m_mbszclass.M_YSFXJG.list_str_tb_ysfx_xsys.Add("Mn");
-            m_mbszclass.M_YSFXJG.list_str_tb_ysfx_xsys.Add("N");
-
-            m_mbszclass.M_YSFXJG.b_ck_yscf_xsmk = true;
-            //显示图形
-            m_mbszclass.M_YSFXJG.index_cb_yscf_xstx = 1;//圈图
-            //计算方式
-            m_mbszclass.M_YSFXJG.index_cb_yscf_jsfs = 0;
-            //颗粒范围
-            m_mbszclass.M_YSFXJG.index_cb_yscf_klfw = 0;
-            m_mbszclass.M_YSFXJG.str_tb_yscf_ysxx = "O,Al,Mg,Ca,Ti,Si,S,Mn,N";//显示元素
-            m_mbszclass.M_YSFXJG.list_str_tb_yscf_ysxx.Add("O");
-            m_mbszclass.M_YSFXJG.list_str_tb_yscf_ysxx.Add("Al");
-            m_mbszclass.M_YSFXJG.list_str_tb_yscf_ysxx.Add("Mg");
-            m_mbszclass.M_YSFXJG.list_str_tb_yscf_ysxx.Add("Ca");
-            m_mbszclass.M_YSFXJG.list_str_tb_yscf_ysxx.Add("Ti");
-            m_mbszclass.M_YSFXJG.list_str_tb_yscf_ysxx.Add("Si");
-            m_mbszclass.M_YSFXJG.list_str_tb_yscf_ysxx.Add("S");
-            m_mbszclass.M_YSFXJG.list_str_tb_yscf_ysxx.Add("Mn");
-            m_mbszclass.M_YSFXJG.list_str_tb_yscf_ysxx.Add("N");
-
-            //三元相图
-            m_mbszclass.M_SYXT.b_ck_syxt_xsmk = true;
-            //计算方式
-            m_mbszclass.M_SYXT.index_cb_syxt_jsfs = 0;
-            //颗粒范围
-            m_mbszclass.M_SYXT.index_cb_syxt_klfw = 0;
-            m_mbszclass.M_SYXT.str_cb_syxt_mhxssl = "2";//每行显示数量
-
-            //获取勾选的项
-            m_mbszclass.M_SYXT.list_lbv_syxt_mblb.Add("MgO.CaO.Al2O3");
-            m_mbszclass.M_SYXT.list_lbv_syxt_mblb.Add("CaO.S.Al2O3");
-            m_mbszclass.M_SYXT.list_lbv_syxt_mblb.Add("CaO.SiO2.Al2O3");
-            m_mbszclass.M_SYXT.list_lbv_syxt_mblb.Add("MnO.S.Al2O3");
-            m_mbszclass.M_SYXT.list_lbv_syxt_mblb.Add("CaO.TiN.Al2O3");
-            m_mbszclass.M_SYXT.list_lbv_syxt_mblb.Add("CaO.AlN.Al2O3");
-
-            m_mbszclass.M_SYXT.list_lbv_syxt_mblb_index.Add(0);
-            m_mbszclass.M_SYXT.list_lbv_syxt_mblb_index.Add(1);
-            m_mbszclass.M_SYXT.list_lbv_syxt_mblb_index.Add(2);
-            m_mbszclass.M_SYXT.list_lbv_syxt_mblb_index.Add(3);
-            m_mbszclass.M_SYXT.list_lbv_syxt_mblb_index.Add(4);
-            m_mbszclass.M_SYXT.list_lbv_syxt_mblb_index.Add(5);
-
-            //颗粒列表信息
-            m_mbszclass.M_KLLBXX.b_ck_kllb_xsmk = true;
-            //计算方式
-            m_mbszclass.M_KLLBXX.index_cb_kllb_jsfs = 0;
-            //颗粒范围
-            m_mbszclass.M_KLLBXX.index_cb_kllb_klfw = 0;
-
-            m_mbszclass.M_KLLBXX.int_tb_kllb_ylsx = 20;//数量上限
-            m_mbszclass.M_KLLBXX.str_tb_kllb_sxys = "O,Al,Mg,Ca,Ti,Si,S,Mn,N";//显示元素
-            m_mbszclass.M_KLLBXX.list_str_tb_lllb_sxys.Add("O");
-            m_mbszclass.M_KLLBXX.list_str_tb_lllb_sxys.Add("Al");
-            m_mbszclass.M_KLLBXX.list_str_tb_lllb_sxys.Add("Mg");
-            m_mbszclass.M_KLLBXX.list_str_tb_lllb_sxys.Add("Ca");
-            m_mbszclass.M_KLLBXX.list_str_tb_lllb_sxys.Add("Ti");
-            m_mbszclass.M_KLLBXX.list_str_tb_lllb_sxys.Add("Si");
-            m_mbszclass.M_KLLBXX.list_str_tb_lllb_sxys.Add("S");
-            m_mbszclass.M_KLLBXX.list_str_tb_lllb_sxys.Add("Mn");
-            m_mbszclass.M_KLLBXX.list_str_tb_lllb_sxys.Add("N");
-            m_mbszclass.M_KLLBXX.b_ck_kllb_ystx = true;//原始图像
-            m_mbszclass.M_KLLBXX.b_ck_kllb_fdtx = true;//放大图像
-            m_mbszclass.M_KLLBXX.b_ck_kllb_npxx = true;//能谱图像
-
-        }
+ 
+     
 
         /// <summary>
         /// 加载报告模板选择项,数据源选项
@@ -1199,7 +1082,7 @@ namespace OTSIncAReportApp
             if (backgroundWorker2.IsBusy == true)
             {
                 //导出线程正在工作中,不让退出该界面
-                MessageBox.Show("正在导出报告,请稍候!", "请稍候", MessageBoxButtons.OK, MessageBoxIcon.Information);
+                MessageBox.Show(table["messagebox1"].ToString(), table["messagebox2"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
                 //然后取消关闭窗体的事件
                 e.Cancel = true;
             }
@@ -1215,7 +1098,7 @@ namespace OTSIncAReportApp
             {
                 if (proc.ProcessName == "OTSIncAReportTemplate")
                 {
-                    DialogResult dr = MessageBox.Show("报告已打开,请先关闭!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Warning);
+                    DialogResult dr = MessageBox.Show(table["messagebox3"].ToString(), table["messagebox4"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Warning);
                     if (dr == DialogResult.OK)
                     {
                         return;
@@ -1226,11 +1109,11 @@ namespace OTSIncAReportApp
             //判断该测量结果文件目录中是否已经有数据库文件,有的话,直接打开,没有则进行导出数据库然后再打开
             if (File.Exists(m_strDBpath))
             {
-                DialogResult dr = MessageBox.Show("[Yes]直接打开报表,[No]重新生成报表,[Cancal]取消操作", "报表已有生成数据,请选择操作", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Question);
+                DialogResult dr = MessageBox.Show(table["messagebox5"].ToString(), table["messagebox6"].ToString(), MessageBoxButtons.YesNoCancel, MessageBoxIcon.Question);
 
                 if (dr == DialogResult.Yes)
                 {
-                    WriteRictBox("报表模板数据库文件已存在,直接打开-----------");
+                    WriteRictBox(table["messagebox7"].ToString());
                     //存在则直接打开报表
                     OpenOTSINcAreportTemplateAPP();
                     return;
@@ -1250,7 +1133,7 @@ namespace OTSIncAReportApp
             //重新导出报表数据
             m_ReportApp.m_ChartsWindow.Activate();
 
-            WriteRictBox("开始执行导出操作-----------");
+            WriteRictBox(table["rictbox1"].ToString());
             progressBar1.Value = 0;
 
             //预览
@@ -1271,7 +1154,7 @@ namespace OTSIncAReportApp
             }
             else
             {
-                WriteRictBox("未找到文件" + tb_lj.Text.Trim() + ",是否未导出?");
+                WriteRictBox(table["rictbox2"].ToString() + tb_lj.Text.Trim() + table["rictbox3"].ToString());
             }
         }
 
@@ -1735,7 +1618,7 @@ namespace OTSIncAReportApp
             #region //获取模板设置的导出的内容-------------------------------------------------
 
             //获取报告模板设置内容
-            worker.ReportProgress(0, "已获取模板中设置内容为:-------------------");
+            worker.ReportProgress(0, table["rictbox4"].ToString());
             System.Threading.Thread.Sleep(1);
             //更新进度
             worker.ReportProgress(5);
@@ -1749,126 +1632,126 @@ namespace OTSIncAReportApp
             i_zz = 80 / 9;
 
             //首先将测量结果信息表导出,在表头------------------------------------------------
-            worker.ReportProgress(0, "加载测量结果信息表模块中....");
-            worker.ReportProgress(0, "加载:测量结果信息表");
+            worker.ReportProgress(0, table["rictbox5"].ToString());
+            worker.ReportProgress(0, table["rictbox6"].ToString());
             //更新进度条
             processvalue = processvalue + 1;
             worker.ReportProgress(processvalue);
             lock (m_thread_flag)
-                m_thread_flag = "等待";
-            while (m_thread_flag == "等待")
+                m_thread_flag = table["rictbox7"].ToString();
+            while (m_thread_flag == table["rictbox7"].ToString())
             {
                 System.Threading.Thread.Sleep(500);
             }
-            worker.ReportProgress(0, "加载测量结果信息表模块完成");
+            worker.ReportProgress(0, table["rictbox8"].ToString());
             //-------------------------------------------------------------------------
 
             //调用输出,颗粒列表----------------------------------------
-            worker.ReportProgress(0, "加载颗粒列表模块中....");
-            worker.ReportProgress(0, "加载:颗粒列表");
+            worker.ReportProgress(0, table["rictbox9"].ToString());
+            worker.ReportProgress(0, table["rictbox10"].ToString());
             //更新进度条
             processvalue = processvalue + i_zz;
             worker.ReportProgress(processvalue);
             lock (m_thread_flag)
-                m_thread_flag = "等待";
-            while (m_thread_flag == "等待")
+                m_thread_flag = table["rictbox7"].ToString();
+            while (m_thread_flag == table["rictbox7"].ToString())
             {
                 System.Threading.Thread.Sleep(500);
             }
-            worker.ReportProgress(0, "加载颗粒列表模块完成");
+            worker.ReportProgress(0, table["rictbox14"].ToString());
 
 
 
             //调用输出,平均元素含量表---------------------------------------
-            worker.ReportProgress(0, "加载平均元素含量表模块中....");
-            worker.ReportProgress(0, "加载:平均元素含量表");
+            worker.ReportProgress(0, table["rictbox15"].ToString());
+            worker.ReportProgress(0, table["rictbox16"].ToString());
             //更新进度条
             processvalue = processvalue + i_zz;
             worker.ReportProgress(processvalue);
             lock (m_thread_flag)
-                m_thread_flag = "等待";
-            while (m_thread_flag == "等待")
+                m_thread_flag = table["rictbox7"].ToString();
+            while (m_thread_flag == table["rictbox7"].ToString())
             {
                 System.Threading.Thread.Sleep(500);
             }
-            worker.ReportProgress(0, "加载平均元素含量表模块完成");
+            worker.ReportProgress(0, table["rictbox17"].ToString());
 
 
 
             //调用输出,颗粒尺寸表--------------------------------------
-            worker.ReportProgress(0, "加载颗粒尺寸表模块中....");
-            worker.ReportProgress(0, "加载:颗粒尺寸表");
+            worker.ReportProgress(0, table["rictbox19"].ToString());
+            worker.ReportProgress(0, table["rictbox20"].ToString());
             //更新进度条
             processvalue = processvalue + i_zz;
             worker.ReportProgress(processvalue);
             lock (m_thread_flag)
-                m_thread_flag = "等待";
-            while (m_thread_flag == "等待")
+                m_thread_flag = table["rictbox7"].ToString();
+            while (m_thread_flag == table["rictbox7"].ToString())
             {
                 System.Threading.Thread.Sleep(500);
             }
-            worker.ReportProgress(0, "加载颗粒尺寸表模块完成");
+            worker.ReportProgress(0, table["rictbox21"].ToString());
 
 
 
 
             //调用,颗粒成份图------------------------------------------------
-            worker.ReportProgress(0, "加载颗粒成份图模块中....");
-            worker.ReportProgress(0, "加载:颗粒成份图");
+            worker.ReportProgress(0, table["rictbox23"].ToString());
+            worker.ReportProgress(0, table["rictbox24"].ToString());
             //更新进度条
             processvalue = processvalue + i_zz;
             worker.ReportProgress(processvalue);
             lock (m_thread_flag)
-                m_thread_flag = "等待";
-            while (m_thread_flag == "等待")
+                m_thread_flag = table["rictbox7"].ToString();
+            while (m_thread_flag == table["rictbox7"].ToString())
             {
                 System.Threading.Thread.Sleep(500);
             }
-            worker.ReportProgress(0, "加载颗粒成份图模块完成");
+            worker.ReportProgress(0, table["rictbox25"].ToString());
 
             //调用,元素成份图---------------------------------------------
-            worker.ReportProgress(0, "加载元素成份图模块中....");
-            worker.ReportProgress(0, "加载:元素成份图");
+            worker.ReportProgress(0, table["rictbox27"].ToString());
+            worker.ReportProgress(0, table["rictbox28"].ToString());
             //更新进度条
             processvalue = processvalue + i_zz;
             worker.ReportProgress(processvalue);
             lock (m_thread_flag)
-                m_thread_flag = "等待";
-            while (m_thread_flag == "等待")
+                m_thread_flag = table["rictbox7"].ToString();
+            while (m_thread_flag == table["rictbox7"].ToString())
             {
                 System.Threading.Thread.Sleep(500);
             }
-            worker.ReportProgress(0, "加载元素成份图模块完成");
+            worker.ReportProgress(0, table["rictbox29"].ToString());
 
 
             //调用,三元相图----------------------------------------------
-            worker.ReportProgress(0, "加载三元相图模块中....");
-            worker.ReportProgress(0, "加载:三元相图");
+            worker.ReportProgress(0, table["rictbox31"].ToString());
+            worker.ReportProgress(0, table["rictbox32"].ToString());
             //更新进度条
             processvalue = processvalue + i_zz;
             worker.ReportProgress(processvalue);
             lock (m_thread_flag)
-                m_thread_flag = "等待";
-            while (m_thread_flag == "等待")
+                m_thread_flag = table["rictbox7"].ToString();
+            while (m_thread_flag == table["rictbox7"].ToString())
             {
                 System.Threading.Thread.Sleep(500);
             }
-            worker.ReportProgress(0, "加载三元相图模块完成");
+            worker.ReportProgress(0, table["rictbox33"].ToString());
 
 
             //生成,模板临时数据库文件----------------------------------------------
-            worker.ReportProgress(0, "生成模板临时数据库文件....");
-            worker.ReportProgress(0, "加载:生成模板临时数据库文件");
+            worker.ReportProgress(0, table["rictbox35"].ToString());
+            worker.ReportProgress(0, table["rictbox36"].ToString());
             //更新进度条
             processvalue = processvalue + i_zz;
             worker.ReportProgress(processvalue);
             lock (m_thread_flag)
-                m_thread_flag = "等待";
-            while (m_thread_flag == "等待")
+                m_thread_flag = table["rictbox7"].ToString();
+            while (m_thread_flag == table["rictbox7"].ToString())
             {
                 System.Threading.Thread.Sleep(500);
             }
-            worker.ReportProgress(0, "模板临时数据库文件完成");
+            worker.ReportProgress(0, table["rictbox37"].ToString());
 
             #endregion 依将循环调用各功能模块结束-------------------------------------------------------
         }
@@ -1887,6 +1770,7 @@ namespace OTSIncAReportApp
 
         private void backgroundWorker2_ProgressChanged(object sender, ProgressChangedEventArgs e)
         {
+            string strNill = table["rictbox40"].ToString();
             BackgroundWorker worker = sender as BackgroundWorker;
           
             //更新进度条的进度
@@ -1896,79 +1780,79 @@ namespace OTSIncAReportApp
                 WriteRictBox((string)e.UserState);
                 
              string s=  AnalyticGraphics(m_mbszclass.M_KLFXJG.index_cb_jzwfl_xstx);
-                if (ls_str.IndexOf("加载:") > -1)
+                if (ls_str.IndexOf(table["rictbox12"].ToString()) > -1)
                 {
-                    if (ls_str.IndexOf("测量结果信息表") > -1)
+                    if (ls_str.IndexOf(table["rictbox11"].ToString()) > -1)
                     {
                         m_export_reporttemplate.InsertReportTemplateTable_ResultGrid();
                         lock (m_thread_flag)
-                            m_thread_flag = "无";
+                            m_thread_flag = strNill;
                     }
-                    if (ls_str.IndexOf("颗粒列表") > -1)
+                    if (ls_str.IndexOf(table["rictbox13"].ToString()) > -1)
                     {
                         m_export_reporttemplate.InsertReportTemplateTable_ParticlesGridDevidePage();
                         lock (m_thread_flag)
-                            m_thread_flag = "无";
+                            m_thread_flag = strNill;
                     }
 
-                    if (ls_str.IndexOf("平均元素含量表") > -1)
+                    if (ls_str.IndexOf(table["rictbox18"].ToString()) > -1)
                     {
                         m_export_reporttemplate.InsertReportTemplateTable_ElementCompositionAvgGrid();
                         lock (m_thread_flag)
-                            m_thread_flag = "无";
+                            m_thread_flag = strNill;
                     }
 
-                    if (ls_str.IndexOf("颗粒尺寸表") > -1)
+                    if (ls_str.IndexOf(table["rictbox22"].ToString()) > -1)
                     {
                         m_export_reporttemplate.InsertReportTemplateTable_ParticleSizeGrid();
                         lock (m_thread_flag)
-                            m_thread_flag = "无";
+                            m_thread_flag = strNill;
                     }
 
-                    if (ls_str.IndexOf("颗粒成份图") > -1)
+                    if (ls_str.IndexOf(table["rictbox26"].ToString()) > -1)
                     {
                         m_export_reporttemplate.InsertReportTemplateChart_ParticlesCompositionChart(AnalyticGraphics(m_mbszclass.M_KLFXJG.index_cb_jzwfl_xstx));
                         lock (m_thread_flag)
-                            m_thread_flag = "无";
+                            m_thread_flag = strNill;
                     }
-                    if (ls_str.IndexOf("元素成份图") > -1)
+                    if (ls_str.IndexOf(table["rictbox30"].ToString()) > -1)
                     {
                         m_export_reporttemplate.InsertReportTemplateChart_ElementCompositionChart(AnalyticGraphics(m_mbszclass.M_YSFXJG.index_cb_yscf_xstx));
                         lock (m_thread_flag)
-                            m_thread_flag = "无";
+                            m_thread_flag = strNill;
                     }
 
-                    if (ls_str.IndexOf("三元相图") > -1)
+                    if (ls_str.IndexOf(table["rictbox34"].ToString()) > -1)
                     {
                         m_export_reporttemplate.InsertReportTemplateChart_Trianglediagram();
                         lock (m_thread_flag)
-                            m_thread_flag = "无";
+                            m_thread_flag = strNill;
                     }
 
-                    if (ls_str.IndexOf("模板临时数据库文件") > -1)
+                    if (ls_str.IndexOf(table["rictbox38"].ToString()) > -1)
                     {
                         //导出到数据库文件中
                         SaveReportTemplateDBFile();
 
                         lock (m_thread_flag)
-                            m_thread_flag = "无";
+                            m_thread_flag = strNill;
                     }
                 }
             }
             else
             {
                 progressBar1.Value = e.ProgressPercentage;
-                WriteRictBox("正在导入到报告模板中,已经完成:" + e.ProgressPercentage.ToString() + "%");
+                WriteRictBox(table["rictbox39"].ToString() + e.ProgressPercentage.ToString() + "%");
             }
         }
 
         private void backgroundWorker2_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
         {
-            WriteRictBox("导出了:" + m_export_reporttemplate.m_list_dt.Count.ToString() + "表", Color.Red);
+            WriteRictBox(table["rictbox41"].ToString() + m_export_reporttemplate.m_list_dt.Count.ToString() + table["rictbox42"].ToString(), Color.Red);
 
             //处理结束后,再将button的状态更新回去
             progressBar1.Value = 100;
-            WriteRictBox("-----------------导出完成!--------------------", Color.Red);
+            WriteRictBox("-----------------"+ table["rictbox43"].ToString() + "--------------------", Color.Red);
             MemoryManagementClass.FlushMemory();
 
 
@@ -1987,7 +1871,7 @@ namespace OTSIncAReportApp
             string path = string.Empty;
 
             OpenFileDialog Load = new OpenFileDialog();
-            Load.Filter = "PXML文件|*.xml";
+            Load.Filter = "XML File|*.xml";
             Load.InitialDirectory = @System.Windows.Forms.Application.StartupPath + "\\Config\\ProData";
             if (Load.ShowDialog() == DialogResult.OK)
                 path = Load.FileName;//赋值目录
@@ -2120,7 +2004,7 @@ namespace OTSIncAReportApp
             {
                 if (proc.ProcessName == "OTSIncAReportTemplate")
                 {
-                    DialogResult dr = MessageBox.Show("报告模板已打开,请先关闭!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Warning);
+                    DialogResult dr = MessageBox.Show(table["rictbox44"].ToString(), table["rictbox45"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Warning);
                     if (dr == DialogResult.OK)
                     {
                         return;

+ 18 - 14
OTSIncAReportApp/1-UI/OTSTemplateDesigner/OTSReport_TemplateDesignerRM.cs

@@ -11,7 +11,7 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
     {
         #region 全局变量
         public OTSReport_Export m_OTSReport_Export;
-
+        System.Collections.Hashtable table;
         #endregion
 
         #region 构造函数及窗体加载
@@ -24,6 +24,10 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
         {
             InitializeComponent();
             m_OTSReport_Export = in_otsreport_export;
+            #region 国际化语言
+            Language lan = new Language(this);
+            table = lan.GetNameTable(this.Name);
+            #endregion
         }
 
         private void OTSReport_TemplateDesignerRM_Load(object sender, EventArgs e)
@@ -56,11 +60,11 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
 
             #region 夹杂物分类图
             //显示图形
-            cb_jzwfl_xstx.Items.Add("饼图");
-            cb_jzwfl_xstx.Items.Add("圈图");
-            cb_jzwfl_xstx.Items.Add("柱形图");
-            cb_jzwfl_xstx.Items.Add("线状图");
-            cb_jzwfl_xstx.Items.Add("堆叠图");
+            cb_jzwfl_xstx.Items.Add(table["report1"].ToString());
+            cb_jzwfl_xstx.Items.Add(table["report2"].ToString());
+            cb_jzwfl_xstx.Items.Add(table["report3"].ToString());
+            cb_jzwfl_xstx.Items.Add(table["report4"].ToString());
+            cb_jzwfl_xstx.Items.Add(table["report5"].ToString());
             cb_jzwfl_xstx.SelectedIndex = 0;
             //计算方式
             //BindComboBox(DisplayPicutureType.AnalyzeDataChart, cb_jzwfl_jsfs, OTS_RETORT_PROP_GRID_ITEMS.CALCULATE_CHART_TYPE, (int)CALCULATE_CHART_TYPE.TRIO_CHART, OTS_RETORT_PROP_GRID_ITEMS.SIZE_CAL_METHOD_TYPE);
@@ -84,11 +88,11 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
 
             #region 元素成份图
             //显示图形
-            cb_yscf_xstx.Items.Add("饼图");
-            cb_yscf_xstx.Items.Add("圈图");
-            cb_yscf_xstx.Items.Add("柱形图");
-            cb_yscf_xstx.Items.Add("线状图");
-            cb_yscf_xstx.Items.Add("堆叠图");
+            cb_yscf_xstx.Items.Add(table["report1"].ToString());
+            cb_yscf_xstx.Items.Add(table["report2"].ToString());
+            cb_yscf_xstx.Items.Add(table["report3"].ToString());
+            cb_yscf_xstx.Items.Add(table["report4"].ToString());
+            cb_yscf_xstx.Items.Add(table["report5"].ToString());
             cb_yscf_xstx.SelectedIndex = 0;
             //计算方式
             //BindComboBox(DisplayPicutureType.AnalyzeDataChart, cb_yscf_jsfs, OTS_RETORT_PROP_GRID_ITEMS.CALCULATE_CHART_TYPE, (int)CALCULATE_CHART_TYPE.TRIO_CHART, OTS_RETORT_PROP_GRID_ITEMS.SIZE_CAL_METHOD_TYPE);
@@ -152,7 +156,7 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
                 if (selectnumber % 2 != 0)
                 {
                     //选择的不是2的整倍数,请重新选择
-                    MessageBox.Show("三元相图模板选择项需2整倍数,请重新选择!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show(table["report10"].ToString(), table["report12"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
                     return false;
                 }
             }
@@ -162,7 +166,7 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
                 if (selectnumber % 3 != 0)
                 {
                     //选择的不是2的整倍数,请重新选择
-                    MessageBox.Show("三元相图模板选择项需3整倍数,请重新选择!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show(table["report11"].ToString(), table["report12"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
                     return false;
                 }
             }
@@ -214,7 +218,7 @@ namespace OTSIncAReportApp.OTSTemplateDesigner
         {
             string path = string.Empty;
             SaveFileDialog save = new SaveFileDialog();
-            save.Filter = "XML文件|*.xml";
+            save.Filter = "XML File|*.xml";
             save.InitialDirectory = @System.Windows.Forms.Application.StartupPath + "\\Config\\ProData";
             if (save.ShowDialog() != DialogResult.OK)
             {

+ 1 - 1
OTSIncAReportApp/1-UI/frmMeasureRstMgr.cs

@@ -319,7 +319,7 @@ namespace OTSIncAReportApp
             string path = System.IO.Path.GetDirectoryName(str_path);
             if (m_DataMgr.resultFilesList.Find(s => s.FileName == name) != null)
             {
-                MessageBox.Show("已经加载同名文件,请重新选择!");
+                MessageBox.Show("The file with the same name has been loaded, please select again!");
                 return;
             }
 

+ 2 - 2
OTSIncAReportApp/1-UI/frmReportApp.cs

@@ -390,7 +390,7 @@ namespace OTSIncAReportApp
         {
             string path = "";
             OpenFileDialog fileDialog = new OpenFileDialog();
-            fileDialog.Filter = "文本文件|*.rst";
+            fileDialog.Filter = "text File|*.rst";
             fileDialog.RestoreDirectory = true; 
             if (fileDialog.ShowDialog() == DialogResult.OK)
                 path = System.IO.Path.GetFullPath(fileDialog.FileName);
@@ -932,7 +932,7 @@ namespace OTSIncAReportApp
         public int ShowSaveInfoMsgBox()
         {
             //是否保存修改信息,保存样品信息提示
-            int iRev = (int)MessageBox.Show("是否保存修改信息", "信息提示", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Warning);
+            int iRev = (int)MessageBox.Show("Save modification information", "Tips", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Warning);
             if (iRev == (int)DialogResult.Yes)
             {
                 return (int)MessageBoxRev.DIALOG_YES;