alielie
2026-06-15 f08871fe7d148d667f2f11f80f64de71a0d9504c
Plugin.TsExecution/SingleControl.xaml.cs
@@ -5,6 +5,7 @@
using HMI.Util;
using NationalInstruments.TestStand.Interop.API;
using NPOI.HSSF.UserModel;
using NPOI.SS.Formula.Functions;
using NPOI.SS.UserModel;
using Plugin.TsExecution.Entity;
using System;
@@ -180,6 +181,16 @@
            set
            {
                Set(ref _probeCount, value);
                try
                {
                    if (ProbeWarn <= 0) probeCountAlarm.Visibility = Visibility.Collapsed;
                    else if (value >= ProbeWarn) probeCountAlarm.Visibility = Visibility.Visible;
                    else probeCountAlarm.Visibility = Visibility.Collapsed;
                }
                catch
                {
                }
            }
        }
@@ -222,7 +233,15 @@
            }
        }
        public int ProbeWarn { get; private set; }
        private int _probeWarn;
        public int ProbeWarn
        {
            get => _probeWarn;
            private set
            {
                Set(ref _probeWarn, value);
            }
        }
        private bool isAutoMode;
        public bool IsAutoMode
@@ -246,9 +265,9 @@
                Interval = 100
            };
            refreshTimer.Elapsed += RefreshTimer_Elapsed;
            RefreshProbeCount(null);
            ReadCounter();
            InitializeComponent();
            RefreshProbeCount(null);
            try
            {
                var value = ParameterManager.GetCommonParameterByName("AutoTestMode");
@@ -653,10 +672,6 @@
            /// 写到配置文件
            IniFileHelper.WriteIniData("Socket" + this.index.ToString(), "ProbeCount", count.ToString(), this.CountIniPath);
            ProbeCount = count;
            //if (ProbeWarn <= 0) probeCountAlarm.Visibility = Visibility.Collapsed;
            //else if (count >= ProbeWarn) probeCountAlarm.Visibility = Visibility.Visible;
            //else probeCountAlarm.Visibility = Visibility.Collapsed;
        }
        public void RefreshProduct(ProductData product)