You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
lj_plc/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Test/TestAction.cs

95 lines
2.4 KiB
C#

using System;
using System.Collections.Generic;
1 year ago
using System.Data;
using System.Diagnostics;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using DataBlockHelper.DBHelpers;
using DevExpress.XtraEditors.Filtering.Templates;
using ICSharpCode.Core;
using Mesnac.Action.Base;
using Mesnac.Action.ChemicalWeighing.LjReport.OpenDoor;
using Mesnac.Action.ChemicalWeighing.MinAn;
using Mesnac.Action.ChemicalWeighing.RgvPlc;
using Mesnac.Basic;
1 year ago
using Mesnac.Codd.Session;
using Mesnac.Controls.Base;
using Mesnac.Controls.ChemicalWeighing;
using Mesnac.Controls.Default;
1 year ago
namespace Mesnac.Action.ChemicalWeighing.Test
{
public class TestAction : DatabaseAction, IAction
{
HslLanternAlarm lanternAlarm;
MCButton mCButton;
HslSwitch hslSwitch;
1 year ago
public void timer1EventProcessor(object source, EventArgs e)
{
1 year ago
DB2105Helper db2105Helper = new DB2105Helper();
var lis = db2105Helper.ReadReadyG1;
lis = db2105Helper.ReadReadyG2;
lis = db2105Helper.ReadReadyG3;
lis = db2105Helper.ReadReadyG4;
lis = db2105Helper.ReadReadyG5;
lis = db2105Helper.ReadReadyG6;
lis = db2105Helper.ReadReadyG7;
lis = db2105Helper.ReadReadyG8;
Merge branch 'dep' into dep_pf # Conflicts: # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/ChemicalWeighingPlc/PlcPlanHelper.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/FinishBatch/FinishBatchHelper.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/FinishBatch/SaveHelper/ReportGelDoserHelper.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/FreeDb/DBEntity/LjFormulaDetailDownEntity.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjClick/FormClientManager.Designer.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjClick/FormClientManager.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjClick/FormClientManager.resx # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjClick/InitFormAction.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjHelp.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMetage/MetageHelp.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPlanning/DownToDatabase.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPlanning/DownloadAction.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPlanning/LjPlanningPlcHelp.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjPlanning/PauseAction.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjWeight/WeightSettingPlc.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Mesnac.Action.ChemicalWeighing.csproj # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Pl/PlcConnect.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Product/PptPlan/AutoDownloadAction.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Sys/TimerRunService.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Technical/PmtRecipe/DeleteAction.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Technical/PmtRecipe/FrmRecipe.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Technical/PmtRecipe/ModifyRecipeAction.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Technical/PmtRecipe/SelectRecipe.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Technical/PmtRecipe/SetCratParam.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Technical/PmtRecipe/SetCratParamForm.cs # Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Test/TestAction.cs # DataBlockHelper/DataBlockHelper.csproj # DataBlockHelper/Entity/ClickEntity.cs # DataBlockHelper/PlcConnect.cs # Main/MCEdit/Data/MCProject/SCWSProject2.mprj # Main/MCEdit/Data/MCProject/nodeForm/Form1.xml
1 year ago
var liss = db2105Helper.ReadReadyM1;
liss = db2105Helper.ReadReadyM2;
liss = db2105Helper.ReadReadyM3;
liss = db2105Helper.ReadReadyM4;
liss = db2105Helper.ReadReadyM5;
liss = db2105Helper.ReadReadyM6;
liss = db2105Helper.ReadReadyM7;
liss = db2105Helper.ReadReadyM8;
var yw= Db3000Helper.ReadModel();
1 year ago
}
public void Run(RuntimeParameter runtime)
{
base.RunIni(runtime); //必须调用
var allDb=GetAllControls();
mCButton = allDb.FirstOrDefault(x => x.Name == "MCButton1") as MCButton;
mCButton.Click += new EventHandler(timer1EventProcessor);
1 year ago
hslSwitch = allDb.FirstOrDefault(x => x.Name == "HsSwitch1") as HslSwitch;
hslSwitch.OnSwitchChanged += HslSwitch_OnSwitchChanged;
1 year ago
1 year ago
1 year ago
//MCButton1
//OpenDoorService
1 year ago
}
private void HslSwitch_OnSwitchChanged(object arg1, bool arg2)
{
HslSwitch hsl= (HslSwitch)arg1;
hslSwitch.Text = "测试:"+arg2;
bool b = arg2;
}
}
}