Browse Source

自定义标准库提示变英语

cxs 2 years ago
parent
commit
90e2490108

+ 1 - 1
Bin/x64/Debug/Resources/XMLData/LanguageDefine.xml

@@ -1,4 +1,4 @@
 <?xml version="1.0" standalone="yes"?>
 <Language>
-  <DefaultLanguage>ZH</DefaultLanguage>
+  <DefaultLanguage>EN</DefaultLanguage>
 </Language>

+ 31 - 31
OTSPartA_STDEditor/Form_ConstantsEditor2.cs

@@ -182,7 +182,7 @@ namespace OTSPartA_STDEditor
             }
             catch /*(Exception ee)*/
             {
-                MessageBox.Show(table["message6"].ToString(), table["message32"].ToString());
+                MessageBox.Show("The selected standard library is formatted incorrectly, please open the correct standard library!", "Tip");
                 return false;
             }
         }
@@ -209,8 +209,8 @@ namespace OTSPartA_STDEditor
                             try
                             {
                                 SaveFileDialog saveFile = new SaveFileDialog();
-                                saveFile.Title = table["message23"].ToString();
-                                saveFile.Filter = table["message36"].ToString();
+                                saveFile.Title = "Please select the path which to save the file";
+                                saveFile.Filter = "Database File(*.db)|*.db";
                                 saveFile.OverwritePrompt = true;  //是否覆盖当前文件
                                 saveFile.RestoreDirectory = true;  //还原上次目录
                                 if (saveFile.ShowDialog() == DialogResult.OK)
@@ -219,7 +219,7 @@ namespace OTSPartA_STDEditor
                                     bool result = SaveDictionaryToClassify(saveFile.FileName);
                                     if (result)
                                     {
-                                        MessageBox.Show(table["message25"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                                        MessageBox.Show("Export file successful!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                                     }
                                 }
                                 else
@@ -236,7 +236,7 @@ namespace OTSPartA_STDEditor
                 }
                 else
                 {
-                    MessageBox.Show(table["message3"].ToString(), table["message32"].ToString());
+                    MessageBox.Show("The name of rulecannot be empty!", "Tip");
                 }
             }
             else
@@ -244,8 +244,8 @@ namespace OTSPartA_STDEditor
                 try
                 {
                     SaveFileDialog saveFile = new SaveFileDialog();
-                    saveFile.Title = table["message23"].ToString();
-                    saveFile.Filter = table["message36"].ToString();
+                    saveFile.Title = "Please select the path which to save the file";
+                    saveFile.Filter = "Database File(*.db)|*.db";
                     saveFile.OverwritePrompt = true;  //是否覆盖当前文件
                     saveFile.RestoreDirectory = true;  //还原上次目录
                     if (saveFile.ShowDialog() == DialogResult.OK)
@@ -254,7 +254,7 @@ namespace OTSPartA_STDEditor
                         bool result = SaveDictionaryToClassify(saveFile.FileName);
                         if (result)
                         {
-                            MessageBox.Show(table["message25"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                            MessageBox.Show("Export file successful!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                         }
                     }
                     else
@@ -330,12 +330,12 @@ namespace OTSPartA_STDEditor
                                     STDDictionaryInitial = Clone(STDDictionary) as Dictionary<int, STDdata>;
                                     forWaiting.Close();
                                     IsModified = false;
-                                    MessageBox.Show(table["message1"].ToString(), table["message32"].ToString());
+                                    MessageBox.Show("Save successful!", "Tip");
                                 }
                                 else
                                 {
                                     forWaiting.Close();
-                                    MessageBox.Show(table["message2"].ToString(), table["message32"].ToString());
+                                    MessageBox.Show("Save failed!", "Tip");
                                 }
                             }
                         }
@@ -363,12 +363,12 @@ namespace OTSPartA_STDEditor
                                     STDDictionaryInitial = new Dictionary<int, STDdata>(STDDictionary);
                                     forWaiting.Close();
                                     IsModified = false;
-                                    MessageBox.Show(table["message1"].ToString(), table["message32"].ToString());
+                                    MessageBox.Show("Save successful!", "Tip");
                                 }
                                 else
                                 {
                                     forWaiting.Close();
-                                    MessageBox.Show(table["message2"].ToString(), table["message32"].ToString());
+                                    MessageBox.Show("Save failed!", "Tip");
                                 }
                             }
                         }
