From 7e668565eb3bc750a3910f4ea07d7f1dc6251045 Mon Sep 17 00:00:00 2001 From: Emmanuele Sassi Date: Mon, 1 Jun 2026 18:48:12 +0200 Subject: [PATCH] - aggiunto debug ExecProcess - inizio correzione Parametri pezzo --- .../ExecProcessManager/MyExecProcessManager.vb | 6 +++++- .../PartParametersWnd/PartParametersWndV.xaml | 3 +-- .../PartParametersWnd/PartParametersWndV.xaml.vb | 1 + .../PartParametersWnd/PartParametersWndVM.vb | 11 +++++++++-- EgtBEAMWALL.Optimizer/Project/ProjectVM.vb | 2 +- 5 files changed, 17 insertions(+), 6 deletions(-) diff --git a/EgtBEAMWALL.Optimizer/ExecProcessManager/MyExecProcessManager.vb b/EgtBEAMWALL.Optimizer/ExecProcessManager/MyExecProcessManager.vb index ff40f63e..934ff556 100644 --- a/EgtBEAMWALL.Optimizer/ExecProcessManager/MyExecProcessManager.vb +++ b/EgtBEAMWALL.Optimizer/ExecProcessManager/MyExecProcessManager.vb @@ -44,6 +44,7 @@ Module MyExecProcessManager Dim sEnvironment As String = "" Dim sPipeLuaFile As String = "" Dim nMaxCamInstances As Integer = 0 + Dim bDebug As Boolean = False While GetMainPrivateProfileString(S_EXECGROUP & nGroupIndex.ToString(), K_ENVIRONMENT, "", sEnvironment) > 0 AndAlso GetMainPrivateProfileString(S_EXECGROUP & nGroupIndex.ToString(), K_PIPELUAFILE, "", sPipeLuaFile) AndAlso GetMainPrivateProfileString(S_EXECGROUP & nGroupIndex.ToString(), K_MAXCAMINSTANCES, "", nMaxCamInstances) @@ -64,7 +65,10 @@ Module MyExecProcessManager nGroupIndex += 1 Continue While End If - Dim NewExecProcessManager As New ExecProcessManager(nGroupIndex, Environment, sCamExePath, PipeLuaPath, nMaxCamInstances, ExecProcessManager.ReturnModes.EVENT_, False) + ' leggo se modalita' debug + Dim nDebug As Integer = GetMainPrivateProfileInt(S_EXECGROUP & nGroupIndex.ToString(), K_DEBUG, 0) + bDebug = (nDebug = 1) + Dim NewExecProcessManager As New ExecProcessManager(nGroupIndex, Environment, sCamExePath, PipeLuaPath, nMaxCamInstances, ExecProcessManager.ReturnModes.EVENT_, bDebug) AddHandler NewExecProcessManager.m_AnswerReceived, AddressOf ExecProcessManager_AnswerReceived NewExecProcessManager.StartExecutionThread() m_ExecProcessManagerList.Add(Environment, NewExecProcessManager) diff --git a/EgtBEAMWALL.Optimizer/PartParametersWnd/PartParametersWndV.xaml b/EgtBEAMWALL.Optimizer/PartParametersWnd/PartParametersWndV.xaml index 34757f74..b2d862ee 100644 --- a/EgtBEAMWALL.Optimizer/PartParametersWnd/PartParametersWndV.xaml +++ b/EgtBEAMWALL.Optimizer/PartParametersWnd/PartParametersWndV.xaml @@ -85,8 +85,7 @@ diff --git a/EgtBEAMWALL.Optimizer/PartParametersWnd/PartParametersWndV.xaml.vb b/EgtBEAMWALL.Optimizer/PartParametersWnd/PartParametersWndV.xaml.vb index 9fcd8af8..e0c3959e 100644 --- a/EgtBEAMWALL.Optimizer/PartParametersWnd/PartParametersWndV.xaml.vb +++ b/EgtBEAMWALL.Optimizer/PartParametersWnd/PartParametersWndV.xaml.vb @@ -14,4 +14,5 @@ Private Sub CloseWindow(bDialogResult As Boolean) Handles m_PartParametersWndVM.m_CloseWindow Me.DialogResult = bDialogResult End Sub + End Class diff --git a/EgtBEAMWALL.Optimizer/PartParametersWnd/PartParametersWndVM.vb b/EgtBEAMWALL.Optimizer/PartParametersWnd/PartParametersWndVM.vb index 4e9ce09e..03f221fc 100644 --- a/EgtBEAMWALL.Optimizer/PartParametersWnd/PartParametersWndVM.vb +++ b/EgtBEAMWALL.Optimizer/PartParametersWnd/PartParametersWndVM.vb @@ -8,6 +8,13 @@ Public Class PartParametersWndVM Friend Event m_CloseWindow(bDialogResult As Boolean) + Private m_CurrPart As BTLPartVM + Public ReadOnly Property CurrPart As BTLPartVM + Get + Return m_CurrPart + End Get + End Property + ' Definizione comandi Private m_cmdOk As ICommand @@ -271,8 +278,8 @@ Public Class PartParametersWndVM #Region "CONSTRUCTOR" - Sub New() - + Sub New(CurrPart As BTLPartVM) + m_CurrPart = CurrPart End Sub #End Region ' CONSTRUCTOR diff --git a/EgtBEAMWALL.Optimizer/Project/ProjectVM.vb b/EgtBEAMWALL.Optimizer/Project/ProjectVM.vb index b97c0dcf..6d70f539 100644 --- a/EgtBEAMWALL.Optimizer/Project/ProjectVM.vb +++ b/EgtBEAMWALL.Optimizer/Project/ProjectVM.vb @@ -991,7 +991,7 @@ Public Class ProjectVM End Property Friend Sub Parameter() - Dim PartParametersWnd As New PartParametersWndV(Application.Current.MainWindow, New PartParametersWndVM()) + Dim PartParametersWnd As New PartParametersWndV(Application.Current.MainWindow, New PartParametersWndVM(m_BTLStructureVM.SelBTLPart)) PartParametersWnd.ShowDialog() End Sub