完成打开导入OPC变量对话框自动连接服务器

This commit is contained in:
2025-07-09 21:35:51 +08:00
parent 5915a6c87b
commit b1e79a63df
6 changed files with 81 additions and 56 deletions

View File

@@ -37,6 +37,8 @@ public partial class OpcUaImportDialogViewModel : ObservableObject
{
OpcUaNodes = new ObservableCollection<OpcUaNode>();
SelectedNodeVariables = new ObservableCollection<VariableData>();
// Automatically connect when the ViewModel is created
_ = Connect().ConfigureAwait(false);
}
[RelayCommand]