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.
38 lines
1.3 KiB
C#
38 lines
1.3 KiB
C#
using Mesnac.Action.Base;
|
|
using Mesnac.Controls.Base;
|
|
using Mesnac.Controls.Default;
|
|
using Mesnac.Controls.Default.GCTS;
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
|
|
namespace Mesnac.Action.ChemicalWeighing.ProjectDebug
|
|
{
|
|
public class Speed_DebugAction : ChemicalWeighingAction, IAction
|
|
{
|
|
public void Run(RuntimeParameter runtime)
|
|
{
|
|
base.RunIni(runtime); //必须调用
|
|
SpecialButton2 CurrentSB2 = runtime.Sender as SpecialButton2;
|
|
string _sbvNumber = CurrentSB2.Name;
|
|
ICSharpCode.Core.LoggingService<DJF_DebugAction>.Debug(_sbvNumber + "器件状态设置");
|
|
if (_sbvNumber == "")
|
|
{
|
|
ICSharpCode.Core.LoggingService<DJF_DebugAction>.Warn(String.Format("请设置正确的名称!"));
|
|
return;
|
|
}
|
|
else
|
|
{
|
|
FrmSpeedProjectDebug frmProjectDebug = new FrmSpeedProjectDebug();
|
|
frmProjectDebug.FormText = CurrentSB2.Name;
|
|
frmProjectDebug.PlcName = CurrentSB2.TextName;
|
|
frmProjectDebug.PlcValue = CurrentSB2.TextValue.ToString();
|
|
frmProjectDebug.ShowDialog();
|
|
}
|
|
|
|
}
|
|
}
|
|
}
|