change - 添加combobox

wangsr
wangsr 1 year ago
parent 25a8cad456
commit a9fe7cdc1b

@ -1,4 +1,5 @@
using Mesnac.Controls.Base; using Mesnac.Controls.Base;
using Mesnac.Controls.Default;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Linq; using System.Linq;
@ -19,8 +20,10 @@ namespace Mesnac.Action.ChemicalWeighing.AutoControl.Entity
public IBaseControl Line6 { get; set; } public IBaseControl Line6 { get; set; }
public IBaseControl Line7 { get; set; } public IBaseControl Line7 { get; set; }
public IBaseControl Line8 { get; set; } public IBaseControl Line8 { get; set; }
public IBaseControl ChooseMaterial1 { get; set; }
public IBaseControl ChooseMaterial2 { get; set; } public MCCombobox ChooseMaterial1 { get; set; }
public MCCombobox ChooseMaterial2 { get; set; }
public IBaseControl MaterialWeight1 { get; set; } public IBaseControl MaterialWeight1 { get; set; }
public IBaseControl MaterialWeight2 { get; set; } public IBaseControl MaterialWeight2 { get; set; }
public IBaseControl MaterialTolerance1 { get; set; } public IBaseControl MaterialTolerance1 { get; set; }

@ -6,6 +6,7 @@ using Mesnac.Action.ChemicalWeighing.AutoControl.DB;
using Mesnac.Action.ChemicalWeighing.AutoControl.Entity; using Mesnac.Action.ChemicalWeighing.AutoControl.Entity;
using Mesnac.Action.ChemicalWeighing.LjMixManager; using Mesnac.Action.ChemicalWeighing.LjMixManager;
using Mesnac.Controls.Base; using Mesnac.Controls.Base;
using Mesnac.Controls.Default;
using Mesnac.Core.Service; using Mesnac.Core.Service;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
@ -13,6 +14,7 @@ using System.Linq;
using System.Text; using System.Text;
using System.Threading.Tasks; using System.Threading.Tasks;
using System.Windows.Forms; using System.Windows.Forms;
using Button = System.Windows.Forms.Button;
namespace Mesnac.Action.ChemicalWeighing.AutoControl namespace Mesnac.Action.ChemicalWeighing.AutoControl
{ {
@ -92,8 +94,9 @@ namespace Mesnac.Action.ChemicalWeighing.AutoControl
ControlsEntity.Line7 = GetBaseControl("Line7"); ControlsEntity.Line7 = GetBaseControl("Line7");
ControlsEntity.Line8 = GetBaseControl("Line8"); ControlsEntity.Line8 = GetBaseControl("Line8");
ControlsEntity.ChooseMaterial1 = GetBaseControl("ChooseMaterial1"); ControlsEntity.ChooseMaterial1 = GetComboBoxControl("ChooseMaterial1");
ControlsEntity.ChooseMaterial2 = GetBaseControl("ChooseMaterial2"); ControlsEntity.ChooseMaterial2 = GetComboBoxControl("ChooseMaterial2");
ControlsEntity.MaterialWeight1 = GetBaseControl("MaterialWeight1"); ControlsEntity.MaterialWeight1 = GetBaseControl("MaterialWeight1");
ControlsEntity.MaterialWeight2 = GetBaseControl("MaterialWeight2"); ControlsEntity.MaterialWeight2 = GetBaseControl("MaterialWeight2");
ControlsEntity.MaterialTolerance1 = GetBaseControl("MaterialTolerance1"); ControlsEntity.MaterialTolerance1 = GetBaseControl("MaterialTolerance1");
@ -235,6 +238,11 @@ namespace Mesnac.Action.ChemicalWeighing.AutoControl
{ {
return McControls.First(x => x.Name == name) as Button; return McControls.First(x => x.Name == name) as Button;
} }
private MCCombobox GetComboBoxControl(string name)
{
return McControls.First(x => x.Name == name) as MCCombobox;
}
} }
} }

@ -176,9 +176,6 @@
<SpecificVersion>False</SpecificVersion> <SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\PlugInPlatform\Mesnac.PlugIn.dll</HintPath> <HintPath>..\..\..\PlugInPlatform\Mesnac.PlugIn.dll</HintPath>
</Reference> </Reference>
<Reference Include="Microsoft.Office.Interop.Excel">
<HintPath>..\..\Microsoft.Office.Interop.Excel.dll</HintPath>
</Reference>
<Reference Include="System" /> <Reference Include="System" />
<Reference Include="System.Configuration" /> <Reference Include="System.Configuration" />
<Reference Include="System.Core" /> <Reference Include="System.Core" />

Loading…
Cancel
Save