This commit is contained in:
sc committed 2024-08-29 00:27:16 +08:00
commit 4a8a4607c8
6 files changed
+59 -96

No files matched your search

+8 -96
View File
@@ -34,18 +34,21 @@ namespace DyeingComputer.Windows
e.Handled = !re.IsMatch(e.Text);
}
string[] a = {"001","007","008","013","017", "020", "022", "031", "035", "036", "039", "040", "041", "049", "050",
"051", "054", "055", "056","065","066","067","090","091","092","093","094" };
private void Form1_Load()
{
this.boxID.Items.Add(Properties.Resources.TemperatureControl);
this.boxID.Items.Add(Properties.Resources.AddWater + "(" + Properties.Resources.WaterLevel + ")");
this.boxID.Items.Add(Properties.Resources.AddWater + "(" + Properties.Resources.Flowmeter + ")");
this.boxID.Items.Add(Properties.Resources.Washing + "(" + Properties.Resources.WaterLevel + ")");
this.boxID.Items.Add(Properties.Resources.Washing + "(" + Properties.Resources.Cooling + ")");
this.boxID.Items.Add(Properties.Resources.Drainage);
}
@@ -54,99 +57,8 @@ namespace DyeingComputer.Windows
int l = boxNAME.Text.Length;
string text = boxNAME.Text.ToString();
if (l == 3)
{
if(text == "001")
{
boxID.SelectedIndex = 0; //温度控制
}
else
if (text == "007")
{
boxID.SelectedIndex = 1; //水位入水
}
else
if (text == "008")
{
boxID.SelectedIndex = 2; //流量入水
}
else
if (text == "013")
{
boxID.SelectedIndex = 3;//水洗
}
else
if (text == "017") { }
else
if (text == "020") { }
else
if (text == "022") { }
else
if (text == "031") { }
else
if (text == "035") { }
else
if (text == "036") { }
else
if (text == "039") { }
else
if (text == "040") { }
else
if (text == "041") { }
else
if (text == "049") { }
else
if (text == "050") { }
else
if (text == "051") { }
else
if (text == "054") { }
else
if (text == "055") { }
else
if (text == "056") { }
else
if (text == "065") { }
else
if (text == "066") { }
else
if (text == "067") { }
else
if (text == "072") { }
else
if (text == "073") { }
else
if (text == "074") { }
else
if (text == "075") { }
else
if (text == "076") { }
else
if (text == "077") { }
else
if (text == "070") { }
else
if (text == "090") { }
else
if (text == "091") { }
else
if (text == "092") { }
else
if (text == "093") { }
else
if (text == "094") { }
else
if (text == "095") { }
else
if (text == "096") { }
else
if (text == "097") { }
else
if (text == "101") { }
else
if (text == "102") { }
else
if (text == "103") { }
{
boxID.SelectedIndex = Array.IndexOf(a, text);
}
}