@@ -406,19 +406,19 @@ namespace OTSPartA_STDEditor
                         {
                             if (str_RemoveBlank.Contains(Symbol[i] + Symbol[j]))
                             {
-                                MessageBox.Show(table["message18"].ToString() + Symbol[i] + Symbol[j], table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                                MessageBox.Show("Invalid string exists:" + Symbol[i] + Symbol[j], "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                                 return false;
                             }
                         }
                     }
                     if (str_RemoveBlank.Contains(Symbol[i] + ")") || str_RemoveBlank.Contains("(" + Symbol[i]))
                     {
-                        MessageBox.Show(table["message18"].ToString() + Symbol[i] + ")", table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                        MessageBox.Show("Invalid string exists:" + Symbol[i] + ")", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                         return false;
                     }
                     if (str_RemoveBlank.Contains("(" + Symbol[i]))
                     {
-                        MessageBox.Show(table["message18"].ToString() + "(" + Symbol[i], table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                        MessageBox.Show("Invalid string exists:" + "(" + Symbol[i], "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                         return false;
                     }
                 }
@@ -433,13 +433,13 @@ namespace OTSPartA_STDEditor
                     }
                     if (BracketsNum != 0)
                     {
-                        MessageBox.Show(table["message19"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                        MessageBox.Show("Number of left and right parentheses does not match!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                         return false;
                     }
                     //首字符检测
                     if ((str_RemoveBlank[0] == '+') || (str_RemoveBlank[0] == '-') || (str_RemoveBlank[0] == '*') || (str_RemoveBlank[0] == '/') || (str_RemoveBlank[0] == '>') || (str_RemoveBlank[0] == '<') || (str_RemoveBlank[0] == '=') || (str_RemoveBlank[0] == ')') || (str_RemoveBlank[str_RemoveBlank.Length - 1] == '('))
                     {
-                        MessageBox.Show(table["message20"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                        MessageBox.Show("First character is error!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                         return false;
                     }
 
@@ -447,7 +447,7 @@ namespace OTSPartA_STDEditor
                     {
                         if ((str_RemoveBlank.Substring(0, 3) == "and") || (str_RemoveBlank.Substring(0, 3) == "end"))
                         {
-                            MessageBox.Show(table["message20"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                            MessageBox.Show("First character is error!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                             return false;
                         }
                     }
@@ -519,13 +519,13 @@ namespace OTSPartA_STDEditor
                         continue;
                     }
 
-                    MessageBox.Show(table["message21"].ToString() + list_all[i], table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show("Please check whether the input rules are correct, error characters:" + list_all[i], "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                     return false;
                 }
                 //检测是否有<>= true,false
                 if (!m_SubMidWindow.m_STDEditor.textbox_STDEditor.Text.ToString().Contains("<") && !m_SubMidWindow.m_STDEditor.textbox_STDEditor.Text.ToString().Contains(">") && !m_SubMidWindow.m_STDEditor.textbox_STDEditor.Text.ToString().Contains("=") && m_SubMidWindow.m_STDEditor.textbox_STDEditor.Text.ToString() != "true" && m_SubMidWindow.m_STDEditor.textbox_STDEditor.Text.ToString() != "false")
                 {
-                    MessageBox.Show(table["message22"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show("Expressions have no effect!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                     return false;
                 }
             }
@@ -534,7 +534,7 @@ namespace OTSPartA_STDEditor
                 var XrayInfo = m_SubMidWindow.m_STDEditor.m_STDXrayList.Find(STDXray => STDXray.StdID == m_STDRuleslist.Grid_Minerals[m_STDRuleslist.PreRow, 0].Tag.ToString());
                 if (XrayInfo==null||XrayInfo.XrayData==null)
                 {
-                    MessageBox.Show(table["message38"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show("Expressions and spectra cannot all be empty!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                     return false;
                 }
             }
@@ -578,7 +578,7 @@ namespace OTSPartA_STDEditor
                 {
                     Position pos = new Position(10, 1);
                     m_Attributes.Grid_Attributes.Selection.Focus(pos, true);
-                    MessageBox.Show(table["message4"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show("This group name is not included, please fill in again!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                     return false;
                 }
             }
@@ -1246,7 +1246,7 @@ namespace OTSPartA_STDEditor
         {            
             if (!EqualsBetweenDictionary(STDDictionaryInitial, STDDictionary) || IsModified)
             {
-                DialogResult dr = MessageBox.Show("是否保存当前修改", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
+                DialogResult dr = MessageBox.Show("Whether to save the current modification?", "Tip", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
                 if (dr == DialogResult.Yes)
                 {
                     if (m_STDRuleslist.Grid_Minerals.RowsCount > 1)
@@ -1276,7 +1276,7 @@ namespace OTSPartA_STDEditor
                     else
                     {
                         forWaiting.Close();
-                        MessageBox.Show(table["message2"].ToString(), table["message32"].ToString());
+                        MessageBox.Show("Save failed!", "Tip");
                     }
                 }
             }
@@ -1309,7 +1309,7 @@ namespace OTSPartA_STDEditor
                 }
                 catch
                 {
-                    MessageBox.Show(table["message6"].ToString(), table["message32"].ToString());
+                    MessageBox.Show("The selected standard library is formatted incorrectly, please open the correct standard library!", "Tip");
                 }
             }
         }
@@ -1394,7 +1394,7 @@ namespace OTSPartA_STDEditor
             openFileDialog.Filter = "(*.db)|*.db";
             openFileDialog.RestoreDirectory = true;
             openFileDialog.FilterIndex = 1;
-            openFileDialog.Title = table["message33"].ToString();
+            openFileDialog.Title = "Please open a database!";
             if (openFileDialog.ShowDialog() == DialogResult.OK)
             {
                 try
@@ -1404,7 +1404,7 @@ namespace OTSPartA_STDEditor
 
                     if(STDDictionary.Count==0)
                     {
-                        MessageBox.Show(table["message27"].ToString(), table["message32"].ToString());
+                        MessageBox.Show(table["message27"].ToString(), "Tip");
                         return;
                     }
 
@@ -1425,7 +1425,7 @@ namespace OTSPartA_STDEditor
                     }
                     if (!ret)
                     {
-                        MessageBox.Show(table["message34"].ToString(), table["message32"].ToString());
+                        MessageBox.Show("No matching energy spectrum data was found", "Tip");
                     }
 
                     int color = Convert.ToInt32(m_SubMidWindow.m_STDEditor.ParseRGB(STDRuleslist.colorHx16toRGB(STDDictionary[int.Parse(STDId)].Color)).ToString());
@@ -1477,7 +1477,7 @@ namespace OTSPartA_STDEditor
             {
                 if (!EqualsBetweenDictionary(STDDictionaryInitial, STDDictionary)|| IsModified)
                 {
-                    DialogResult dr = MessageBox.Show("是否保存当前修改", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
+                    DialogResult dr = MessageBox.Show("Whether to save the current modification", "Tip", MessageBoxButtons.YesNo, MessageBoxIcon.Question);
                     if (dr == DialogResult.Yes)
                     {
                         if (m_STDRuleslist.Grid_Minerals.RowsCount > 1)
@@ -1508,7 +1508,7 @@ namespace OTSPartA_STDEditor
                         else
                         {
                             forWaiting.Close();
-                            MessageBox.Show(table["message2"].ToString(), table["message32"].ToString());
+                            MessageBox.Show("Save failed!", "Tip");
                         }
                     }
                     else
@@ -1531,7 +1531,7 @@ namespace OTSPartA_STDEditor
         {
             DataTable OreDatabasedt = new DataTable();
             OpenFileDialog openFileDialog = new OpenFileDialog();
-            openFileDialog.Title= table["message37"].ToString();
+            openFileDialog.Title= "Please select the database you want to convert";
             openFileDialog.Filter = "(*.db)|*.db";
             openFileDialog.RestoreDirectory = true;
             openFileDialog.FilterIndex = 1;

+ 6 - 6
OTSPartA_STDEditor/Form_GroupId.cs

@@ -208,14 +208,14 @@ namespace OTSPartA_STDEditor
                     {
                         if (!AddIntoDB(m_dbConnection, kv.Key, kv.Value.name, kv.Value.color, kv.Value.iorder))
                         {
-                            MessageBox.Show(table_GroupId["message1"].ToString(), table_GroupId["message32"].ToString());
+                            MessageBox.Show("Failed to add into database!", "Tip");
                         }
                     }
                     else
                     {
                         if (!UpdataInDB(m_dbConnection, kv.Key, kv.Value.name, kv.Value.color, kv.Value.iorder))
                         {
-                            MessageBox.Show(table_GroupId["message2"].ToString(), table_GroupId["message32"].ToString());
+                            MessageBox.Show("Failed to update to database!", "Tip");
                         }
                     }
                 }
@@ -223,7 +223,7 @@ namespace OTSPartA_STDEditor
                 {
                     if (!DeleteInDB(m_dbConnection, kv.Key, kv.Value.name, kv.Value.color, kv.Value.iorder))
                     {
-                        MessageBox.Show(table_GroupId["message3"].ToString(), table_GroupId["message32"].ToString());
+                        MessageBox.Show("Failed to delete data in database!", "Tip");
                     }
                 }
             }
@@ -312,7 +312,7 @@ namespace OTSPartA_STDEditor
             }
             else
             {
-                MessageBox.Show(table_GroupId["message4"].ToString(), table_GroupId["message32"].ToString());
+                MessageBox.Show("Failed to read database", "Tip");
             }
         }
         public int AddMineralGroupDictionaryItem()
@@ -384,7 +384,7 @@ namespace OTSPartA_STDEditor
                         Position pos = new Position(i, 0);
                         Grid_FroupId.Selection.Focus(pos, true);
                         string DuplicateNames = Grid_FroupId[i, 0].ToString();
-                        MessageBox.Show(table_GroupId["message5"].ToString() + DuplicateNames + table_GroupId["message6"].ToString(), table_GroupId["message32"].ToString());
+                        MessageBox.Show("The names of groups are reusable which named " + DuplicateNames + ",please modify!", "Tip");
                         return;
                     }
                 }
@@ -432,7 +432,7 @@ namespace OTSPartA_STDEditor
             }
             else
             {
-                MessageBox.Show(table_GroupId["message7"].ToString(), table_GroupId["message32"].ToString());
+                MessageBox.Show("No gruop is selected!", "Tip");
 
             }
         }

+ 17 - 17
OTSPartA_STDEditor/Form_MaxEDSRules.cs

@@ -403,12 +403,12 @@ namespace OTSPartA_STDEditor
                 }
                 else
                 {
-                    MessageBox.Show(table["message1"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show("No nodes are selected!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                 }
             }
             catch (Exception ex)
             {
-                MessageBox.Show(ex.ToString(), table["message32"].ToString());
+                MessageBox.Show(ex.ToString(), "Tip");
             }
         }
 
@@ -423,7 +423,7 @@ namespace OTSPartA_STDEditor
                     double dMaxEDSTime = 0;
                     if (!double.TryParse(textBox_MaxEDSTime.Text, out dMaxEDSTime) || double.Parse(textBox_MaxEDSTime.Text) <= 0)
                     {
-                        MessageBox.Show(table["message8"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                        MessageBox.Show("The MaxEDSTime of current selected node input error, please enter the correct format!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                         return;
                     }
                     //判断textbox_STDEditor
@@ -457,7 +457,7 @@ namespace OTSPartA_STDEditor
             }
             catch (Exception ex)
             {
-                MessageBox.Show(ex.ToString(), table["message32"].ToString());
+                MessageBox.Show(ex.ToString(), "Tip");
             }
         }
 
@@ -591,7 +591,7 @@ namespace OTSPartA_STDEditor
             m_dataAdapter.Update(ds, "MaxEDSRules");
             m_dbConnection.Close();
 
-            MessageBox.Show(table["message2"].ToString(), table["message32"].ToString());
+            MessageBox.Show("Save successful!", "Tip");
         }
 
         //元素周期表开关
@@ -670,7 +670,7 @@ namespace OTSPartA_STDEditor
                 {
                     textBox_MaxEDSTime.Focus();
                     textBox_MaxEDSTime.SelectAll();
-                    MessageBox.Show(table["message16"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show("The Item of MaxEDSTime input error, please enter the correct format!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                     return;
                 }
                 //判断textbox_STDEditor
@@ -725,7 +725,7 @@ namespace OTSPartA_STDEditor
             if (textbox_STDEditor.Text == "" || textbox_STDEditor.Text == null)
             {
                 textBox_MaxEDSTime.Focus();
-                MessageBox.Show(table["message17"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                MessageBox.Show("The content of Standard library cannot be empty!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                 return false;
             }
             string str_RemoveBlank = textbox_STDEditor.Text.ToString().Replace(" ", "");
@@ -740,19 +740,19 @@ namespace OTSPartA_STDEditor
                     {
                         if (str_RemoveBlank.Contains(Symbol[i] + Symbol[j]))
                         {
-                            MessageBox.Show(table["message18"].ToString() + Symbol[i] + Symbol[j], table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                            MessageBox.Show("Invalid string exists:" + Symbol[i] + Symbol[j], "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                             return false;
                         }
                     }
                 }
                 if (str_RemoveBlank.Contains(Symbol[i] + ")") || str_RemoveBlank.Contains("(" + Symbol[i]))
                 {
-                    MessageBox.Show(table["message18"].ToString() + Symbol[i] + ")", table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show("Invalid string exists:" + Symbol[i] + ")", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                     return false;
                 }
                 if (str_RemoveBlank.Contains("(" + Symbol[i]))
                 {
-                    MessageBox.Show(table["message18"].ToString() + "(" + Symbol[i], table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show("Invalid string exists:" + "(" + Symbol[i], "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                     return false;
                 }
             }
@@ -767,13 +767,13 @@ namespace OTSPartA_STDEditor
                 }
                 if (BracketsNum != 0)
                 {
-                    MessageBox.Show(table["message19"].ToString(),table["message32"].ToString(),MessageBoxButtons.OK,MessageBoxIcon.Information);
+                    MessageBox.Show("Number of left and right parentheses does not match!", "Tip", MessageBoxButtons.OK,MessageBoxIcon.Information);
                     return false;
                 }
                 //首字符检测
                 if ((str_RemoveBlank[0] == '+') || (str_RemoveBlank[0] == '-') || (str_RemoveBlank[0] == '*') || (str_RemoveBlank[0] == '/') || (str_RemoveBlank[0] == '>') || (str_RemoveBlank[0] == '<') || (str_RemoveBlank[0] == '=') || (str_RemoveBlank[0] == ')') || (str_RemoveBlank[str_RemoveBlank.Length - 1] == '('))
                 {
-                    MessageBox.Show(table["message20"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show("First character is error!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                     return false;
                 }
 
@@ -781,7 +781,7 @@ namespace OTSPartA_STDEditor
                 {
                     if ((str_RemoveBlank.Substring(0, 3) == "and") || (str_RemoveBlank.Substring(0, 3) == "end"))
                     {
-                        MessageBox.Show(table["message20"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                        MessageBox.Show("First character is error!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                         return false;
                     }
                 }
@@ -853,14 +853,14 @@ namespace OTSPartA_STDEditor
                     continue;
                 }
 
-                MessageBox.Show(table["message21"].ToString() + list_all[i], table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                MessageBox.Show("Please check whether the input rules are correct, error characters:" + list_all[i], "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                 return false;
             }
 
             //检测是否有<>= true,false
             if (!textbox_STDEditor.Text.ToString().Contains("<") && !textbox_STDEditor.Text.ToString().Contains(">") && !textbox_STDEditor.Text.ToString().Contains("=")&& textbox_STDEditor.Text.ToString()!="true"&& textbox_STDEditor.Text.ToString() != "false")
             {
-                MessageBox.Show(table["message22"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                MessageBox.Show("Expressions have no effect!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                 return false;
             }
 
@@ -942,7 +942,7 @@ namespace OTSPartA_STDEditor
             }
             catch(Exception ex)
             {
-                MessageBox.Show(table["message26"].ToString() + "\n"+ex.Message.ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                MessageBox.Show("Recovery failed!" + "\n"+ex.Message.ToString(), "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
             }
         }
 
@@ -955,7 +955,7 @@ namespace OTSPartA_STDEditor
                 {
                     XmlTree_MaxEDSRules.SelectedNode = XmlTree_MaxEDSRules.Nodes[num];
                     SetGrayExceptSelectedNode(XmlTree_MaxEDSRules, XmlTree_MaxEDSRules.SelectedNode);
-                    DialogResult result = MessageBox.Show(table["message27"].ToString() + XmlTree_MaxEDSRules.Nodes[num].Text + table["message28"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Warning);
+                    DialogResult result = MessageBox.Show("Closing failed," + XmlTree_MaxEDSRules.Nodes[num].Text + table["message28"].ToString(), "Tip", MessageBoxButtons.OK, MessageBoxIcon.Warning);
                     return false;
                 }
             }

+ 3 - 3
OTSPartA_STDEditor/Form_UserConstants.cs

@@ -170,7 +170,7 @@ namespace OTSPartA_STDEditor
                     }
                     else
                     {
-                        MessageBox.Show(table["message29"].ToString() + checkBox.Name + table["message30"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Warning);
+                        MessageBox.Show("Symbol" + checkBox.Name + "Input error for corresponding value!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Warning);
                         return;
                     }
                 }
@@ -206,7 +206,7 @@ namespace OTSPartA_STDEditor
             }
             
 
-            MessageBox.Show(table["message31"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+            MessageBox.Show("The library of constants updated successfully!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
 
             this.DialogResult = DialogResult.Yes;
         }
@@ -255,7 +255,7 @@ namespace OTSPartA_STDEditor
             }
             else
             {
-                MessageBox.Show(table["message1"].ToString(), table["message32"].ToString());
+                MessageBox.Show("Failed to close. Applied to other rules!", "Tip");
                 return false;
             }
         }

+ 21 - 21
OTSPartA_STDEditor/Form_ZeroElementRules.cs

@@ -373,12 +373,12 @@ namespace OTSPartA_STDEditor
                 }
                 else
                 {
-                    MessageBox.Show(table["message1"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show("No nodes are selected!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                 }
             }
             catch (Exception ex)
             {
-                MessageBox.Show(ex.ToString(), table["message32"].ToString());
+                MessageBox.Show(ex.ToString(), "Tip");
             }
         }
 
@@ -393,13 +393,13 @@ namespace OTSPartA_STDEditor
                     {
                         if (!comboBox_PeriodicTable.Items.Contains(XmlTree_ZeroElementRules.SelectedNode.Text.Split('=')[0]))
                         {
-                            MessageBox.Show(XmlTree_ZeroElementRules.SelectedNode.Text + table["message9"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                            MessageBox.Show(XmlTree_ZeroElementRules.SelectedNode.Text + "Item,It`s format of name is error, The correct format is : element name =0", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                             return;
                         }
                     }
                     else
                     {
-                        MessageBox.Show(XmlTree_ZeroElementRules.SelectedNode.Text + table["message9"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                        MessageBox.Show(XmlTree_ZeroElementRules.SelectedNode.Text + "Item,It`s format of name is error, The correct format is : element name =0", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                         return;
                     }
                     //判断textbox_STDEditor
@@ -426,7 +426,7 @@ namespace OTSPartA_STDEditor
             }
             catch (Exception ex)
             {
-                MessageBox.Show(ex.ToString(), table["message32"].ToString());
+                MessageBox.Show(ex.ToString(), "Tip");
             }
         }
 
@@ -560,7 +560,7 @@ namespace OTSPartA_STDEditor
             m_dataAdapter.Update(ds, "ZeroElementRules");
             m_dbConnection.Close();
 
-            MessageBox.Show(table["message2"].ToString(), table["message32"].ToString());
+            MessageBox.Show("Save successful!", "Tip");
         }
 
         //元素周期表开关
@@ -657,13 +657,13 @@ namespace OTSPartA_STDEditor
                 {
                     if (!comboBox_PeriodicTable.Items.Contains(XmlTree_ZeroElementRules.SelectedNode.Text.Split('=')[0]))
                     {
-                        MessageBox.Show(XmlTree_ZeroElementRules.SelectedNode.Text + table["message9"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                        MessageBox.Show(XmlTree_ZeroElementRules.SelectedNode.Text + "Item,It`s format of name is error, The correct format is : element name =0", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                         return;
                     }
                 }
                 else
                 {
-                    MessageBox.Show(XmlTree_ZeroElementRules.SelectedNode.Text + table["message9"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show(XmlTree_ZeroElementRules.SelectedNode.Text + "Item,It`s format of name is error, The correct format is : element name =0", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                     return;
                 }
                 //判断textbox_STDEditor
@@ -718,7 +718,7 @@ namespace OTSPartA_STDEditor
             if (textbox_STDEditor.Text == "" || textbox_STDEditor.Text == null)
             {
                 textbox_STDEditor.Focus();
-                MessageBox.Show(table["message17"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                MessageBox.Show("The content of Standard library cannot be empty!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                 return false;
             }
             string str_RemoveBlank = textbox_STDEditor.Text.ToString().Replace(" ", "");
@@ -733,19 +733,19 @@ namespace OTSPartA_STDEditor
                     {
                         if (str_RemoveBlank.Contains(Symbol[i] + Symbol[j]))
                         {
-                            MessageBox.Show(table["message18"].ToString() + Symbol[i] + Symbol[j], table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                            MessageBox.Show("Invalid string exists:" + Symbol[i] + Symbol[j], "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                             return false;
                         }
                     }
                 }
                 if (str_RemoveBlank.Contains(Symbol[i] + ")") || str_RemoveBlank.Contains("(" + Symbol[i]))
                 {
-                    MessageBox.Show(table["message18"].ToString() + Symbol[i] + ")", table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show("Invalid string exists:" + Symbol[i] + ")", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                     return false;
                 }
                 if (str_RemoveBlank.Contains("(" + Symbol[i]))
                 {
-                    MessageBox.Show(table["message18"].ToString() + "(" + Symbol[i], table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show("Invalid string exists:" + "(" + Symbol[i], "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                     return false;
                 }
             }
@@ -760,13 +760,13 @@ namespace OTSPartA_STDEditor
                 }
                 if (BracketsNum != 0)
                 {
-                    MessageBox.Show(table["message19"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show("Number of left and right parentheses does not match!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                     return false;
                 }
                 //首字符检测
                 if ((str_RemoveBlank[0] == '+') || (str_RemoveBlank[0] == '-') || (str_RemoveBlank[0] == '*') || (str_RemoveBlank[0] == '/') || (str_RemoveBlank[0] == '>') || (str_RemoveBlank[0] == '<') || (str_RemoveBlank[0] == '=') || (str_RemoveBlank[0] == ')') || (str_RemoveBlank[str_RemoveBlank.Length - 1] == '('))
                 {
-                    MessageBox.Show(table["message20"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show("First character is error!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                     return false;
                 }
 
@@ -774,7 +774,7 @@ namespace OTSPartA_STDEditor
                 {
                     if ((str_RemoveBlank.Substring(0, 3) == "and") || (str_RemoveBlank.Substring(0, 3) == "end"))
                     {
-                        MessageBox.Show(table["message20"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                        MessageBox.Show("First character is error!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                         return false;
                     }
                 }
@@ -846,14 +846,14 @@ namespace OTSPartA_STDEditor
                     continue;
                 }
 
-                MessageBox.Show(table["message21"].ToString() + list_all[i], table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                MessageBox.Show("Please check whether the input rules are correct, error characters:" + list_all[i], "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                 return false;
             }
 
             //检测是否有<>= true,false
             if (!textbox_STDEditor.Text.ToString().Contains("<") && !textbox_STDEditor.Text.ToString().Contains(">") && !textbox_STDEditor.Text.ToString().Contains("=") && textbox_STDEditor.Text.ToString() != "true" && textbox_STDEditor.Text.ToString() != "false")
             {
-                MessageBox.Show(table["message22"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                MessageBox.Show("Expressions have no effect!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                 return false;
             }
 
@@ -932,7 +932,7 @@ namespace OTSPartA_STDEditor
             }
             catch (Exception ex)
             {
-                MessageBox.Show(table["message26"].ToString() + "\n" + ex.Message.ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                MessageBox.Show("Recovery failed!" + "\n" + ex.Message.ToString(), "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
             }
         }
 
@@ -961,7 +961,7 @@ namespace OTSPartA_STDEditor
                 {
                     XmlTree_ZeroElementRules.SelectedNode = XmlTree_ZeroElementRules.Nodes[num];
                     SetGrayExceptSelectedNode(XmlTree_ZeroElementRules, XmlTree_ZeroElementRules.SelectedNode);
-                    DialogResult result = MessageBox.Show(table["message27"].ToString() + XmlTree_ZeroElementRules.Nodes[num].Text + table["message28"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Warning);
+                    DialogResult result = MessageBox.Show("Closing failed," + XmlTree_ZeroElementRules.Nodes[num].Text + "Item ,it`s rule input contains this constant!", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Warning);
                     return false;
                 }
             }
@@ -976,7 +976,7 @@ namespace OTSPartA_STDEditor
                 {
                     if (!comboBox_PeriodicTable.Items.Contains(XmlTree_ZeroElementRules.SelectedNode.Text.Split('=')[0]))
                     {
-                        MessageBox.Show(XmlTree_ZeroElementRules.SelectedNode.Text + table["message9"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                        MessageBox.Show(XmlTree_ZeroElementRules.SelectedNode.Text + "Item,It`s format of name is error, The correct format is : element name =0", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                         SetGrayExceptSelectedNode(XmlTree_ZeroElementRules, XmlTree_ZeroElementRules.SelectedNode);
                         e.Cancel = true;
                         return;
@@ -984,7 +984,7 @@ namespace OTSPartA_STDEditor
                 }
                 else
                 {
-                    MessageBox.Show(XmlTree_ZeroElementRules.SelectedNode.Text + table["message9"].ToString(), table["message32"].ToString(), MessageBoxButtons.OK, MessageBoxIcon.Information);
+                    MessageBox.Show(XmlTree_ZeroElementRules.SelectedNode.Text + "Item,It`s format of name is error, The correct format is : element name =0", "Tip", MessageBoxButtons.OK, MessageBoxIcon.Information);
                     SetGrayExceptSelectedNode(XmlTree_ZeroElementRules, XmlTree_ZeroElementRules.SelectedNode);
                     e.Cancel = true;
                     return;

+ 1 - 1
OTSPartA_STDEditor/ReferenceLibrary.cs

@@ -163,7 +163,7 @@ namespace OTSPartA_STDEditor
             }
             catch /*(Exception ee)*/
             {
-                MessageBox.Show(table_ReferenceLibrary["message1"].ToString(), table_ReferenceLibrary["message32"].ToString());
+                MessageBox.Show("Reference library format error, please open the correct reference library!", "Tip");
 
                 return false;
             }

+ 9 - 9
OTSPartA_STDEditor/STDEditor.cs

@@ -490,19 +490,19 @@ namespace OTSPartA_STDEditor
             string strTime = txtCollectTime.Text.Trim();
             if (txtCollectTime.Equals(""))
             {
-                showMessage(table_STDEditor["message33"].ToString());
+                showMessage("Please fill in the collection time name!");
                 txtCollectTime.Focus();
                 return;
             }
             if (!IsMatch(strTime, 1))
             {
-                showMessage(table_STDEditor["message34"].ToString());
+                showMessage("Error collecting time content, the format should be integer!");
                 txtCollectTime.Focus();
                 return;
             }
             if (Convert.ToInt32(strTime) < 50)
             {
-                showMessage(table_STDEditor["message35"].ToString());
+                showMessage("CollectTime must not be less than 100 milliseconds!");
                 txtCollectTime.Focus();
                 return;
             }
@@ -687,7 +687,7 @@ namespace OTSPartA_STDEditor
         /// <param name="strContent"></param>
         protected void showMessage(string strContent)
         {
-            MessageBox.Show(strContent, table_STDEditor["message32"].ToString());
+            MessageBox.Show(strContent, "Tip");
         }
         #endregion
 
@@ -1333,7 +1333,7 @@ namespace OTSPartA_STDEditor
                     Result ret=ImportFromResult(STDId, m_dbConnection);
                     if(ret== Result.NoMatched)
                     {
-                        MessageBox.Show(table_STDEditor["message3"].ToString(), table_STDEditor["message32"].ToString());
+                        MessageBox.Show("No matching energy spectrum data was found", "Tip");
                     }
                     m_dbConnection.Close();
                     int color = Convert.ToInt32(ParseRGB(colorHx16toRGB(m_SubMidWindow.m_MainForm.STDDictionary[int.Parse(STDId)].Color)).ToString());
@@ -1348,7 +1348,7 @@ namespace OTSPartA_STDEditor
                 }
                 catch /*(Exception ex)*/
                 {
-                    MessageBox.Show(table_STDEditor["message21"].ToString(), table_STDEditor["message32"].ToString());
+                    MessageBox.Show("Failed to load Xray data!", "Tip");
                 }
             }
         }
@@ -1374,13 +1374,13 @@ namespace OTSPartA_STDEditor
                         {
                             if (dt.Rows.Count > 0)
                             {
-                                DialogResult dr = MessageBox.Show(table_STDEditor["message29"].ToString() + STDId+ table_STDEditor["message30"].ToString(), table_STDEditor["message32"].ToString(), MessageBoxButtons.OKCancel);
+                                DialogResult dr = MessageBox.Show("ID Num:" + STDId+ ", this rule has found the first match object, is it loaded?", "Tip", MessageBoxButtons.OKCancel);
                                 if(dr == DialogResult.OK)
                                 {
                                     m_SubMidWindow.m_MainForm.IsModified = true;
                                     if (SelSTDDBBySTDId(STDId))
                                     {
-                                        if (MessageBox.Show(table_STDEditor["message29"].ToString() + STDId + table_STDEditor["message36"].ToString(), table_STDEditor["message32"].ToString(), MessageBoxButtons.OKCancel) == DialogResult.OK)
+                                        if (MessageBox.Show("ID Num:" + STDId + ", the database already contains records of this rule XRay curve, is it overwritten?", "Tip", MessageBoxButtons.OKCancel) == DialogResult.OK)
                                         {
                                             UpdateSTDXray(int.Parse(STDId), (byte[])dt.Rows[0]["XrayData"]);
                                         } 
@@ -1415,7 +1415,7 @@ namespace OTSPartA_STDEditor
             }
             catch /*(Exception ee)*/
             {
-                MessageBox.Show(table_STDEditor["message21"].ToString(), table_STDEditor["message32"].ToString());
+                MessageBox.Show("Failed to load Xray data!", "Tip");
                 return Result.Fail;
             }
         }

+ 1 - 1
OTSPartA_STDEditor/STDRuleslist.cs

@@ -281,7 +281,7 @@ namespace OTSPartA_STDEditor
             }
             else
             {
-                MessageBox.Show(table_STDRuleslist["message1"].ToString(), "Tip");
+                MessageBox.Show("There is no rule to delete!", "Tip");
             }
         }
         private void ToolStripMenuItem_Del_Click(object sender, EventArgs e)

+ 4 - 4
OTSPartA_STDEditor/XrayContrastForm.cs

@@ -616,19 +616,19 @@ namespace OTSPartA_STDEditor
                 string strTime = txtCollectTime.Text.Trim();
                 if (txtCollectTime.Equals(""))
                 {
-                    showMessage(table["message1"].ToString());
+                    showMessage("Please fill in the collection time name!");
                     txtCollectTime.Focus();
                     return;
                 }
                 if (!IsMatch(strTime, 1))
                 {
-                    showMessage(table["message2"].ToString());
+                    showMessage("Error collecting time content, the format should be integer!");
                     txtCollectTime.Focus();
                     return;
                 }
                 if (Convert.ToInt32(strTime) < 100)
                 {
-                    showMessage(table["message3"].ToString());
+                    showMessage("CollectTime must not be less than 100 milliseconds!");
                     txtCollectTime.Focus();
                     return;
                 }
@@ -830,7 +830,7 @@ namespace OTSPartA_STDEditor
         /// <param name="strContent"></param>
         protected void showMessage(string strContent)
         {
-            MessageBox.Show(strContent, table["message4"].ToString());
+            MessageBox.Show(strContent, "Tip");
         }
 
         #region 常用数据验证的封装,数字字符的验证