diff --git a/EgtBEAMWALL.Core/BTLModel/BTLFeatureM.vb b/EgtBEAMWALL.Core/BTLModel/BTLFeatureM.vb index 7b7dd37a..7c59e64c 100644 --- a/EgtBEAMWALL.Core/BTLModel/BTLFeatureM.vb +++ b/EgtBEAMWALL.Core/BTLModel/BTLFeatureM.vb @@ -547,12 +547,7 @@ Public Class BTLFeatureM bOk = True Else ' Impossibile creare una feature con questi valori - ERRORE - 'MessageBox.Show(EgtMsg(61852), EgtMsg(30007)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61852), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61852), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61852), EgtMsg(30007)) nFeatureId = EgtBeamModifyProcess(Me.nFeatureId, Me.nSelGRP, Me.nPRC, Me.nSelSIDE, "", Me.nPRID, Me.frFRAME, vPar, sPar, vParQ, nCrvId, nCrv2Id) SetFeatureId(nFeatureId) diff --git a/EgtBEAMWALL.Core/EgtDataGrid/EgtDataGrid.xaml.vb b/EgtBEAMWALL.Core/EgtDataGrid/EgtDataGrid.xaml.vb index 0e1f326e..93a72e68 100644 --- a/EgtBEAMWALL.Core/EgtDataGrid/EgtDataGrid.xaml.vb +++ b/EgtBEAMWALL.Core/EgtDataGrid/EgtDataGrid.xaml.vb @@ -62,12 +62,7 @@ Public Class EgtDataGrid newItems(index).InitColumn(col) context.Columns.Add(col) Catch ex As Exception - 'MessageBox.Show(String.Format(EgtMsg(61883), newItems(index).Name, newItems(index).ParentDataGridName), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, String.Format(EgtMsg(61883), newItems(index).Name, newItems(index).ParentDataGridName), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, String.Format(EgtMsg(61883), newItems(index).Name, newItems(index).ParentDataGridName), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) - End If + MessageBox.Show(String.Format(EgtMsg(61883), newItems(index).Name, newItems(index).ParentDataGridName), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) End Try Next @@ -90,12 +85,7 @@ Public Class EgtDataGrid CurrDataGrid.Columns(e.NewStartingIndex).DisplayIndex = e.NewStartingIndex End If Catch ex As Exception - 'MessageBox.Show(String.Format(EgtMsg(61883), one.Name, one.ParentDataGridName), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, String.Format(EgtMsg(61883), one.Name, one.ParentDataGridName), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, String.Format(EgtMsg(61883), one.Name, one.ParentDataGridName), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) - End If + MessageBox.Show(String.Format(EgtMsg(61883), one.Name, one.ParentDataGridName), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) End Try Next End If diff --git a/EgtBEAMWALL.Core/Lib/NewMachGroupPanelVM.vb b/EgtBEAMWALL.Core/Lib/NewMachGroupPanelVM.vb index efd24a4c..0d2e5a59 100644 --- a/EgtBEAMWALL.Core/Lib/NewMachGroupPanelVM.vb +++ b/EgtBEAMWALL.Core/Lib/NewMachGroupPanelVM.vb @@ -214,11 +214,7 @@ Public Class NewMachGroupPanelVM Dim m_MessageBoxResult As MessageBoxResult If MachGroupVMList.Count = 1 Then 'chiedo conferma prima di resettare il gruppo di lavorazione - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62539), "", MessageBoxButton.YesNo, MessageBoxImage.Question) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62539), "", MessageBoxButton.YesNo, MessageBoxImage.Question) - End If + MessageBox.Show(Application.Current.MainWindow, EgtMsg(62539), "", MessageBoxButton.YesNo, MessageBoxImage.Question) Select Case m_MessageBoxResult Case MessageBoxResult.Yes ' cancello il gruppo corrente e ne creo uno nuovo con lo stesso nome @@ -232,11 +228,7 @@ Public Class NewMachGroupPanelVM End Select Else 'chiedo conferma prima di cancellare il gruppo di lavorazione - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62539), "", MessageBoxButton.YesNo, MessageBoxImage.Question) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62539), "", MessageBoxButton.YesNo, MessageBoxImage.Question) - End If + MessageBox.Show(Application.Current.MainWindow, EgtMsg(62539), "", MessageBoxButton.YesNo, MessageBoxImage.Question) Select Case m_MessageBoxResult Case MessageBoxResult.Yes ' cancello quello selezionato (ovvero il corrente) diff --git a/EgtBEAMWALL.Supervisor/CALCPanel/CALCPanelVM.vb b/EgtBEAMWALL.Supervisor/CALCPanel/CALCPanelVM.vb index 2d3f9270..e6e38112 100644 --- a/EgtBEAMWALL.Supervisor/CALCPanel/CALCPanelVM.vb +++ b/EgtBEAMWALL.Supervisor/CALCPanel/CALCPanelVM.vb @@ -91,12 +91,7 @@ Public Class CALCPanelVM Private Sub Calc_Ended(sender As Object, e As CalcEndEventArgs) If e.End_ <> CalcEndEventArgs.Results.OK Then - 'MessageBox.Show("Execution error (all processes are disabled)") - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62540)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62540)) - End If + MessageBox.Show("Execution error (all processes are disabled)") End If ' ciclo sui pezzi Dim bNotOkFound As Boolean = False diff --git a/EgtBEAMWALL.Supervisor/Comms/NUMAxiumComm.vb b/EgtBEAMWALL.Supervisor/Comms/NUMAxiumComm.vb index 7ccb18ce..6b70f440 100644 --- a/EgtBEAMWALL.Supervisor/Comms/NUMAxiumComm.vb +++ b/EgtBEAMWALL.Supervisor/Comms/NUMAxiumComm.vb @@ -474,19 +474,9 @@ Public Class NUMAxiumComm Private Sub objDGeneralFunction_VariableWritten(ByVal errorCode As Short) If errorCode <> 0 Then - 'MessageBox.Show("Error from VariableWritten:" & " " & errorCode.ToString()) - If EgtBEAMWALL.Core.Configuration.bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62541) & " " & errorCode.ToString()) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62541) & " " & errorCode.ToString()) - End If + MessageBox.Show("Error from VariableWritten:" & " " & errorCode.ToString()) Else - 'MessageBox.Show("VariableWritten successfully") - If EgtBEAMWALL.Core.Configuration.bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62542)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62542)) - End If + MessageBox.Show("VariableWritten successfully") End If End Sub diff --git a/EgtBEAMWALL.Supervisor/Comms/NUMAxiumPcToolkitComm.vb b/EgtBEAMWALL.Supervisor/Comms/NUMAxiumPcToolkitComm.vb index b14549f0..1d8a8ae6 100644 --- a/EgtBEAMWALL.Supervisor/Comms/NUMAxiumPcToolkitComm.vb +++ b/EgtBEAMWALL.Supervisor/Comms/NUMAxiumPcToolkitComm.vb @@ -741,19 +741,9 @@ Public Class NUMAxiumPcToolkitComm Private Sub objDGeneralFunction_VariableWritten(ByVal errorCode As Short) If errorCode <> 0 Then - 'MessageBox.Show("Error from VariableWritten:" & " " & errorCode.ToString()) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62541) & " " & errorCode.ToString()) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62541) & " " & errorCode.ToString()) - End If + MessageBox.Show("Error from VariableWritten:" & " " & errorCode.ToString()) Else - 'MessageBox.Show("VariableWritten successfully") - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62542)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62542)) - End If + MessageBox.Show("VariableWritten successfully") End If End Sub diff --git a/EgtBEAMWALL.Supervisor/Comms/NUMFlexiumComm.vb b/EgtBEAMWALL.Supervisor/Comms/NUMFlexiumComm.vb index 1ced2966..9b975aa4 100644 --- a/EgtBEAMWALL.Supervisor/Comms/NUMFlexiumComm.vb +++ b/EgtBEAMWALL.Supervisor/Comms/NUMFlexiumComm.vb @@ -446,19 +446,9 @@ Public Class NUMFlexiumComm Private Sub objDGeneralFunction_VariableWritten(ByVal errorCode As Short) If errorCode <> 0 Then - 'MessageBox.Show("Error from VariableWritten:" & " " & errorCode.ToString()) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62541) & " " & errorCode.ToString()) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62541) & " " & errorCode.ToString()) - End If + MessageBox.Show("Error from VariableWritten:" & " " & errorCode.ToString()) Else - 'MessageBox.Show("VariableWritten successfully") - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62542)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62542)) - End If + MessageBox.Show("VariableWritten successfully") End If End Sub diff --git a/EgtBEAMWALL.Supervisor/Comms/TPAComm.vb b/EgtBEAMWALL.Supervisor/Comms/TPAComm.vb index 0669ca55..ac7fc5f5 100644 --- a/EgtBEAMWALL.Supervisor/Comms/TPAComm.vb +++ b/EgtBEAMWALL.Supervisor/Comms/TPAComm.vb @@ -122,12 +122,7 @@ Public Class TPAComm AddHandler _remObject.RPCUpdate, m_Rem_RPCUpdateEventHandler AddHandler _remObject.VariableCommandExecuted, m_Rem_VariableCommandExecutedEventHandler Catch ex As System.Runtime.Remoting.RemotingException - Dim dR As MessageBoxResult - If EgtBEAMWALL.Core.Configuration.bOnlyProd Then - dR = EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, ex.Message) - Else - dR = EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, ex.Message) - End If + MessageBox.Show(Application.Current.MainWindow, ex.Message) End Try ' creo classe che gestisce variabili m_RWVariableManager = RWVariableManager.CreateRWVariableManager(Me) @@ -189,12 +184,7 @@ Public Class TPAComm Private Sub RemoteObject_ServerError(ByVal sender As Object, ByVal seEA As ISOCNC.Remoting.ServerErrorEventArgs) m_ResultCallbackDlg(CommandTypes.ERROR_, CommandStates.ERROR_, ResultTypes.RESULT, EgtUILib.EgtMsg(62543) & seEA.[Error]) - Dim dr As MessageBoxResult - If EgtBEAMWALL.Core.Configuration.bOnlyProd Then - dr = EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtUILib.EgtMsg(62543) & seEA.[Error]) - Else - dr = EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtUILib.EgtMsg(62543) & seEA.[Error]) - End If + MessageBox.Show(Application.Current.MainWindow, EgtUILib.EgtMsg(62543) & seEA.[Error]) End Sub Private Sub RemoteObject_AxisCoordinatesUpdate(ByVal axisValue As Double, ByVal axisIndex As Integer) diff --git a/EgtBEAMWALL.Supervisor/ItemParamList/FeatureInPartInRawPartListV.xaml b/EgtBEAMWALL.Supervisor/ItemParamList/FeatureInPartInRawPartListV.xaml index 95c42dfb..292395f5 100644 --- a/EgtBEAMWALL.Supervisor/ItemParamList/FeatureInPartInRawPartListV.xaml +++ b/EgtBEAMWALL.Supervisor/ItemParamList/FeatureInPartInRawPartListV.xaml @@ -18,7 +18,7 @@ ScrollViewer.VerticalScrollBarVisibility="Auto" ScrollViewer.HorizontalScrollBarVisibility="Auto" Margin="0,0,0,5" - ColumnHeaderBackground="{DynamicResource {x:Static SystemColors.ControlBrushKey}}" + ColumnHeaderBackground="{StaticResource DataGrid.Static.Background}" ColumnHeaderForeground="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" ColumnHeaderFontWeight="Normal" ColumnHeaderPadding="0,2,0,2" diff --git a/EgtBEAMWALL.Supervisor/ItemParamList/PartInRawPartListV.xaml b/EgtBEAMWALL.Supervisor/ItemParamList/PartInRawPartListV.xaml index 92764cc5..7f7c1324 100644 --- a/EgtBEAMWALL.Supervisor/ItemParamList/PartInRawPartListV.xaml +++ b/EgtBEAMWALL.Supervisor/ItemParamList/PartInRawPartListV.xaml @@ -17,7 +17,7 @@ ScrollViewer.VerticalScrollBarVisibility="Auto" ScrollViewer.HorizontalScrollBarVisibility="Auto" Margin="0,0,0,5" - ColumnHeaderBackground="{DynamicResource {x:Static SystemColors.ControlBrushKey}}" + ColumnHeaderBackground="{StaticResource DataGrid.Static.Background}" ColumnHeaderForeground="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" ColumnHeaderFontWeight="Normal" ColumnHeaderPadding="0,2,0,2" diff --git a/EgtBEAMWALL.Supervisor/ItemParamList/RawPartListV.xaml b/EgtBEAMWALL.Supervisor/ItemParamList/RawPartListV.xaml index 62ae47f3..32be2d61 100644 --- a/EgtBEAMWALL.Supervisor/ItemParamList/RawPartListV.xaml +++ b/EgtBEAMWALL.Supervisor/ItemParamList/RawPartListV.xaml @@ -18,7 +18,7 @@ ScrollViewer.VerticalScrollBarVisibility="Auto" ScrollViewer.HorizontalScrollBarVisibility="Auto" Margin="0,0,0,5" - ColumnHeaderBackground="{DynamicResource {x:Static SystemColors.ControlBrushKey}}" + ColumnHeaderBackground="{StaticResource DataGrid.Static.Background}" ColumnHeaderForeground="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" ColumnHeaderFontWeight="Normal" ColumnHeaderPadding="0,2,0,2" diff --git a/EgtBEAMWALL.Supervisor/LeftPanel/LeftPanelVM.vb b/EgtBEAMWALL.Supervisor/LeftPanel/LeftPanelVM.vb index 8aa38491..c84d1c85 100644 --- a/EgtBEAMWALL.Supervisor/LeftPanel/LeftPanelVM.vb +++ b/EgtBEAMWALL.Supervisor/LeftPanel/LeftPanelVM.vb @@ -738,12 +738,7 @@ Public Class LeftPanelVM Dim SelMachGroup As MyMachGroupVM = Map.refProjectVM.SupervisorMachGroupPanelVM.SelectedMachGroup ' se gia' prodotto, o in produzione non lo posso eliminare If SelMachGroup.dtStartTime <> Date.MinValue OrElse SelMachGroup.dtEndTime <> Date.MinValue OrElse SelMachGroup.bReadyForMachining OrElse SelMachGroup.bSentToMachine OrElse SelMachGroup.bResetWhileCutting Then - 'MessageBox.Show("Impossibile cancellare il grezzo") - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62544)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62544)) - End If + MessageBox.Show("Impossibile cancellare il grezzo") Return End If ' rimuovo da Db il MachGroup @@ -797,12 +792,7 @@ Public Class LeftPanelVM If CurrPart Is SelMachGroup.SelPart Then Exit For ElseIf CurrPart.nProduction_State < ItemState.Produced Then - 'MessageBox.Show("It is not possible to set as done a part that has before not already produced parts.", "Error", MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62545), EgtMsg(91115), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62545), EgtMsg(91115), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show("It is not possible to set as done a part that has before not already produced parts.", "Error", MessageBoxButton.OK, MessageBoxImage.Error) Return End If Next diff --git a/EgtBEAMWALL.Supervisor/MachGroupPanel/MyMachGroupVM.vb b/EgtBEAMWALL.Supervisor/MachGroupPanel/MyMachGroupVM.vb index f8e996a5..ddbec527 100644 --- a/EgtBEAMWALL.Supervisor/MachGroupPanel/MyMachGroupVM.vb +++ b/EgtBEAMWALL.Supervisor/MachGroupPanel/MyMachGroupVM.vb @@ -1,5 +1,6 @@ Imports System.Collections.ObjectModel Imports System.IO +Imports System.Windows.Forms Imports EgtBEAMWALL.Core Imports EgtUILib Imports EgtWPFLib5 @@ -189,12 +190,7 @@ Public Class MyMachGroupVM ' creo nuova barra Dim RedoMachGroupVM As MyMachGroupVM = RedoRawPart() If IsNothing(RedoMachGroupVM) Then - 'MessageBox.Show("New RawPart creation failed!") - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62546)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62546)) - End If + MessageBox.Show("New RawPart creation failed!") Return End If ' salvo progetto con nuova barra @@ -227,13 +223,7 @@ Public Class MyMachGroupVM ' se progetto travi e lavorazione interrotta da reset If Map.refSupervisorManagerVM.CurrProd.nType = BWType.BEAM AndAlso (bResetWhileCutting OrElse dtStartTime <> DateTime.MinValue) And Not Map.refLeftPanelVM.bRestart Then ' chiedo se riprendere o rifare la barra da zero - Dim bRedo As MessageBoxResult - If bOnlyProd Then - bRedo = EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62509), "", MessageBoxButton.YesNo, MessageBoxImage.Information) - Else - bRedo = EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62509), "", MessageBoxButton.YesNo, MessageBoxImage.Information) - End If - Select Case bRedo + Select Case MessageBox.Show(Application.Current.MainWindow, EgtMsg(62509), "", MessageBoxButton.YesNo, MessageBoxImage.Information) Case MessageBoxResult.Yes ' segno da rifare pezzi non completamente lavorati For Each Part As PartVM In PartVMList @@ -284,14 +274,8 @@ Public Class MyMachGroupVM ElseIf Map.refSupervisorManagerVM.CurrProd.nType = BWType.WALL AndAlso (bResetWhileCutting OrElse dtStartTime <> DateTime.MinValue) Then If False Then ' chiedo se riprendere o rifare il pannello da zero - Dim bRedo As MessageBoxResult - If bOnlyProd Then - bRedo = EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62547), "", MessageBoxButton.YesNo, MessageBoxImage.Information) - Else - bRedo = EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62547), "", MessageBoxButton.YesNo, MessageBoxImage.Information) - End If Dim MachIndexVariable As Variable = Map.refMachCommandMessagePanelVM.MainVariablesList.FirstOrDefault(Function(x) x.sName = MACHINDEX) - Select Case bRedo + Select Case MessageBox.Show(Application.Current.MainWindow, EgtMsg(62547), "", MessageBoxButton.YesNo, MessageBoxImage.Information) ' se ripresa Case MessageBoxResult.Yes ' ripristino indice di lavorazione precedente a reset @@ -419,12 +403,7 @@ Public Class MyMachGroupVM If File.Exists(sLogPath) Then Dim LogFile As String() = File.ReadAllLines(sLogPath) If LogFile.Count >= 2 AndAlso Not IsNothing(LogFile(1)) Then - 'MessageBox.Show(LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(Application.Current.MainWindow, LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) End If End If Return Nothing diff --git a/EgtBEAMWALL.Supervisor/MachManagingThread/MachManaging.vb b/EgtBEAMWALL.Supervisor/MachManagingThread/MachManaging.vb index 6c748e66..f7827dfa 100644 --- a/EgtBEAMWALL.Supervisor/MachManagingThread/MachManaging.vb +++ b/EgtBEAMWALL.Supervisor/MachManagingThread/MachManaging.vb @@ -810,12 +810,7 @@ Public Class MachManaging bFileOk = True Catch ex As Exception m_ResultCallbackDlg(CommandTypes.START, CommandStates.ERROR_, ResultTypes.NULL, "Error in copying DEFAULT.ISO file") - 'MessageBox.Show("Impossibile copiare il file DEFAULT.ISO!", "Error", MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62548), EgtMsg(91115), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62548), EgtMsg(91115), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show("Impossibile copiare il file DEFAULT.ISO!", "Error", MessageBoxButton.OK, MessageBoxImage.Error) Return End Try End If diff --git a/EgtBEAMWALL.Supervisor/MachinePanel/MachinePanelVM.vb b/EgtBEAMWALL.Supervisor/MachinePanel/MachinePanelVM.vb index fd150846..8a20bd05 100644 --- a/EgtBEAMWALL.Supervisor/MachinePanel/MachinePanelVM.vb +++ b/EgtBEAMWALL.Supervisor/MachinePanel/MachinePanelVM.vb @@ -200,12 +200,7 @@ Public Class MachinePanelVM BeamMchsWinV.ShowDialog() Else ' Impossibile aprire l'Editor delle lavorazioni delle travi.
Mancano i file di configurazione. - Errore - 'MessageBox.Show(EgtMsg(9009), EgtMsg(9008), MessageBoxButton.OK, MessageBoxImage.Stop) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(9009), EgtMsg(9008), MessageBoxButton.OK, MessageBoxImage.Stop) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(9009), EgtMsg(9008), MessageBoxButton.OK, MessageBoxImage.Stop) - End If + MessageBox.Show(EgtMsg(9009), EgtMsg(9008), MessageBoxButton.OK, MessageBoxImage.Stop) End If Return True End Function @@ -224,12 +219,7 @@ Public Class MachinePanelVM WallMchsWinV.ShowDialog() Else ' Impossibile aprire l'Editor delle lavorazioni delle pareti.
Mancano i file di configurazione. - Errore - 'MessageBox.Show(EgtMsg(9011), EgtMsg(9008), MessageBoxButton.OK, MessageBoxImage.Stop) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(9011), EgtMsg(9008), MessageBoxButton.OK, MessageBoxImage.Stop) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(9011), EgtMsg(9008), MessageBoxButton.OK, MessageBoxImage.Stop) - End If + MessageBox.Show(EgtMsg(9011), EgtMsg(9008), MessageBoxButton.OK, MessageBoxImage.Stop) End If Return True End Function @@ -239,12 +229,7 @@ Public Class MachinePanelVM ' ricarico il database per intercettare eventuali aggiornamenti fatti da altre istanze del programma (se la cartella Machines è condivisa) If Not EgtTdbReload() Then EgtOutLog("Impossible reloading tool Db") - 'MessageBox.Show(EgtMsg(MSG_TOOLDBERRORS + 30), EgtMsg(MSG_MESSAGEBOX + 1), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(31130), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(31130), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(MSG_TOOLDBERRORS + 30), EgtMsg(MSG_MESSAGEBOX + 1), MessageBoxButton.OK, MessageBoxImage.Error) Return End If @@ -275,12 +260,7 @@ Public Class MachinePanelVM ' ricarico il database per intercettare eventuali aggiornamenti fatti da altre istanze del programma (se la cartella Machines è condivisa) If Not EgtMdbReload() Then EgtOutLog("Impossible reloading machining Db") - 'MessageBox.Show(EgtMsg(MSG_MACHININGDBERRORS + 8), EgtMsg(MSG_MESSAGEBOX + 1), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(31408), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(31408), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(MSG_MACHININGDBERRORS + 8), EgtMsg(MSG_MESSAGEBOX + 1), MessageBoxButton.OK, MessageBoxImage.Error) Return End If @@ -306,12 +286,7 @@ Public Class MachinePanelVM ' verifico che il file di configurazione attrezzaggio (lua) della macchina esista If Not File.Exists(CurrentMachine.sMachDir & "\Scripts\" & SETUP_LUA) Then EgtOutLog("SetUp error: SetUp configuration file doesn't exist ") - 'MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 7), EgtMsg(MSG_SETUPERRORS + 1), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6477), EgtMsg(6471), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6477), EgtMsg(6471), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 7), EgtMsg(MSG_SETUPERRORS + 1), MessageBoxButton.OK, MessageBoxImage.Error) Return End If ' carico Lua che contiene le funzioni per ottenere le posizioni valide dell'utensile selezionato, @@ -330,12 +305,7 @@ Public Class MachinePanelVM EgtLuaGetGlobIntVar("STU.ERR", nErr) If nErr = 0 Then If EgtGetHeadExitCount(sHead) = 0 Then - 'MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 8), EgtMsg(MSG_SETUPERRORS + 1), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6478), EgtMsg(6471), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6478), EgtMsg(6471), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 8), EgtMsg(MSG_SETUPERRORS + 1), MessageBoxButton.OK, MessageBoxImage.Error) Return End If End If diff --git a/EgtBEAMWALL.Supervisor/MainWindow/MainWindowVM.vb b/EgtBEAMWALL.Supervisor/MainWindow/MainWindowVM.vb index baba2c45..ceb2977d 100644 --- a/EgtBEAMWALL.Supervisor/MainWindow/MainWindowVM.vb +++ b/EgtBEAMWALL.Supervisor/MainWindow/MainWindowVM.vb @@ -214,12 +214,7 @@ Public Class MainWindowVM ' se macchina sta funzionando If Not IsNothing(Map.refMachManaging) AndAlso Map.refMachManaging.bConnected AndAlso (Map.refLeftPanelVM.SelOPState.Id <> OPStates.End AndAlso Map.refLeftPanelVM.SelOPState.Id <> OPStates.Unspecified) Then - 'MessageBox.Show("Impossible closing software while machine is working. If you want to close, first press reset and stop the machine!", "Error", MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtUILib.EgtMsg(62549), EgtUILib.EgtMsg(91115), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtUILib.EgtMsg(62549), EgtUILib.EgtMsg(91115), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show("Impossible closing software while machine is working. If you want to close, first press reset and stop the machine!", "Error", MessageBoxButton.OK, MessageBoxImage.Error) Return End If ' disconnetto comunicazione con macchina diff --git a/EgtBEAMWALL.Supervisor/SceneHost/MySceneHostVM.vb b/EgtBEAMWALL.Supervisor/SceneHost/MySceneHostVM.vb index fe89fc56..059c2139 100644 --- a/EgtBEAMWALL.Supervisor/SceneHost/MySceneHostVM.vb +++ b/EgtBEAMWALL.Supervisor/SceneHost/MySceneHostVM.vb @@ -4,6 +4,7 @@ Imports EgtUILib Imports EgtWPFLib5 Imports EgtBEAMWALL.Core Imports EgtBEAMWALL.DataLayer.DatabaseModels +Imports System.Windows.Forms Public Class MySceneHostVM Inherits EgtWPFLib5.SceneHostVM @@ -72,34 +73,17 @@ Public Class MySceneHostVM ' Box di avviso chiave mancante : "Chiave non presente. \n Inserirla e riavviare il programma." "Errore" Dim sText As String = EgtMsg(10102) & vbCrLf & EgtMsg(10103) Dim sTitle As String = EgtMsg(10101) - 'MessageBox.Show(sText, sTitle, MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, sText, sTitle, MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, sText, sTitle, MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(Application.Current.MainWindow, sText, sTitle, MessageBoxButton.OK, MessageBoxImage.Error) ' Altrimenti manca la licenza Else EgtOutLog("Problems with Licence") ' Box di avviso licenza con problemi : "Programma senza licenza. \n Caricala e riavvia il programma." "Errore" Dim sText As String = EgtMsg(10105) & vbCrLf & EgtMsg(10106) Dim sTitle As String = EgtMsg(10101) - Dim m_MessageBoxResult As MessageBoxResult - If bOnlyProd Then - m_MessageBoxResult = EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, sText, sTitle, MessageBoxButton.OKCancel, MessageBoxImage.Error) - Else - m_MessageBoxResult = EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, sText, sTitle, MessageBoxButton.OKCancel, MessageBoxImage.Error) - End If - If m_MessageBoxResult = MessageBoxResult.OK Then + If MessageBox.Show(Application.Current.MainWindow, sText, sTitle, MessageBoxButton.OKCancel, MessageBoxImage.Error) = MessageBoxResult.OK Then ' Apro dialogo per richiesta file licenza - 'Dim LicDlg As New Microsoft.Win32.OpenFileDialog() With { - ' .DefaultExt = ".lic", - ' .Filter = "Licences (.lic)|*.lic", - ' .CheckFileExists = True, - ' .ValidateNames = True - '} - Dim LicDlg As New EgtBEAMWALL.Core.EgtManageFileDialogV(Application.Current.MainWindow, New EgtManageFileDialogVM()) With { - .Title = EgtMsg(30006), + Dim LicDlg As New Microsoft.Win32.OpenFileDialog() With { + .DefaultExt = ".lic", .Filter = "Licences (.lic)|*.lic", .CheckFileExists = True, .ValidateNames = True @@ -272,12 +256,7 @@ Public Class MySceneHostVM EgtNewFile() Map.refMainWindowVM.SetTitle(" New - EgtBEAMWALL") Dim sMsg As String = EgtMsg(10003) & " '" & sFile & "'" 'Error opening file - 'MessageBox.Show(sMsg, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, sMsg, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, sMsg, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error - End If + MessageBox.Show(Application.Current.MainWindow, sMsg, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error End If MainScene.SetStatusNull() End Sub @@ -289,12 +268,7 @@ Public Class MySceneHostVM ' Se salvataggio non riuscito, esco subito If Not bOk Then Dim sMsg As String = EgtMsg(10004) & " '" & sFile & "'" 'Error saving file - 'MessageBox.Show(sMsg, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, sMsg, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, sMsg, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error - End If + MessageBox.Show(Application.Current.MainWindow, sMsg, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error Return End If ' Salvo nome ultimo file @@ -305,12 +279,7 @@ Public Class MySceneHostVM If nType = FT.BTL Or nType = FT.BTLX Then nFlag = GetMainPrivateProfileInt(S_IMPORT, K_BTLFLAG, EIB_FL.TS3_POS + EIB_FL.SORT + EIB_FL.USEUATTR) Else - 'MessageBox.Show(Application.Current.MainWindow, EgtMsg(10005), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' File type unknown - Error - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(10005), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' File type unknown - Error - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(10005), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' File type unknown - Error - End If + MessageBox.Show(Application.Current.MainWindow, EgtMsg(10005), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' File type unknown - Error End If End Sub diff --git a/EgtBEAMWALL.Supervisor/SupervisorManager/SupervisorManagerVM.vb b/EgtBEAMWALL.Supervisor/SupervisorManager/SupervisorManagerVM.vb index e876a460..a229e63a 100644 --- a/EgtBEAMWALL.Supervisor/SupervisorManager/SupervisorManagerVM.vb +++ b/EgtBEAMWALL.Supervisor/SupervisorManager/SupervisorManagerVM.vb @@ -185,12 +185,7 @@ Public Class SupervisorManagerVM ' se macchina connessa e non in reset If Not IsNothing(Map.refMachManaging) AndAlso Map.refLeftPanelVM.SelOPState.Id <> OPStates.End Then ' impedisco cambio progetto - 'MessageBox.Show("Press reset before changing program!!") - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62550)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62550)) - End If + MessageBox.Show("Press reset before changing program!!") Return End If Dim sFilePath As String = "" @@ -221,12 +216,7 @@ Public Class SupervisorManagerVM If CurrentMachine.sMachineName <> TempCurrProd.sMachine Then ' rimuovo il file in apertura dalla lista degli MRU m_MruFiles.Remove(sFilePath) - 'MessageBox.Show(String.Format("Impossible opening a project done with {0} in a supervisor on a {1}!", {TempCurrProd.sMachine, CurrentMachine.sMachineName}), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, String.Format(EgtMsg(62551), {TempCurrProd.sMachine, CurrentMachine.sMachineName}), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, String.Format(EgtMsg(62551), {TempCurrProd.sMachine, CurrentMachine.sMachineName}), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error - End If + MessageBox.Show(String.Format("Impossible opening a project done with {0} in a supervisor on a {1}!", {TempCurrProd.sMachine, CurrentMachine.sMachineName}), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error EgtNewFile() EgtDraw() Map.refProjectVM.ProdMachGroupPanelVM = New MyMachGroupPanelVM(MyMachGroupPanelM.CreateMyMachGroupPanel(Map.refMachinePanelVM.MachineList.ToList())) @@ -245,12 +235,7 @@ Public Class SupervisorManagerVM ' inizializzo visibilita' bottone done per i Part Map.refLeftPanelVM.NotifyPropertyChanged(NameOf(Map.refLeftPanelVM.DonePart_Visibility)) Else - 'MessageBox.Show("Impossibile aprire il file!!") - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62552)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62552)) - End If + MessageBox.Show("Impossibile aprire il file!!") Map.refSceneHostVM.MainController.NewProject() Map.refMainWindowVM.SetTitle("New - EgtBEAMWALL") m_bLoadingProd = False @@ -259,12 +244,7 @@ Public Class SupervisorManagerVM Return End If Else - 'MessageBox.Show("File non trovato!!") - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62553)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62553)) - End If + MessageBox.Show("File non trovato!!") Map.refSceneHostVM.MainController.NewProject() Map.refMainWindowVM.SetTitle("New - EgtBEAMWALL") m_bLoadingProd = False diff --git a/EgtBEAMWALL.Supervisor/Utility/DbControllers.vb b/EgtBEAMWALL.Supervisor/Utility/DbControllers.vb index f8c8e82c..3e8b77a2 100644 --- a/EgtBEAMWALL.Supervisor/Utility/DbControllers.vb +++ b/EgtBEAMWALL.Supervisor/Utility/DbControllers.vb @@ -87,12 +87,7 @@ Module DbControllers End If Catch ex As Exception EgtOutLog("InitDb error: " & ex.ToString()) - 'MessageBox.Show(Application.Current.MainWindow, "Db connection error!!", "Error") - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62554), EgtMsg(91115)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62554), EgtMsg(91115)) - End If + MessageBox.Show(Application.Current.MainWindow, "Db connection error!!", "Error") End End Try diff --git a/EgtBEAMWALL.ViewerOptimizer/AddFeatureWnd/AddFeatureWndVM.vb b/EgtBEAMWALL.ViewerOptimizer/AddFeatureWnd/AddFeatureWndVM.vb index 4c7cd87d..6a818d66 100644 --- a/EgtBEAMWALL.ViewerOptimizer/AddFeatureWnd/AddFeatureWndVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/AddFeatureWnd/AddFeatureWndVM.vb @@ -329,12 +329,7 @@ Public Class AddFeatureWndVM If Not IsNothing(m_nSelPRC) AndAlso m_nSelPRC.nPRC > 0 Then RaiseEvent m_CloseWindow(True) Else - 'MessageBox.Show(EgtMsg(61852), EgtMsg(30007)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61852), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61852), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61852), EgtMsg(30007)) End If End Sub diff --git a/EgtBEAMWALL.ViewerOptimizer/AddPartWnd/AddPartWndVM.vb b/EgtBEAMWALL.ViewerOptimizer/AddPartWnd/AddPartWndVM.vb index 3fa0fdea..18745851 100644 --- a/EgtBEAMWALL.ViewerOptimizer/AddPartWnd/AddPartWndVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/AddPartWnd/AddPartWndVM.vb @@ -165,12 +165,7 @@ Public Class AddPartWndVM Not IsNothing(m_dH) AndAlso m_dH >= 0 Then RaiseEvent m_CloseWindow(True) Else - 'MessageBox.Show(EgtMsg(61853), EgtMsg(30007)) - If EgtBEAMWALL.Core.Configuration.bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61853), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61853), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61853), EgtMsg(30007)) End If End Sub diff --git a/EgtBEAMWALL.ViewerOptimizer/AddRawPartWnd/AddRawPartWndVM.vb b/EgtBEAMWALL.ViewerOptimizer/AddRawPartWnd/AddRawPartWndVM.vb index 84ce0ad1..9d3632e5 100644 --- a/EgtBEAMWALL.ViewerOptimizer/AddRawPartWnd/AddRawPartWndVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/AddRawPartWnd/AddRawPartWndVM.vb @@ -160,12 +160,7 @@ Public Class AddRawPartWndVM For Each Variable In m_VariableList If (Variable.nType = Variable.VariableType.STRING_ AndAlso IsNothing(Variable.sValue)) OrElse ((Variable.nType = Variable.VariableType.DOUBLE_ OrElse Variable.nType = Variable.VariableType.LENGTH) AndAlso IsNothing(Variable.dValue)) Then - 'MessageBox.Show(If(m_nProjectType = MachineType.BEAM, EgtMsg(61854), EgtMsg(61855)), EgtMsg(30007)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, If(m_nProjectType = MachineType.BEAM, EgtMsg(61854), EgtMsg(61855)), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, If(m_nProjectType = MachineType.BEAM, EgtMsg(61854), EgtMsg(61855)), EgtMsg(30007)) - End If + MessageBox.Show(If(m_nProjectType = MachineType.BEAM, EgtMsg(61854), EgtMsg(61855)), EgtMsg(30007)) Return End If Next diff --git a/EgtBEAMWALL.ViewerOptimizer/AddSectionXMaterialWnd/AddSectionXMaterialWndVM.vb b/EgtBEAMWALL.ViewerOptimizer/AddSectionXMaterialWnd/AddSectionXMaterialWndVM.vb index 3c634eb2..4bf62848 100644 --- a/EgtBEAMWALL.ViewerOptimizer/AddSectionXMaterialWnd/AddSectionXMaterialWndVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/AddSectionXMaterialWnd/AddSectionXMaterialWndVM.vb @@ -191,16 +191,14 @@ Public Class AddSectionXMaterialWndVM (Not NewSectionXMaterialList(Index).Alias_IsChecked And NewSectionXMaterialList(Index).dNewL < 0) OrElse (NewSectionXMaterialList(Index).Alias_IsChecked And IsNothing(NewSectionXMaterialList(Index).SelMaterialForSameSection)) OrElse (Not NewSectionXMaterialList(Index).Alias_IsChecked And (NewSectionXMaterialList(Index).nQuantity < 0 Or NewSectionXMaterialList(Index).nQuantity > 99)) Then - 'MessageBox.Show(IncorrectValues_Msg, Error_Msg) - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValues_Msg, Error_Msg) + MessageBox.Show(IncorrectValues_Msg, Error_Msg) Return End If If Map.refProjectVM.BTLStructureVM.nPROJTYPE = MachineType.WALL AndAlso (Not NewSectionXMaterialList(Index).Alias_IsChecked And (NewSectionXMaterialList(Index).dNewW < 0 Or NewSectionXMaterialList(Index).dNewL < 0)) OrElse (NewSectionXMaterialList(Index).Alias_IsChecked And IsNothing(NewSectionXMaterialList(Index).SelMaterialForSameSection)) OrElse (Not NewSectionXMaterialList(Index).Alias_IsChecked And (NewSectionXMaterialList(Index).nQuantity < 0 Or NewSectionXMaterialList(Index).nQuantity > 99)) Then - 'MessageBox.Show(IncorrectValues_Msg, Error_Msg) - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValues_Msg, Error_Msg) + MessageBox.Show(IncorrectValues_Msg, Error_Msg) Return End If Next diff --git a/EgtBEAMWALL.ViewerOptimizer/BTLPartManager/BTLPartManagerVM.vb b/EgtBEAMWALL.ViewerOptimizer/BTLPartManager/BTLPartManagerVM.vb index 745fd28f..df73aa0e 100644 --- a/EgtBEAMWALL.ViewerOptimizer/BTLPartManager/BTLPartManagerVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/BTLPartManager/BTLPartManagerVM.vb @@ -199,22 +199,12 @@ Public Class BTLPartManagerVM If Not IsNothing(Part) Then If Map.refProjectVM.BTLStructureVM.nPROJTYPE = BWType.BEAM Then If Part.dH <> dHSection OrElse Part.dW <> dWSection Then - 'MessageBox.Show(EgtMsg(61970), EgtMsg(30007)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61970), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61970), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61970), EgtMsg(30007)) Return End If ElseIf Map.refProjectVM.BTLStructureVM.nPROJTYPE = BWType.WALL Then If Part.dH <> dHSection Then - 'MessageBox.Show(EgtMsg(61970), EgtMsg(30007)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61970), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61970), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61970), EgtMsg(30007)) Return End If End If @@ -224,12 +214,7 @@ Public Class BTLPartManagerVM Next ' se pareti e piu' di uno selezionato, esco If Map.refProjectVM.BTLStructureVM.nPROJTYPE = BWType.WALL And SelParts.Count > 1 Then - 'MessageBox.Show(EgtMsg(61971), EgtMsg(30007)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61971), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61971), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61971), EgtMsg(30007)) Return End If ' se nessun grezzo, rendo tutti i pezzi visibili @@ -289,12 +274,7 @@ Public Class BTLPartManagerVM dRawL = SParamlist(0).dL dRawW = SParamlist(0).dW Else - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61975), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61975), EgtMsg(30007)) - End If - 'MessageBox.Show(EgtMsg(61975), EgtMsg(30007)) + MessageBox.Show(EgtMsg(61975), EgtMsg(30007)) Return End If Else @@ -341,12 +321,7 @@ Public Class BTLPartManagerVM dTotLen += SelParts(PartIndex).dL Next If dTotLen > dRawL Then - 'MessageBox.Show(EgtMsg(61972), EgtMsg(30007)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61972), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61972), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61972), EgtMsg(30007)) Return End If End If @@ -399,20 +374,10 @@ Public Class BTLPartManagerVM If File.Exists(sLogPath) Then Dim LogFile As String() = File.ReadAllLines(sLogPath) If LogFile.Count >= 2 AndAlso Not IsNothing(LogFile(1)) Then - 'MessageBox.Show(LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) End If Else - 'MessageBox.Show(EgtMsg(61973), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61973), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61973), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(61973), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) End If ' se nessun grezzo, rimetto tutti i pezzi invisibili If Map.refProjectVM.MachGroupPanelVM.MachGroupVMList.Count = 0 Then @@ -453,20 +418,10 @@ Public Class BTLPartManagerVM If File.Exists(sLogPath) Then Dim LogFile As String() = File.ReadAllLines(sLogPath) If LogFile.Count >= 2 AndAlso Not IsNothing(LogFile(1)) Then - 'MessageBox.Show(LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) End If Else - 'MessageBox.Show(EgtMsg(61973), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61973), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61973), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(61973), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) End If ' se nessun grezzo, rimetto tutti i pezzi invisibili If Map.refProjectVM.MachGroupPanelVM.MachGroupVMList.Count = 0 Then @@ -606,14 +561,7 @@ Public Class BTLPartManagerVM For Each sPart In ToAddList sMessage &= " - " & sPart & Environment.NewLine Next - 'If MessageBox.Show(sMessage & EgtMsg(61893), "", MessageBoxButton.YesNo, MessageBoxImage.Question) = MessageBoxResult.Yes Then - Dim m_MessageBoxResult As MessageBoxResult - If bOnlyProd Then - m_MessageBoxResult = EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, sMessage & EgtMsg(61893), "", MessageBoxButton.YesNo, MessageBoxImage.Question) - Else - m_MessageBoxResult = EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, sMessage & EgtMsg(61893), "", MessageBoxButton.YesNo, MessageBoxImage.Question) - End If - If m_MessageBoxResult = MessageBoxResult.Yes Then + If MessageBox.Show(sMessage & EgtMsg(61893), "", MessageBoxButton.YesNo, MessageBoxImage.Question) = MessageBoxResult.Yes Then For Each PartVM In ToAddVM PartVM.AddNewPartToAdded() Next @@ -686,12 +634,7 @@ Public Class BTLPartManagerVM If IsNothing(SelMachGroup) Then Return ' se pareti e piu' di uno selezionato, esco If Map.refProjectVM.BTLStructureVM.nPROJTYPE = BWType.WALL And SelParts.Count > 1 Then - 'MessageBox.Show(EgtMsg(61971), EgtMsg(30007)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61971), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61971), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61971), EgtMsg(30007)) Return End If ' se MachGroup gia' mandato in produzione, esco @@ -710,23 +653,13 @@ Public Class BTLPartManagerVM ' verifico sezione e materiale For Each Part In SelParts If Part.Section <> BeamMachGroup.Section Then - 'MessageBox.Show(EgtMsg(61866), EgtMsg(30007)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61866), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61866), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61866), EgtMsg(30007)) Return End If Next ' verifico lunghezza totale If Not VerifyTotLength(BeamMachGroup, SelParts) Then - 'MessageBox.Show(EgtMsg(61867), EgtMsg(30007)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61867), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61867), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61867), EgtMsg(30007)) Return End If If AddPartToBeam(BeamMachGroup, SelParts) Then @@ -744,12 +677,7 @@ Public Class BTLPartManagerVM Dim WallMachGroup As MyMachGroupVM = SelMachGroup ' verifico spessore If SelPart.Section <> WallMachGroup.Section Then - 'MessageBox.Show(EgtMsg(61868), EgtMsg(30007)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61868), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61868), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61868), EgtMsg(30007)) Return End If If AddPartToWall(WallMachGroup, SelPart) Then @@ -1099,12 +1027,7 @@ Public Class BTLPartManagerVM Dim nDuploCount As Integer = 0 If EgtDuploCount(BTLPartToDelete.nPartId, nDuploCount) AndAlso nDuploCount > 0 Then ' avviso che il pezzo non è cancellabile perchè in produzione - 'MessageBox.Show(String.Format(EgtMsg(61929), nDuploCount), EgtMsg(15003), MessageBoxButton.OK, MessageBoxImage.Warning) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, String.Format(EgtMsg(61929), nDuploCount), EgtMsg(15003), MessageBoxButton.OK, MessageBoxImage.Warning) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, String.Format(EgtMsg(61929), nDuploCount), EgtMsg(15003), MessageBoxButton.OK, MessageBoxImage.Warning) - End If + MessageBox.Show(String.Format(EgtMsg(61929), nDuploCount), EgtMsg(15003), MessageBoxButton.OK, MessageBoxImage.Warning) Return End If ' verifico se rimuovere sezione dalla lista diff --git a/EgtBEAMWALL.ViewerOptimizer/BTLViewModel/BTLParamVM.vb b/EgtBEAMWALL.ViewerOptimizer/BTLViewModel/BTLParamVM.vb index 96bd57fc..64d00fb4 100644 --- a/EgtBEAMWALL.ViewerOptimizer/BTLViewModel/BTLParamVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/BTLViewModel/BTLParamVM.vb @@ -130,12 +130,7 @@ Public Class BTLParamVM Case BTLParamType.DOUBLE_, BTLParamType.LENGTH ' verifico che sia compreso tra minimo e massimo If dNewValue < m_BTLParamM.dMin OrElse dNewValue > m_BTLParamM.dMax Then - 'MessageBox.Show(EgtMsg(61856), EgtMsg(30007)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61856), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61856), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61856), EgtMsg(30007)) NotifyPropertyChanged(NameOf(sValue)) Return End If @@ -150,19 +145,9 @@ Public Class BTLParamVM Dim nDoneCnt As Integer = DbControllers.m_ProjController.getCountItemState(ProjectManagerVM.CurrProj.nProjId, nPartId, ItemState.Assigned) ' controllo se i pezzi sono lavorati se si messaggio di warning altrimenti messaggio informativo If nDoneCnt > 0 Then - 'MessageBox.Show("Pezzo " & nPartId & " non modificato in " & INPROD & " barra/e perche' settata/e come da produrre", EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62555) & nPartId & EgtMsg(62556) & INPROD & EgtMsg(62557), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62555) & nPartId & EgtMsg(62556) & INPROD & EgtMsg(62557), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) - End If + MessageBox.Show("Pezzo " & nPartId & " non modificato in " & INPROD & " barra/e perche' settata/e come da produrre", EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) ElseIf INPROD > 0 Then - 'MessageBox.Show("Pezzo " & nPartId & " modificato in " & INPROD & " barra/e grezza/e", EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Information) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62555) & nPartId & EgtMsg(62558) & INPROD & EgtMsg(62559), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Information) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62555) & nPartId & EgtMsg(62558) & INPROD & EgtMsg(62559), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Information) - End If + MessageBox.Show("Pezzo " & nPartId & " modificato in " & INPROD & " barra/e grezza/e", EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Information) End If UpdateParamValue(dNewValue, "") Case Else @@ -207,12 +192,7 @@ Public Class BTLParamVM Case BTLParamType.DOUBLE_, BTLParamType.LENGTH ' verifico che sia compreso tra minimo e massimo If dNewValue < m_BTLParamM.dMin OrElse dNewValue > m_BTLParamM.dMax Then - 'MessageBox.Show(EgtMsg(61856), EgtMsg(30007)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61856), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61856), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61856), EgtMsg(30007)) NotifyPropertyChanged(NameOf(sDefault)) Return End If diff --git a/EgtBEAMWALL.ViewerOptimizer/BTLViewModel/BTLPartVM.vb b/EgtBEAMWALL.ViewerOptimizer/BTLViewModel/BTLPartVM.vb index f4a0a847..5fc17ce8 100644 --- a/EgtBEAMWALL.ViewerOptimizer/BTLViewModel/BTLPartVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/BTLViewModel/BTLPartVM.vb @@ -93,12 +93,7 @@ Public Class BTLPartVM End If Next If bDuploInProduction Then - 'MessageBox.Show("Impossible change dimension because already in production!", "", MessageBoxButton.OK, MessageBoxImage.Exclamation) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, "Impossible change dimension because already in production!", "", MessageBoxButton.OK, MessageBoxImage.Exclamation) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, "Impossible change dimension because already in production!", "", MessageBoxButton.OK, MessageBoxImage.Exclamation) - End If + MessageBox.Show("Impossible change dimension because already in production!", "", MessageBoxButton.OK, MessageBoxImage.Exclamation) Return False End If ' lo impedisco @@ -1163,12 +1158,7 @@ Public Class BTLPartVM If nTempADDED >= nINPROD Then m_BTLPartM.nADDED = nTempADDED Else - 'MessageBox.Show(EgtMsg(61857), "", MessageBoxButton.OK, MessageBoxImage.Warning) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61857), "", MessageBoxButton.OK, MessageBoxImage.Warning) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61857), "", MessageBoxButton.OK, MessageBoxImage.Warning) - End If + MessageBox.Show(EgtMsg(61857), "", MessageBoxButton.OK, MessageBoxImage.Warning) End If End If NotifyPropertyChanged(NameOf(sADDED)) diff --git a/EgtBEAMWALL.ViewerOptimizer/CALCPanel/CALCPanelVM.vb b/EgtBEAMWALL.ViewerOptimizer/CALCPanel/CALCPanelVM.vb index 5f5fcac9..c4760a85 100644 --- a/EgtBEAMWALL.ViewerOptimizer/CALCPanel/CALCPanelVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/CALCPanel/CALCPanelVM.vb @@ -243,12 +243,7 @@ Public Class CALCPanelVM Private Sub Calc_Ended(sender As Object, e As CalcEndEventArgs) If e.End_ = CalcEndEventArgs.Results.ERROR_ OrElse e.End_ = CalcEndEventArgs.Results.NULL Then - 'MessageBox.Show("Execution error (all processes are disabled)") - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62540)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62540)) - End If + MessageBox.Show("Execution error (all processes are disabled)") End If If e.End_ = CalcEndEventArgs.Results.EDIT Then Map.refMyStatusBarVM.SetOutputMessage("Editor closed") @@ -1126,12 +1121,7 @@ Public Class CALCPanelVM Friend Sub ChooseMachine() ' rendo visibile la CmBx per la scelta e il pulsante di conferma solo se il Proj corrente non ha associato alcun Prod If ProjectManagerVM.CurrProj.nProdId > 0 AndAlso Map.refMainMenuVM.SelPage <> Pages.ONLYPRODPAGE Then - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61929), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Exclamation) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61929), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Exclamation) - End If - 'MessageBox.Show(EgtMsg(61929), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Exclamation) + MessageBox.Show(EgtMsg(61929), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Exclamation) Else SetChooseMachine_Visibility(True) End If diff --git a/EgtBEAMWALL.ViewerOptimizer/ChangeMaterialWnd/ChangeMaterialWndVM.vb b/EgtBEAMWALL.ViewerOptimizer/ChangeMaterialWnd/ChangeMaterialWndVM.vb index 47bd3a6e..c7d3d71d 100644 --- a/EgtBEAMWALL.ViewerOptimizer/ChangeMaterialWnd/ChangeMaterialWndVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/ChangeMaterialWnd/ChangeMaterialWndVM.vb @@ -129,12 +129,7 @@ Public Class ChangeMaterialWndVM Not IsNothing(m_SelWhMaterial) AndAlso m_SelWhMaterial <> "" Then RaiseEvent m_CloseWindow(True) Else - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61858), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61858), EgtMsg(30007)) - End If - 'MessageBox.Show(EgtMsg(61858), EgtMsg(30007)) + MessageBox.Show(EgtMsg(61858), EgtMsg(30007)) End If End Sub diff --git a/EgtBEAMWALL.ViewerOptimizer/ChangeParameterWnd/ChangeParameterWndVM.vb b/EgtBEAMWALL.ViewerOptimizer/ChangeParameterWnd/ChangeParameterWndVM.vb index 5b993418..7c17752b 100644 --- a/EgtBEAMWALL.ViewerOptimizer/ChangeParameterWnd/ChangeParameterWndVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/ChangeParameterWnd/ChangeParameterWndVM.vb @@ -108,12 +108,7 @@ Public Class ChangeParameterWndVM Not IsNothing(m_SelParam) AndAlso m_SelParam.sName <> "" Then RaiseEvent m_CloseWindow(True) Else - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61858), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61858), EgtMsg(30007)) - End If - 'MessageBox.Show(EgtMsg(61858), EgtMsg(30007)) + MessageBox.Show(EgtMsg(61858), EgtMsg(30007)) End If End Sub diff --git a/EgtBEAMWALL.ViewerOptimizer/ConfigurationPage/ConfigurationPageVM.vb b/EgtBEAMWALL.ViewerOptimizer/ConfigurationPage/ConfigurationPageVM.vb index 100a860d..b9fe1ea5 100644 --- a/EgtBEAMWALL.ViewerOptimizer/ConfigurationPage/ConfigurationPageVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/ConfigurationPage/ConfigurationPageVM.vb @@ -698,29 +698,13 @@ Public Class ConfigurationPageVM ''' Execute the Save. This method is invoked by the SaveCommand. ''' Public Sub ChooseExternalBackupFolderPath() - 'Dim FileDialog As New Microsoft.Win32.SaveFileDialog() With {.InitialDirectory = m_ExternalBackupFolderPath, - ' .CheckFileExists = False, - ' .CheckPathExists = False, - ' .DefaultExt = ".folder", - ' .OverwritePrompt = False, - ' .FileName = "Select this ", - ' .Title = "Backup & Restore File Path"} - Dim FileDialog As Object - If bOnlyProd Then - FileDialog = New EgtBEAMWALL.Core.OnlyProdEgtManageFileDialogV(Application.Current.MainWindow, New EgtManageFileDialogVM()) With { - .CheckFileExists = False, - .OverwritePrompt = False, - .FileName = "Select this ", - .Title = "Backup & Restore File Path" - } - Else - FileDialog = New EgtBEAMWALL.Core.EgtManageFileDialogV(Application.Current.MainWindow, New EgtManageFileDialogVM()) With { - .CheckFileExists = False, - .OverwritePrompt = False, - .FileName = "Select this ", - .Title = "Backup & Restore File Path" - } - End If + Dim FileDialog As New Microsoft.Win32.SaveFileDialog() With {.InitialDirectory = m_ExternalBackupFolderPath, + .CheckFileExists = False, + .CheckPathExists = False, + .DefaultExt = ".folder", + .OverwritePrompt = False, + .FileName = "Select this ", + .Title = "Backup & Restore File Path"} If FileDialog.ShowDialog() Then m_ExternalBackupFolderPath = Path.GetDirectoryName(FileDialog.FileName) WriteMainPrivateProfileString(S_BACKUPANDRESTORE, K_EXTERNALFILEPATH, m_ExternalBackupFolderPath) @@ -810,12 +794,7 @@ Public Class ConfigurationPageVM Try DataLayer.DbConfig.DataBaseDumpToFile(sBackupZipPath) Catch ex As Exception - 'MessageBox.Show(EgtMsg(62103), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62103), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62103), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(62103), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) bOk = False End Try If bOk AndAlso File.Exists(sBackupZipPath) Then @@ -843,12 +822,7 @@ Public Class ConfigurationPageVM zip.Save() End Using Catch ex As Exception - 'MessageBox.Show(EgtMsg(62103), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62103), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62103), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(62103), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) bOk = False End Try End If @@ -861,12 +835,7 @@ Public Class ConfigurationPageVM If Directory.Exists(m_ExternalBackupFolderPath) Then CopyForExternalBackup(sBackupFolder, m_ExternalBackupFolderPath) Else - 'MessageBox.Show(EgtMsg(62104), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) ' External folder does not exist or is not reachable! Copy to external folder impossible! - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62104), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) ' External folder does not exist or is not reachable! Copy to external folder impossible! - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62104), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) ' External folder does not exist or is not reachable! Copy to external folder impossible! - End If + MessageBox.Show(EgtMsg(62104), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) ' External folder does not exist or is not reachable! Copy to external folder impossible! End If End If 'chiudo finestra di caricamento @@ -908,12 +877,7 @@ Public Class ConfigurationPageVM Dim localProc As Process() = Process.GetProcessesByName(sSupervisorName) ' verifico che sia chiuso If localProc.Length > 0 Then - 'MessageBox.Show(EgtMsg(62105), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) ' Please verify the machine is stoped and close the supervisor before proceding with the restore operation! - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62105), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) ' Please verify the machine is stoped and close the supervisor before proceding with the restore operation! - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62105), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) ' Please verify the machine is stoped and close the supervisor before proceding with the restore operation! - End If + MessageBox.Show(EgtMsg(62105), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) ' Please verify the machine is stoped and close the supervisor before proceding with the restore operation! Return End If m_bRestoreRunning = True @@ -952,44 +916,20 @@ Public Class ConfigurationPageVM Next End If If String.IsNullOrEmpty(sRestorePath) Then - 'MessageBox.Show(EgtMsg(62106), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) ' Restore impossible! Last backup not found! - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62106), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) ' Restore impossible! Last backup not found! - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62106), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) ' Restore impossible! Last backup not found! - End If + MessageBox.Show(EgtMsg(62106), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) ' Restore impossible! Last backup not found! End If - 'If MessageBox.Show(String.Format(EgtMsg(62107), nYear, nMonth, nDay), EgtMsg(15002), MessageBoxButton.OKCancel, MessageBoxImage.Warning) <> MessageBoxResult.OK Then 'Are you sure you want to restore the last backup from {0}\{1}\{2}? If you proceed you will lose actual data! - Dim m_MessageBoxResult As MessageBoxResult - If bOnlyProd Then - m_MessageBoxResult = EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, String.Format(EgtMsg(62107), nYear, nMonth, nDay), EgtMsg(15002), MessageBoxButton.OKCancel, MessageBoxImage.Warning) - Else - m_MessageBoxResult = EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, String.Format(EgtMsg(62107), nYear, nMonth, nDay), EgtMsg(15002), MessageBoxButton.OKCancel, MessageBoxImage.Warning) - End If - If m_MessageBoxResult <> MessageBoxResult.OK Then 'Are you sure you want to restore the last backup from {0}\{1}\{2}? If you proceed you will lose actual data! + If MessageBox.Show(String.Format(EgtMsg(62107), nYear, nMonth, nDay), EgtMsg(15002), MessageBoxButton.OKCancel, MessageBoxImage.Warning) <> MessageBoxResult.OK Then 'Are you sure you want to restore the last backup from {0}\{1}\{2}? If you proceed you will lose actual data! m_bRestoreRunning = False Return End If Dim bDoBackup = False - 'Select Case MessageBox.Show(EgtMsg(62108), EgtMsg(15003), MessageBoxButton.YesNoCancel, MessageBoxImage.Information) ' Do you want to do a backup of the current project before proceding with the restore? - Dim m_MessageBoxResultCase As MessageBoxResult - If bOnlyProd Then - m_MessageBoxResultCase = EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62108), EgtMsg(15003), MessageBoxButton.YesNoCancel, MessageBoxImage.Information) - Else - m_MessageBoxResultCase = EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62108), EgtMsg(15003), MessageBoxButton.YesNoCancel, MessageBoxImage.Information) - End If - Select Case m_MessageBoxResultCase ' Do you want to do a backup of the current project before proceding with the restore? + Select Case MessageBox.Show(EgtMsg(62108), EgtMsg(15003), MessageBoxButton.YesNoCancel, MessageBoxImage.Information) ' Do you want to do a backup of the current project before proceding with the restore? Case MessageBoxResult.Yes bDoBackup = True Case MessageBoxResult.No bDoBackup = False Case MessageBoxResult.Cancel - 'MessageBox.Show(EgtMsg(62109), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62109), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62109), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) - End If + MessageBox.Show(EgtMsg(62109), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) m_bRestoreRunning = False Return End Select @@ -1028,12 +968,7 @@ Public Class ConfigurationPageVM Catch ex1 As Exception EgtOutLog("Error! Impossible importing Recovery file " & sRestorePath & "!") EgtOutLog("Exception in zip: " & ex1.ToString()) - 'MessageBox.Show(EgtMsg(62110), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) ' Impossible importing Recovery file! - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62110), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) ' Impossible importing Recovery file! - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62110), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) ' Impossible importing Recovery file! - End If + MessageBox.Show(EgtMsg(62110), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) ' Impossible importing Recovery file! bOk = False End Try Dim sBackupTempPath As String = Map.refMainWindowVM.MainWindowM.sTempDir & "\DbRestore" @@ -1043,12 +978,7 @@ Public Class ConfigurationPageVM Try DataLayer.DbConfig.DataBaseRestoreFromFile(sRestoreDir & "\DbBackup.zip", "", sBackupTempPath) Catch ex As Exception - 'MessageBox.Show(EgtMsg(62111), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) ' Restore failed! Impossible to restore the backup Database - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62111), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) ' Restore failed! Impossible to restore the backup Database - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62111), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) ' Restore failed! Impossible to restore the backup Database - End If + MessageBox.Show(EgtMsg(62111), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) ' Restore failed! Impossible to restore the backup Database bOk = False End Try End If @@ -1153,12 +1083,7 @@ Public Class ConfigurationPageVM Dim MachParamString As String = sMachParamType & "," & MachParamItem.sName & "," & MachParamItem.sValue & "," & MachParamItem.sDescription Dim bOk = WriteMachPrivateProfileString(MachParamItem.nParentTable, MachParamItem.nParamIndex, MachParamString) If Not bOk Then - 'MessageBox.Show(EgtMsg(61859), EgtMsg(30007)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61859), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61859), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61859), EgtMsg(30007)) Return End If MachParamItem.IsModifiedReset() diff --git a/EgtBEAMWALL.ViewerOptimizer/FeatureListManager/FeatureListManagerVM.vb b/EgtBEAMWALL.ViewerOptimizer/FeatureListManager/FeatureListManagerVM.vb index 10c6e30d..3ba89550 100644 --- a/EgtBEAMWALL.ViewerOptimizer/FeatureListManager/FeatureListManagerVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/FeatureListManager/FeatureListManagerVM.vb @@ -135,12 +135,7 @@ Public Class FeatureListManagerVM ' Reset lua EgtLuaResetGlobVar("MACRO") If Not bOk Then - 'MessageBox.Show(EgtMsg(61869), EgtMsg(30007)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61869), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61869), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61869), EgtMsg(30007)) Return End If bMacroFlag = True diff --git a/EgtBEAMWALL.ViewerOptimizer/FreeContourManager/FreeContourManagerVM.vb b/EgtBEAMWALL.ViewerOptimizer/FreeContourManager/FreeContourManagerVM.vb index 9c056804..0a733163 100644 --- a/EgtBEAMWALL.ViewerOptimizer/FreeContourManager/FreeContourManagerVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/FreeContourManager/FreeContourManagerVM.vb @@ -83,14 +83,7 @@ Public Class FreeContourManagerVM NotifyPropertyChanged(NameOf(TextAngle_Visibility)) Case FreeContourTypes.TWO ' chiedo conferma - Dim m_MessageBoxResult As MessageBoxResult - If bOnlyProd Then - m_MessageBoxResult = EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61862), "", MessageBoxButton.YesNo, MessageBoxImage.Warning) - Else - m_MessageBoxResult = EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61862), "", MessageBoxButton.YesNo, MessageBoxImage.Warning) - End If - 'If MessageBox.Show(EgtMsg(61862), "", MessageBoxButton.YesNo, MessageBoxImage.Warning) <> MessageBoxResult.Yes Then - If m_MessageBoxResult <> MessageBoxResult.Yes Then + If MessageBox.Show(EgtMsg(61862), "", MessageBoxButton.YesNo, MessageBoxImage.Warning) <> MessageBoxResult.Yes Then m_SelType = FreeContourTypes.TWO NotifyPropertyChanged(NameOf(SelType)) Return diff --git a/EgtBEAMWALL.ViewerOptimizer/ItemParamList/BTLPartListV.xaml b/EgtBEAMWALL.ViewerOptimizer/ItemParamList/BTLPartListV.xaml index 30726016..b52cee90 100644 --- a/EgtBEAMWALL.ViewerOptimizer/ItemParamList/BTLPartListV.xaml +++ b/EgtBEAMWALL.ViewerOptimizer/ItemParamList/BTLPartListV.xaml @@ -20,10 +20,6 @@ PreviewMouseUp="DataGrid_PreviewMouseUp" PreviewMouseMove="DataGrid_PreviewMouseMove" Margin="0,0,0,5" - ColumnHeaderBackground="{DynamicResource {x:Static SystemColors.ControlBrushKey}}" - ColumnHeaderForeground="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" - ColumnHeaderFontWeight="Normal" - ColumnHeaderPadding="0,2,0,2" EgtBEAMWALL:MultiSelectorBehaviours.SynchronizedSelectedItems="{Binding Tag.SelBTLParts, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BTLPartListV}}}" BindingColumns="{Binding PartColumns}" diff --git a/EgtBEAMWALL.ViewerOptimizer/ItemParamList/FeatureInPartInRawPartListV.xaml b/EgtBEAMWALL.ViewerOptimizer/ItemParamList/FeatureInPartInRawPartListV.xaml index 01a32011..75a97bb9 100644 --- a/EgtBEAMWALL.ViewerOptimizer/ItemParamList/FeatureInPartInRawPartListV.xaml +++ b/EgtBEAMWALL.ViewerOptimizer/ItemParamList/FeatureInPartInRawPartListV.xaml @@ -16,7 +16,7 @@ ScrollViewer.VerticalScrollBarVisibility="Auto" ScrollViewer.HorizontalScrollBarVisibility="Auto" Margin="0,0,0,5" - ColumnHeaderBackground="{DynamicResource {x:Static SystemColors.ControlBrushKey}}" + ColumnHeaderBackground="{StaticResource DataGrid.Static.Background}" ColumnHeaderForeground="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" ColumnHeaderFontWeight="Normal" ColumnHeaderPadding="0,2,0,2" diff --git a/EgtBEAMWALL.ViewerOptimizer/ItemParamList/FeatureListV.xaml b/EgtBEAMWALL.ViewerOptimizer/ItemParamList/FeatureListV.xaml index 83d58d07..aff15670 100644 --- a/EgtBEAMWALL.ViewerOptimizer/ItemParamList/FeatureListV.xaml +++ b/EgtBEAMWALL.ViewerOptimizer/ItemParamList/FeatureListV.xaml @@ -16,7 +16,7 @@ ScrollViewer.VerticalScrollBarVisibility="Auto" ScrollViewer.HorizontalScrollBarVisibility="Auto" Margin="0,0,0,5" - ColumnHeaderBackground="{DynamicResource {x:Static SystemColors.ControlBrushKey}}" + ColumnHeaderBackground="{StaticResource DataGrid.Static.Background}" ColumnHeaderForeground="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" ColumnHeaderFontWeight="Normal" ColumnHeaderPadding="0,2,0,2" diff --git a/EgtBEAMWALL.ViewerOptimizer/ItemParamList/PParameterListV.xaml b/EgtBEAMWALL.ViewerOptimizer/ItemParamList/PParameterListV.xaml index b848d544..bca169ff 100644 --- a/EgtBEAMWALL.ViewerOptimizer/ItemParamList/PParameterListV.xaml +++ b/EgtBEAMWALL.ViewerOptimizer/ItemParamList/PParameterListV.xaml @@ -12,7 +12,7 @@ ScrollViewer.VerticalScrollBarVisibility="Auto" ScrollViewer.HorizontalScrollBarVisibility="Auto" Margin="0,0,0,5" - ColumnHeaderBackground="{DynamicResource {x:Static SystemColors.ControlBrushKey}}" + ColumnHeaderBackground="{StaticResource DataGrid.Static.Background}" ColumnHeaderForeground="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" ColumnHeaderFontWeight="Normal" ColumnHeaderPadding="0,2,0,2" diff --git a/EgtBEAMWALL.ViewerOptimizer/ItemParamList/PartInRawPartListV.xaml b/EgtBEAMWALL.ViewerOptimizer/ItemParamList/PartInRawPartListV.xaml index c223b21f..2de81c33 100644 --- a/EgtBEAMWALL.ViewerOptimizer/ItemParamList/PartInRawPartListV.xaml +++ b/EgtBEAMWALL.ViewerOptimizer/ItemParamList/PartInRawPartListV.xaml @@ -18,7 +18,7 @@ ScrollViewer.VerticalScrollBarVisibility="Auto" ScrollViewer.HorizontalScrollBarVisibility="Auto" Margin="0,0,0,5" - ColumnHeaderBackground="{DynamicResource {x:Static SystemColors.ControlBrushKey}}" + ColumnHeaderBackground="{StaticResource DataGrid.Static.Background}" ColumnHeaderForeground="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" ColumnHeaderFontWeight="Normal" ColumnHeaderPadding="0,2,0,2" diff --git a/EgtBEAMWALL.ViewerOptimizer/ItemParamList/QParameterListV.xaml b/EgtBEAMWALL.ViewerOptimizer/ItemParamList/QParameterListV.xaml index 51ddf384..632a6853 100644 --- a/EgtBEAMWALL.ViewerOptimizer/ItemParamList/QParameterListV.xaml +++ b/EgtBEAMWALL.ViewerOptimizer/ItemParamList/QParameterListV.xaml @@ -12,7 +12,7 @@ ScrollViewer.VerticalScrollBarVisibility="Auto" ScrollViewer.HorizontalScrollBarVisibility="Auto" Margin="0,0,0,5" - ColumnHeaderBackground="{DynamicResource {x:Static SystemColors.ControlBrushKey}}" + ColumnHeaderBackground="{StaticResource DataGrid.Static.Background}" ColumnHeaderForeground="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" ColumnHeaderFontWeight="Normal" ColumnHeaderPadding="0,2,0,2" diff --git a/EgtBEAMWALL.ViewerOptimizer/ItemParamList/RawPartListV.xaml b/EgtBEAMWALL.ViewerOptimizer/ItemParamList/RawPartListV.xaml index 5b891547..2f6a2260 100644 --- a/EgtBEAMWALL.ViewerOptimizer/ItemParamList/RawPartListV.xaml +++ b/EgtBEAMWALL.ViewerOptimizer/ItemParamList/RawPartListV.xaml @@ -16,7 +16,7 @@ ScrollViewer.VerticalScrollBarVisibility="Auto" ScrollViewer.HorizontalScrollBarVisibility="Auto" Margin="0,0,0,5" - ColumnHeaderBackground="{DynamicResource {x:Static SystemColors.ControlBrushKey}}" + ColumnHeaderBackground="{StaticResource DataGrid.Static.Background}" ColumnHeaderForeground="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" ColumnHeaderFontWeight="Normal" ColumnHeaderPadding="0,2,0,2" diff --git a/EgtBEAMWALL.ViewerOptimizer/MachGroupPanel/MyMachGroupVM.vb b/EgtBEAMWALL.ViewerOptimizer/MachGroupPanel/MyMachGroupVM.vb index c0c8a7b9..d12864c1 100644 --- a/EgtBEAMWALL.ViewerOptimizer/MachGroupPanel/MyMachGroupVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/MachGroupPanel/MyMachGroupVM.vb @@ -388,12 +388,7 @@ Public Class MyMachGroupVM BeamWallMachGroup.DeleteMachGroup() Dim LogFile As String() = File.ReadAllLines(sLogPath) If LogFile.Count >= 2 AndAlso Not IsNothing(LogFile(1)) Then - 'MessageBox.Show(LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) End If Return Nothing End If @@ -470,12 +465,7 @@ Public Class MyMachGroupVM BeamWallMachGroup.DeleteMachGroup() Dim LogFile As String() = File.ReadAllLines(sLogPath) If LogFile.Count >= 2 AndAlso Not IsNothing(LogFile(1)) Then - 'MessageBox.Show(LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) End If Return Nothing End If @@ -578,14 +568,7 @@ Public Class MyMachGroupVM Next sPartToAdd &= Environment.NewLine & "Aggiungerli?" If bPartToAdd Then - 'If MessageBox.Show(sPartToAdd, "", MessageBoxButton.YesNo, MessageBoxImage.Question) = MessageBoxResult.Yes Then - Dim m_MessageBoxResult As MessageBoxResult - If bOnlyProd Then - m_MessageBoxResult = EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, sPartToAdd, "", MessageBoxButton.YesNo, MessageBoxImage.Question) - Else - m_MessageBoxResult = EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, sPartToAdd, "", MessageBoxButton.YesNo, MessageBoxImage.Question) - End If - If m_MessageBoxResult = MessageBoxResult.Yes Then + If MessageBox.Show(sPartToAdd, "", MessageBoxButton.YesNo, MessageBoxImage.Question) = MessageBoxResult.Yes Then For Each Part In SelParts If Not Part.CanAddPartToCount() Then Part.AddNewPartToAdded() Next diff --git a/EgtBEAMWALL.ViewerOptimizer/MachinePanel/MachinePanelVM.vb b/EgtBEAMWALL.ViewerOptimizer/MachinePanel/MachinePanelVM.vb index 486466e5..79084ac5 100644 --- a/EgtBEAMWALL.ViewerOptimizer/MachinePanel/MachinePanelVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/MachinePanel/MachinePanelVM.vb @@ -219,12 +219,7 @@ Public Class MachinePanelVM BeamMchsWinV.ShowDialog() Else ' Impossibile aprire l'Editor delle lavorazioni delle travi.
Mancano i file di configurazione. - Errore - 'MessageBox.Show(EgtMsg(9009), EgtMsg(9008), MessageBoxButton.OK, MessageBoxImage.Stop) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(9009), EgtMsg(9008), MessageBoxButton.OK, MessageBoxImage.Stop) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(9009), EgtMsg(9008), MessageBoxButton.OK, MessageBoxImage.Stop) - End If + MessageBox.Show(EgtMsg(9009), EgtMsg(9008), MessageBoxButton.OK, MessageBoxImage.Stop) End If Return True End Function @@ -248,12 +243,7 @@ Public Class MachinePanelVM WallMchsWinV.ShowDialog() Else ' Impossibile aprire l'Editor delle lavorazioni delle pareti.
Mancano i file di configurazione. - Errore - 'MessageBox.Show(EgtMsg(9011), EgtMsg(9008), MessageBoxButton.OK, MessageBoxImage.Stop) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(9011), EgtMsg(9008), MessageBoxButton.OK, MessageBoxImage.Stop) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(9011), EgtMsg(9008), MessageBoxButton.OK, MessageBoxImage.Stop) - End If + MessageBox.Show(EgtMsg(9011), EgtMsg(9008), MessageBoxButton.OK, MessageBoxImage.Stop) End If Return True End Function @@ -263,12 +253,7 @@ Public Class MachinePanelVM ' ricarico il database per intercettare eventuali aggiornamenti fatti da altre istanze del programma (se la cartella Machines è condivisa) If Not EgtTdbReload() Then EgtOutLog("Impossible reloading tool Db") - 'MessageBox.Show(EgtMsg(MSG_TOOLDBERRORS + 30), EgtMsg(MSG_MESSAGEBOX + 1), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(31130), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(31130), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(MSG_TOOLDBERRORS + 30), EgtMsg(MSG_MESSAGEBOX + 1), MessageBoxButton.OK, MessageBoxImage.Error) Return End If @@ -294,12 +279,7 @@ Public Class MachinePanelVM ' ricarico il database per intercettare eventuali aggiornamenti fatti da altre istanze del programma (se la cartella Machines è condivisa) If Not EgtMdbReload() Then EgtOutLog("Impossible reloading machining Db") - 'MessageBox.Show(EgtMsg(MSG_MACHININGDBERRORS + 8), EgtMsg(MSG_MESSAGEBOX + 1), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(31408), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(31408), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(MSG_MACHININGDBERRORS + 8), EgtMsg(MSG_MESSAGEBOX + 1), MessageBoxButton.OK, MessageBoxImage.Error) Return End If Dim MachDbWindowVM As New EgtWPFLib5.MachiningDbWindowVM(CurrentMachine.sMachIniFile, Map.refSceneHostVM.MainScene.GetCtx(), "Stone") @@ -323,12 +303,7 @@ Public Class MachinePanelVM ' verifico che il file di configurazione attrezzaggio (lua) della macchina esista If Not File.Exists(CurrentMachine.sMachDir & "\Scripts\" & SETUP_LUA) Then EgtOutLog("SetUp error: SetUp configuration file doesn't exist ") - 'MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 7), EgtMsg(MSG_SETUPERRORS + 1), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6477), EgtMsg(6471), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6477), EgtMsg(6471), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 7), EgtMsg(MSG_SETUPERRORS + 1), MessageBoxButton.OK, MessageBoxImage.Error) Return End If ' carico Lua che contiene le funzioni per ottenere le posizioni valide dell'utensile selezionato, @@ -347,12 +322,7 @@ Public Class MachinePanelVM EgtLuaGetGlobIntVar("STU.ERR", nErr) If nErr = 0 Then If EgtGetHeadExitCount(sHead) = 0 Then - 'MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 8), EgtMsg(MSG_SETUPERRORS + 1), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6478), EgtMsg(6471), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6478), EgtMsg(6471), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 8), EgtMsg(MSG_SETUPERRORS + 1), MessageBoxButton.OK, MessageBoxImage.Error) Return End If End If diff --git a/EgtBEAMWALL.ViewerOptimizer/MacroFeatureWnd/MacroFeatureWndVM.vb b/EgtBEAMWALL.ViewerOptimizer/MacroFeatureWnd/MacroFeatureWndVM.vb index 60aed00e..6a10ad70 100644 --- a/EgtBEAMWALL.ViewerOptimizer/MacroFeatureWnd/MacroFeatureWndVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/MacroFeatureWnd/MacroFeatureWndVM.vb @@ -132,12 +132,7 @@ Public Class MacroFeatureWndVM WriteMacro(sFeatureName) RaiseEvent m_CloseWindow(True) Else - 'MessageBox.Show(EgtMsg(61870), EgtMsg(30007)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61870), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61870), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61870), EgtMsg(30007)) End If End Sub diff --git a/EgtBEAMWALL.ViewerOptimizer/MainMenu/MainMenuVM.vb b/EgtBEAMWALL.ViewerOptimizer/MainMenu/MainMenuVM.vb index 13b730d2..e478e17f 100644 --- a/EgtBEAMWALL.ViewerOptimizer/MainMenu/MainMenuVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/MainMenu/MainMenuVM.vb @@ -471,12 +471,7 @@ Public Class MainMenuVM ' seleziono prima barra Map.refProjectVM.MachGroupPanelVM.SelFirstMachGroup() Else - 'MessageBox.Show(EgtMsg(61871)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61871)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61871)) - End If + MessageBox.Show(EgtMsg(61871)) End If Else Map.refSceneHostVM.MainController.NewProject() @@ -701,12 +696,7 @@ Public Class MainMenuVM ' seleziono prima barra Map.refProjectVM.MachGroupPanelVM.SelFirstMachGroup() Else - 'MessageBox.Show(EgtMsg(61871)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61871)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61871)) - End If + MessageBox.Show(EgtMsg(61871)) End If Else Map.refSceneHostVM.MainController.NewProject() @@ -817,12 +807,7 @@ Public Class MainMenuVM ''' Public Sub SendFeedback(ByVal param As Object) If (SelPage = Pages.MACHINING OrElse SelPage = Pages.ONLYPRODPAGE) AndAlso IsNothing(ProjectManagerVM.CurrProd) Then - 'MessageBox.Show(EgtMsg(61891), EgtMsg(MSG_MESSAGEBOX + 1), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61891), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61891), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(61891), EgtMsg(MSG_MESSAGEBOX + 1), MessageBoxButton.OK, MessageBoxImage.Error) Return End If ' Recupero indirizzo a cui spedire la mail @@ -830,12 +815,7 @@ Public Class MainMenuVM GetMainPrivateProfileString(S_GENERAL, K_SUPPORT, "support@egaltech.com", sSupportAddress) ' se vuoto do messaggio di errore ed esco If String.IsNullOrWhiteSpace(sSupportAddress) Then - 'MessageBox.Show(EgtMsg(MSG_TOPCOMMANDBAR + 10), EgtMsg(MSG_MESSAGEBOX + 1), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(30510), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(30510), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(MSG_TOPCOMMANDBAR + 10), EgtMsg(MSG_MESSAGEBOX + 1), MessageBoxButton.OK, MessageBoxImage.Error) Return End If ' Recupero numero chiave @@ -923,12 +903,7 @@ Public Class MainMenuVM bEx = True End Try If bEx OrElse EgtWPFLib5.MapiMailMessage.m_ErrorCode <> 0 Then - 'MessageBox.Show(String.Format(EgtMsg(MSG_TOPCOMMANDBAR + 12), sSupportAddress, sZipToCreate), EgtMsg(MSG_MESSAGEBOX + 3), MessageBoxButton.OK, MessageBoxImage.Information) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, String.Format(EgtMsg(30512), sSupportAddress, sZipToCreate), EgtMsg(15003), MessageBoxButton.OK, MessageBoxImage.Information) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, String.Format(EgtMsg(30512), sSupportAddress, sZipToCreate), EgtMsg(15003), MessageBoxButton.OK, MessageBoxImage.Information) - End If + MessageBox.Show(String.Format(EgtMsg(MSG_TOPCOMMANDBAR + 12), sSupportAddress, sZipToCreate), EgtMsg(MSG_MESSAGEBOX + 3), MessageBoxButton.OK, MessageBoxImage.Information) Else Map.refMyStatusBarVM.SetOutputMessage(EgtMsg(30514)) End If diff --git a/EgtBEAMWALL.ViewerOptimizer/MainWindow/MainWindowVM.vb b/EgtBEAMWALL.ViewerOptimizer/MainWindow/MainWindowVM.vb index 476015f5..3533c412 100644 --- a/EgtBEAMWALL.ViewerOptimizer/MainWindow/MainWindowVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/MainWindow/MainWindowVM.vb @@ -6,6 +6,7 @@ Imports EgtUILib Imports EgtWPFLib5 Imports System.IO Imports System.Threading +Imports System.Windows.Forms Imports System.Windows.Threading Public Class MainWindowVM @@ -251,13 +252,7 @@ Public Class MainWindowVM End If Dim TimeFromLastBackup As TimeSpan = DateTime.Now - LastBackupDate If TimeFromLastBackup > TimeSpan.FromDays(Map.refConfigurationPageVM.SelReminder.Id) Then - Dim m_MessageBoxResult As MessageBoxResult - If bOnlyProd Then - m_MessageBoxResult = EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, String.Format(EgtMsg(61987), Map.refConfigurationPageVM.SelReminder.Name), EgtMsg(15002), MessageBoxButton.YesNo, MessageBoxImage.Warning) - Else - m_MessageBoxResult = EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, String.Format(EgtMsg(61987), Map.refConfigurationPageVM.SelReminder.Name), EgtMsg(15002), MessageBoxButton.YesNo, MessageBoxImage.Warning) - End If - If m_MessageBoxResult = MessageBoxResult.Yes Then + If MessageBox.Show(Application.Current.MainWindow, String.Format(EgtMsg(61987), Map.refConfigurationPageVM.SelReminder.Name), EgtMsg(15002), MessageBoxButton.YesNo, MessageBoxImage.Warning) = MessageBoxResult.Yes Then Map.refConfigurationPageVM.Backup(True) End If End If @@ -376,31 +371,16 @@ Public Class MainWindowVM End If ' verifico se sono in modifica percorso libero If Map.refFreeContourManagerVM.bIsActive Then - 'MessageBox.Show(EgtMsg(61994)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61994)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61994)) - End If + MessageBox.Show(EgtMsg(61994)) Return End If ' verifico se sto facendo backup If Map.refConfigurationPageVM.bBackupRunning Then - 'MessageBox.Show(EgtMsg(62101), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) 'Backup running! Impossible closing the software until finish the backup process! - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62101), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) 'Backup running! Impossible closing the software until finish the backup process! - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62101), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) 'Backup running! Impossible closing the software until finish the backup process! - End If + MessageBox.Show(Application.Current.MainWindow, EgtMsg(62101), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) 'Backup running! Impossible closing the software until finish the backup process! Return End If If Map.refConfigurationPageVM.bRestoreRunning Then - 'MessageBox.Show(EgtMsg(62102), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) 'Restore running! Impossible closing the software until finish the restore process! - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62102), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) 'Restore running! Impossible closing the software until finish the restore process! - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62102), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) 'Restore running! Impossible closing the software until finish the restore process! - End If + MessageBox.Show(Application.Current.MainWindow, EgtMsg(62102), EgtMsg(15002), MessageBoxButton.OK, MessageBoxImage.Warning) 'Restore running! Impossible closing the software until finish the restore process! Return End If ' Gestisco eventuale file corrente modificato diff --git a/EgtBEAMWALL.ViewerOptimizer/MovePartInRawPartWnd/MovePartInRawPartWndVM.vb b/EgtBEAMWALL.ViewerOptimizer/MovePartInRawPartWnd/MovePartInRawPartWndVM.vb index 88e669e0..07f3117b 100644 --- a/EgtBEAMWALL.ViewerOptimizer/MovePartInRawPartWnd/MovePartInRawPartWndVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/MovePartInRawPartWnd/MovePartInRawPartWndVM.vb @@ -145,20 +145,10 @@ Public Class MovePartInRawPartWndVM End If RaiseEvent m_CloseWindow(True) Else - 'MessageBox.Show(EgtMsg(61947), EgtMsg(30007)) - If EgtBEAMWALL.Core.Configuration.bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61947), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61947), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61947), EgtMsg(30007)) End If Else - 'MessageBox.Show(EgtMsg(61948), EgtMsg(30007)) - If EgtBEAMWALL.Core.Configuration.bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61948), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61948), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61948), EgtMsg(30007)) End If End Sub diff --git a/EgtBEAMWALL.ViewerOptimizer/MultiCopyRawPartWnd/MultiCopyRawPartWndVM.vb b/EgtBEAMWALL.ViewerOptimizer/MultiCopyRawPartWnd/MultiCopyRawPartWndVM.vb index 7af21eff..c4bb9fd6 100644 --- a/EgtBEAMWALL.ViewerOptimizer/MultiCopyRawPartWnd/MultiCopyRawPartWndVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/MultiCopyRawPartWnd/MultiCopyRawPartWndVM.vb @@ -71,12 +71,7 @@ Public Class MultiCopyRawPartWndVM If Not IsNothing(m_nQuantity) AndAlso m_nQuantity > 0 AndAlso m_nQuantity < 99 Then RaiseEvent m_CloseWindow(True) Else - 'MessageBox.Show(EgtMsg(61887), EgtMsg(30007)) - If EgtBEAMWALL.Core.Configuration.bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61887), EgtMsg(30007)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61887), EgtMsg(30007)) - End If + MessageBox.Show(EgtMsg(61887), EgtMsg(30007)) End If End Sub diff --git a/EgtBEAMWALL.ViewerOptimizer/NestingRunningWnd/NestingRunningWndVM.vb b/EgtBEAMWALL.ViewerOptimizer/NestingRunningWnd/NestingRunningWndVM.vb index 4b7d0403..fb3411b0 100644 --- a/EgtBEAMWALL.ViewerOptimizer/NestingRunningWnd/NestingRunningWndVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/NestingRunningWnd/NestingRunningWndVM.vb @@ -609,20 +609,10 @@ Public Class NestingRunningWndVM If File.Exists(sLogPath) Then Dim LogFile As String() = File.ReadAllLines(sLogPath) If LogFile.Count >= 2 AndAlso Not IsNothing(LogFile(1)) Then - 'MessageBox.Show(LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) End If Else - 'MessageBox.Show("Impossible creating rawpart", EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61973), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61973), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show("Impossible creating rawpart", EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error) End If ' se nessun grezzo, rimetto tutti i pezzi invisibili If Map.refProjectVM.MachGroupPanelVM.MachGroupVMList.Count = 0 Then @@ -768,14 +758,7 @@ Public Class NestingRunningWndVM ''' Friend Sub Cancel() ' chiedo conferma - 'If MessageBox.Show("Are you sure you want to stop the nesting?", "Warning", MessageBoxButton.YesNo, MessageBoxImage.Warning) = MessageBoxResult.No Then Return - Dim m_MessageBoxResult As MessageBoxResult - If bOnlyProd Then - m_MessageBoxResult = EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62560), EgtMsg(91122), MessageBoxButton.YesNo, MessageBoxImage.Warning) - Else - m_MessageBoxResult = EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62560), EgtMsg(91122), MessageBoxButton.YesNo, MessageBoxImage.Warning) - End If - If m_MessageBoxResult = MessageBoxResult.No Then Return + If MessageBox.Show("Are you sure you want to stop the nesting?", "Warning", MessageBoxButton.YesNo, MessageBoxImage.Warning) = MessageBoxResult.No Then Return ' fermo il nesting Map.refOptimizePanelVM.m_StopNesting = True End Sub diff --git a/EgtBEAMWALL.ViewerOptimizer/NewOpenProjectFileDialog/NewOpenProjectFileDialogVM.vb b/EgtBEAMWALL.ViewerOptimizer/NewOpenProjectFileDialog/NewOpenProjectFileDialogVM.vb index 60567076..695f7dcf 100644 --- a/EgtBEAMWALL.ViewerOptimizer/NewOpenProjectFileDialog/NewOpenProjectFileDialogVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/NewOpenProjectFileDialog/NewOpenProjectFileDialogVM.vb @@ -1,4 +1,5 @@ Imports System.IO +Imports System.Windows.Forms Imports EgtBEAMWALL.Core Imports EgtBEAMWALL.Core.ConstBeam Imports EgtUILib @@ -144,12 +145,7 @@ Public Class NewOpenProjectFileDialogVM Dim ProjListIndex As Integer = m_ProjectList.IndexOf(SelProject) ' verifico se proj selezionato e' il corrente If Not IsNothing(ProjectManagerVM.CurrProj) AndAlso SelProject.ProjFileList.Any(Function(x) x.nProjId = ProjectManagerVM.CurrProj.nProjId) Then - Dim m_MessageBoxResult As MessageBoxResult - If bOnlyProd Then - m_MessageBoxResult = EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61872), EgtMsg(30009), MessageBoxButton.OKCancel, MessageBoxImage.Warning) - Else - m_MessageBoxResult = EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61872), EgtMsg(30009), MessageBoxButton.OKCancel, MessageBoxImage.Warning) - End If + Dim m_MessageBoxResult As MessageBoxResult = MessageBox.Show(Application.Current.MainWindow, EgtMsg(61872), EgtMsg(30009), MessageBoxButton.OKCancel, MessageBoxImage.Warning) If m_ProjectType = ProjectType.PROJ AndAlso m_MessageBoxResult = MessageBoxResult.Cancel Then Return Else @@ -158,12 +154,7 @@ Public Class NewOpenProjectFileDialogVM End If ' verifico se prod selezionato e' il corrente If Not IsNothing(ProjectManagerVM.CurrProd) AndAlso SelProject.ProdFileVM.nProdId = ProjectManagerVM.CurrProd.nProdId Then - Dim m_MessageBoxResult As MessageBoxResult - If bOnlyProd Then - m_MessageBoxResult = EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61872), EgtMsg(30009), MessageBoxButton.OKCancel, MessageBoxImage.Warning) - Else - m_MessageBoxResult = EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61872), EgtMsg(30009), MessageBoxButton.OKCancel, MessageBoxImage.Warning) - End If + Dim m_MessageBoxResult As MessageBoxResult = MessageBox.Show(Application.Current.MainWindow, EgtMsg(61872), EgtMsg(30009), MessageBoxButton.OKCancel, MessageBoxImage.Warning) If m_ProjectType = ProjectType.PROD AndAlso m_MessageBoxResult = MessageBoxResult.Cancel Then Return Else diff --git a/EgtBEAMWALL.ViewerOptimizer/OnlyProdManager/OnlyProdManagerVM.vb b/EgtBEAMWALL.ViewerOptimizer/OnlyProdManager/OnlyProdManagerVM.vb index c52d4bf4..14d73afc 100644 --- a/EgtBEAMWALL.ViewerOptimizer/OnlyProdManager/OnlyProdManagerVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/OnlyProdManager/OnlyProdManagerVM.vb @@ -412,8 +412,7 @@ Public Class OnlyProdManagerVM End Try ' se almeno un errore, mostro log If bGlobalError Then - 'MessageBox.Show(Application.Current.MainWindow, sImportMessage, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, sImportMessage, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error + MessageBox.Show(Application.Current.MainWindow, sImportMessage, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error End If End If End If @@ -503,8 +502,7 @@ Public Class OnlyProdManagerVM ' inizializzo nuovo progetto PROD NewProdFromProj() Else - 'MessageBox.Show(EgtMsg(61876)) - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61876)) + MessageBox.Show(EgtMsg(61876)) End If Map.refMainWindowVM.UpdateTitle() NotifyPropertyChanged(NameOf(MruFileNames)) @@ -568,8 +566,7 @@ Public Class OnlyProdManagerVM If IsNothing(Map.refMachinePanelVM.MachineList.FirstOrDefault(Function(x) x.Name = TempCurrProd.sMachine)) Then ' rimuovo il file in apertura dalla lista degli MRU m_MruFiles.Remove(sFilePath) - 'MessageBox.Show(EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error + MessageBox.Show(EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error NewProject() Map.refProjectVM.MachGroupPanelVM = New MyMachGroupPanelVM(MyMachGroupPanelM.CreateMyMachGroupPanel(Map.refMachinePanelVM.MachineList.ToList())) Else @@ -583,8 +580,7 @@ Public Class OnlyProdManagerVM Dim nFlag As Integer = GetMainPrivateProfileInt(S_IMPORT, sBTLFlag, EIB_FL.TS3_POS + EIB_FL.SORT + EIB_FL.USEUATTR) EgtBeamSetFlag(nFlag) Else - 'MessageBox.Show(EgtMsg(61871)) - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61871)) + MessageBox.Show(EgtMsg(61871)) Map.refSceneHostVM.MainController.NewProject() Map.refMainWindowVM.SetTitle("New - EgtBEAMWALL") End If @@ -722,21 +718,13 @@ Public Class OnlyProdManagerVM GetMainPrivateProfileString(S_GENERAL, K_LASTIMPDIR, "", sDir) If bWithDlg Then ' apro finestra scelta file - 'Dim BTLDlg As New Microsoft.Win32.OpenFileDialog() With { - ' .DefaultExt = ".btl", - ' .Filter = "BTL (*.btl)|*.btl" & - ' "|BTLX (*.btlx)|*.btlx", - ' .InitialDirectory = If(Directory.Exists(sDir), sDir, ""), - ' .CheckFileExists = True, - ' .ValidateNames = True} - Dim BTLDlg As New EgtBEAMWALL.Core.OnlyProdEgtManageFileDialogV(Application.Current.MainWindow, New EgtManageFileDialogVM()) With { - .Title = EgtMsg(61840), - .Filter = "BTL (*.btl)|*.btl" & - "|BTLX (*.btlx)|*.btlx", - .InitialDirectory = If(Directory.Exists(sDir), sDir, ""), - .CheckFileExists = True, - .ValidateNames = True - } + Dim BTLDlg As New Microsoft.Win32.OpenFileDialog() With { + .DefaultExt = ".btl", + .Filter = "BTL (*.btl)|*.btl" & + "|BTLX (*.btlx)|*.btlx", + .InitialDirectory = If(Directory.Exists(sDir), sDir, ""), + .CheckFileExists = True, + .ValidateNames = True} If BTLDlg.ShowDialog() Then sFile = BTLDlg.FileName Else @@ -753,8 +741,7 @@ Public Class OnlyProdManagerVM Dim ToDeleteProj As ProjFileM = DbControllers.m_ProjController.FindByProjIdConv(nAlreadyImported) ' se esiste gia' un'ottimizzazione If ToDeleteProj.nProdId > 0 Then - 'Select Case MessageBox.Show(EgtMsg(61942), "Information", MessageBoxButton.YesNo, MessageBoxImage.Information) ' BTL file already imported and optimized. Do you want to import it again? - Select Case EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61942), EgtMsg(15003), MessageBoxButton.YesNo, MessageBoxImage.Information) ' BTL file already imported and optimized. Do you want to import it again? + Select Case MessageBox.Show(EgtMsg(61942), "Information", MessageBoxButton.YesNo, MessageBoxImage.Information) ' BTL file already imported and optimized. Do you want to import it again? Case MessageBoxResult.Yes ' lo importo, quindi non devo fare nulla Case MessageBoxResult.No @@ -762,8 +749,7 @@ Public Class OnlyProdManagerVM End Select Else ' se non ha ottimizazione, chiedo se sovrascriverlo - 'Select Case MessageBox.Show(EgtMsg(61943), "Information", MessageBoxButton.YesNoCancel, MessageBoxImage.Information) ' BTL file already imported. Do you want to overwrite it? - Select Case EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61943), EgtMsg(15003), MessageBoxButton.YesNoCancel, MessageBoxImage.Information) ' BTL file already imported. Do you want to overwrite it? + Select Case MessageBox.Show(EgtMsg(61943), "Information", MessageBoxButton.YesNoCancel, MessageBoxImage.Information) ' BTL file already imported. Do you want to overwrite it? Case MessageBoxResult.Yes ' cancello BTLParts su DB DbControllers.m_ProjController.UpdateBtlParts(nAlreadyImported, New List(Of BTLPartM)) @@ -904,15 +890,13 @@ Public Class OnlyProdManagerVM If IsNothing(CurrProd) Then Return ' verifico se progetto modificato, e chiedo se salvare If CurrProd.bIsNew Or EgtGetModified() OrElse Map.refCALCPanelVM.IsMachineModified() Then - 'Select Case MessageBox.Show(EgtMsg(61877), "", MessageBoxButton.YesNoCancel, MessageBoxImage.Question) - Select Case EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61877), "", MessageBoxButton.YesNoCancel, MessageBoxImage.Question) + Select Case MessageBox.Show(EgtMsg(61877), "", MessageBoxButton.YesNoCancel, MessageBoxImage.Question) Case MessageBoxResult.Yes Save() Case MessageBoxResult.Cancel Return Case Else ' No - 'MessageBox.Show(EgtMsg(61892), "", MessageBoxButton.OK, MessageBoxImage.Exclamation) - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61892), "", MessageBoxButton.OK, MessageBoxImage.Exclamation) + MessageBox.Show(EgtMsg(61892), "", MessageBoxButton.OK, MessageBoxImage.Exclamation) Return End Select End If @@ -927,21 +911,13 @@ Public Class OnlyProdManagerVM GetMainPrivateProfileString(S_GENERAL, K_LASTUPDATEDIR, "", sDir) If bWithDlg Then ' apro finestra scelta file - 'Dim BTLDlg As New Microsoft.Win32.OpenFileDialog() With { - ' .DefaultExt = ".btl", - ' .Filter = "BTL (*.btl)|*.btl" & - ' "|BTLX (*.btlx)|*.btlx", - ' .InitialDirectory = If(Directory.Exists(sDir), sDir, ""), - ' .CheckFileExists = True, - ' .ValidateNames = True} - Dim BTLDlg As New EgtBEAMWALL.Core.OnlyProdEgtManageFileDialogV(Application.Current.MainWindow, New EgtManageFileDialogVM()) With { - .Title = EgtMsg(61834), - .Filter = "BTL (*.btl)|*.btl" & - "|BTLX (*.btlx)|*.btlx", - .InitialDirectory = If(Directory.Exists(sDir), sDir, ""), - .CheckFileExists = True, - .ValidateNames = True - } + Dim BTLDlg As New Microsoft.Win32.OpenFileDialog() With { + .DefaultExt = ".btl", + .Filter = "BTL (*.btl)|*.btl" & + "|BTLX (*.btlx)|*.btlx", + .InitialDirectory = If(Directory.Exists(sDir), sDir, ""), + .CheckFileExists = True, + .ValidateNames = True} If BTLDlg.ShowDialog() Then sFile = BTLDlg.FileName Else @@ -1411,14 +1387,9 @@ Public Class OnlyProdManagerVM End Select ' apro finestra di salvataggio progetto - 'Dim ExportDlg As New Microsoft.Win32.SaveFileDialog() With {.DefaultExt = ".ngexp", - ' .Filter = "ProjectExport (*.ngexp)|*.ngexp", - ' .FileName = CurrProd.nProdId.ToString("0000") & " - " & CurrProd.sBTLFileName & " - ProjectExport"} - Dim ExportDlg As New EgtBEAMWALL.Core.OnlyProdEgtManageFileDialogV(Application.Current.MainWindow, New EgtManageFileDialogVM()) With { - .Title = EgtMsg(30001), - .Filter = "ProjectExport (*.ngexp)|*.ngexp", - .FileName = CurrProd.nProdId.ToString("0000") & " - " & CurrProd.sBTLFileName & " - ProjectExport" - } + Dim ExportDlg As New Microsoft.Win32.SaveFileDialog() With {.DefaultExt = ".ngexp", + .Filter = "ProjectExport (*.ngexp)|*.ngexp", + .FileName = CurrProd.nProdId.ToString("0000") & " - " & CurrProd.sBTLFileName & " - ProjectExport"} If IsNothing(sExportFileName) Then 'If ExportDlg.ShowDialog() <> True Then Return Nothing If ExportDlg.ShowDialog() <> System.Windows.Forms.DialogResult.OK Then Return Nothing @@ -1473,8 +1444,7 @@ Public Class OnlyProdManagerVM End Using Catch ex1 As Exception EgtOutLog("Exception in zip: " & ex1.ToString()) - 'MessageBox.Show("Error in export file creation!") - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62561)) + MessageBox.Show("Error in export file creation!") End Try ' elimino layer di esportazione EgtErase(nImpExpPartId) @@ -1513,21 +1483,12 @@ Public Class OnlyProdManagerVM Dim sDir As String = String.Empty GetMainPrivateProfileString(S_GENERAL, K_LASTNGEXPDIR, "", sDir) ' apro finestra scelta file - 'Dim ImportDlg As New Microsoft.Win32.OpenFileDialog() With {.DefaultExt = ".ngexp", - ' .Filter = "ProjectExport (*.ngexp)|*.ngexp", - ' .InitialDirectory = If(Directory.Exists(sDir), sDir, ""), - ' .CheckFileExists = True, - ' .ValidateNames = True} - 'If ImportDlg.ShowDialog() <> True Then Return - Dim ImportDlg As New EgtBEAMWALL.Core.OnlyProdEgtManageFileDialogV(Application.Current.MainWindow, New EgtManageFileDialogVM()) With { - .Title = EgtMsg(61839), - .Filter = "ProjectExport (*.ngexp)|*.ngexp", - .InitialDirectory = If(Directory.Exists(sDir), sDir, ""), - .CheckFileExists = True, - .ValidateNames = True, - .Mode = 1 - } - If Not ImportDlg.ShowDialog() = System.Windows.Forms.DialogResult.OK Then Return + Dim ImportDlg As New Microsoft.Win32.OpenFileDialog() With {.DefaultExt = ".ngexp", + .Filter = "ProjectExport (*.ngexp)|*.ngexp", + .InitialDirectory = If(Directory.Exists(sDir), sDir, ""), + .CheckFileExists = True, + .ValidateNames = True} + If ImportDlg.ShowDialog() <> True Then Return ' creo cartella temporanea di estrazione in Temp Dim sProjectimportDir As String = Map.refMainWindowVM.MainWindowM.sTempDir & "\ProjectImport" If Directory.Exists(sProjectimportDir) Then @@ -1541,8 +1502,7 @@ Public Class OnlyProdManagerVM End Using Catch ex1 As Exception EgtOutLog("Exception in zip: " & ex1.ToString()) - 'MessageBox.Show("Impossibile importare file", "Errore") - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62562), EgtMsg(15001)) + MessageBox.Show("Impossibile importare file", "Errore") Return End Try LoadingWndHelper.OpenLoadingWnd(ActiveIds.IMPORTPROJECT, 2, EgtMsg(63018), EgtMsg(63019), 30) ' Project importing ' Loading project @@ -1551,8 +1511,7 @@ Public Class OnlyProdManagerVM Dim bOk = EgtOpenFile(sProjFromPath(0)) If Not bOk Then LoadingWndHelper.CloseLoadingWnd(ActiveIds.IMPORTPROJECT) - 'MessageBox.Show("Impossibile aprire il file", "Errore") - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62562), EgtMsg(15001)) + MessageBox.Show("Impossibile aprire il file", "Errore") Return End If ' recupero e verifico se ho a disposizione la macchina con cui e' stato creato il progetto @@ -1562,8 +1521,7 @@ Public Class OnlyProdManagerVM ' se la macchina del progetto in apertura non è tra le macchine disponibili lo segnalo e apro un progetto vuoto If IsNothing(Map.refMachinePanelVM.MachineList.FirstOrDefault(Function(x) x.Name = sMachine)) Then LoadingWndHelper.CloseLoadingWnd(ActiveIds.IMPORTPROJECT) - 'MessageBox.Show(EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error + MessageBox.Show(EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error Return End If Dim Machine As Machine = Map.refMachinePanelVM.MachineList.FirstOrDefault(Function(x) x.Name = sMachine) @@ -1571,8 +1529,7 @@ Public Class OnlyProdManagerVM EgtGetInfo(nImpExpPartId, BTL_GEN_PROJTYPE, nType) If IsNothing(Machine) OrElse nType = BWType.NULL Then LoadingWndHelper.CloseLoadingWnd(ActiveIds.IMPORTPROJECT) - 'MessageBox.Show(EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error + MessageBox.Show(EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error Return End If ' elimino part di esportazione @@ -1601,8 +1558,7 @@ Public Class OnlyProdManagerVM nBTLInfoLayerId = EgtGetNextName(nBTLInfoLayerId, BTLINFO) End While If Not ImportProjIdList.Count > 0 Then - 'MessageBox.Show("Nessun progetto trovato all'interno del file importato", "Errore") - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62563), EgtMsg(15001)) + MessageBox.Show("Nessun progetto trovato all'interno del file importato", "Errore") End If ' carico i proj For nProjIndex = 0 To ImportProjIdList.Count - 1 @@ -1655,8 +1611,7 @@ Public Class OnlyProdManagerVM Catch ex As Exception EgtOutLog("Impossibile copiare il file") LoadingWndHelper.CloseLoadingWnd(ActiveIds.IMPORTPROJECT) - 'MessageBox.Show("Impossibile copiare il file del progetto", "Errore") - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62564), EgtMsg(61764)) + MessageBox.Show("Impossibile copiare il file del progetto", "Errore") Return End Try End If @@ -1802,8 +1757,7 @@ Public Class OnlyProdManagerVM Dim VerifyResult As MessageBoxResult = MessageBoxResult.None ' verifico se progetto modificato, e chiedo se salvare If EgtGetModified() OrElse CurrProd.bIsNew OrElse Map.refCALCPanelVM.IsMachineModified() Then - 'VerifyResult = MessageBox.Show(EgtMsg(61875), "", If(CurrProd.bIsNew, MessageBoxButton.OKCancel, MessageBoxButton.YesNoCancel), MessageBoxImage.Question) - VerifyResult = EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61875), "", If(CurrProd.bIsNew, MessageBoxButton.OKCancel, MessageBoxButton.YesNoCancel), MessageBoxImage.Question) + VerifyResult = MessageBox.Show(EgtMsg(61875), "", If(CurrProd.bIsNew, MessageBoxButton.OKCancel, MessageBoxButton.YesNoCancel), MessageBoxImage.Question) Select Case VerifyResult Case MessageBoxResult.Yes, MessageBoxResult.OK ' salvo proj @@ -1834,18 +1788,15 @@ Public Class OnlyProdManagerVM End If Next If bFound Then - 'MessageBox.Show("Selezionato progetto che fa gia' parte di questa produzione!", "Errore", MessageBoxButton.OK, MessageBoxImage.Error) - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62565), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) + MessageBox.Show("Selezionato progetto che fa gia' parte di questa produzione!", "Errore", MessageBoxButton.OK, MessageBoxImage.Error) Else - 'MessageBox.Show("Progetto gia' collegato ad una produzione!", "Errore", MessageBoxButton.OK, MessageBoxImage.Error) - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62566), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) + MessageBox.Show("Progetto gia' collegato ad una produzione!", "Errore", MessageBoxButton.OK, MessageBoxImage.Error) End If Return End If ' verifico che sia associato alla stessa macchina If OpenProjectFileDialogVM.SelProject.sMachine <> CurrProd.sMachine Then - 'MessageBox.Show("Progetto per una macchina diversa da quella del progetto corrente!", "Errore", MessageBoxButton.OK, MessageBoxImage.Error) - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62567), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) + MessageBox.Show("Progetto per una macchina diversa da quella del progetto corrente!", "Errore", MessageBoxButton.OK, MessageBoxImage.Error) Return End If ' inserisco proj nel prod corrente diff --git a/EgtBEAMWALL.ViewerOptimizer/OpenProjectFileDialog/OpenProjectFileDialogVM.vb b/EgtBEAMWALL.ViewerOptimizer/OpenProjectFileDialog/OpenProjectFileDialogVM.vb index d02419d8..1b917c1a 100644 --- a/EgtBEAMWALL.ViewerOptimizer/OpenProjectFileDialog/OpenProjectFileDialogVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/OpenProjectFileDialog/OpenProjectFileDialogVM.vb @@ -120,22 +120,12 @@ Public Class OpenProjectFileDialogVM If m_ProjectType = ProjectType.PROJ Then ' verifico se proj selezionato e' il corrente If Not IsNothing(ProjectManagerVM.CurrProj) AndAlso SelProject.nProjId = ProjectManagerVM.CurrProj.nProjId Then - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61872), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61872), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) - End If - 'MessageBox.Show(EgtMsg(61872), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) + MessageBox.Show(EgtMsg(61872), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) Return End If ' verifico se proj selezionato ha prod If SelProject.nProdId > 0 Then - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61873), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61873), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) - End If - 'MessageBox.Show(EgtMsg(61873), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) + MessageBox.Show(EgtMsg(61873), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) Return End If Map.refProjManagerVM.m_MruFiles.Remove(SelProject.sProjPath) @@ -159,22 +149,12 @@ Public Class OpenProjectFileDialogVM ElseIf m_ProjectType = ProjectType.PROD Then ' verifico se prod selezionato e' il corrente If Not IsNothing(ProjectManagerVM.CurrProd) AndAlso SelProject.nProdId = ProjectManagerVM.CurrProd.nProdId Then - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61872), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61872), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) - End If - 'MessageBox.Show(EgtMsg(61872), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) + MessageBox.Show(EgtMsg(61872), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) Return End If ' verifico se ci sono grezzi mandati al supervisore If DbControllers.m_ProdController.IsAnyInSupervisor(SelProject.nProdId) Then - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61874), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61874), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) - End If - 'MessageBox.Show(EgtMsg(61874), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) + MessageBox.Show(EgtMsg(61874), EgtMsg(30009), MessageBoxButton.OK, MessageBoxImage.Warning) Return End If Map.refProdManagerVM.m_MruFiles.Remove(SelProject.sProdPath) diff --git a/EgtBEAMWALL.ViewerOptimizer/OptimizePanel/OptimizePanelVM.vb b/EgtBEAMWALL.ViewerOptimizer/OptimizePanel/OptimizePanelVM.vb index 9b4fe592..c793ba5f 100644 --- a/EgtBEAMWALL.ViewerOptimizer/OptimizePanel/OptimizePanelVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/OptimizePanel/OptimizePanelVM.vb @@ -460,12 +460,7 @@ Public Class OptimizePanelVM Next Next If Not String.IsNullOrWhiteSpace(sResult) Then - 'MessageBox.Show(Application.Current.MainWindow, sResult, "", MessageBoxButton.OK, MessageBoxImage.Warning) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, sResult, "", MessageBoxButton.OK, MessageBoxImage.Warning) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, sResult, "", MessageBoxButton.OK, MessageBoxImage.Warning) - End If + MessageBox.Show(Application.Current.MainWindow, sResult, "", MessageBoxButton.OK, MessageBoxImage.Warning) End If End Sub diff --git a/EgtBEAMWALL.ViewerOptimizer/ProdManager/ProdManagerVM.vb b/EgtBEAMWALL.ViewerOptimizer/ProdManager/ProdManagerVM.vb index 5a178a1d..fe5e59dd 100644 --- a/EgtBEAMWALL.ViewerOptimizer/ProdManager/ProdManagerVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/ProdManager/ProdManagerVM.vb @@ -305,8 +305,7 @@ Public Class ProdManagerVM If IsNothing(Map.refMachinePanelVM.MachineList.FirstOrDefault(Function(x) x.Name = Map.refProdManagerVM.TempCurrProd.sMachine)) Then ' rimuovo il file in apertura dalla lista degli MRU Map.refProdManagerVM.m_MruFiles.Remove(sFilePath) - 'MessageBox.Show(EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error + MessageBox.Show(EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error Map.refProjManagerVM.NewProject() Map.refProjectVM.MachGroupPanelVM = New MyMachGroupPanelVM(MyMachGroupPanelM.CreateMyMachGroupPanel(Map.refMachinePanelVM.MachineList.ToList())) Else @@ -320,8 +319,7 @@ Public Class ProdManagerVM Dim nFlag As Integer = GetMainPrivateProfileInt(S_IMPORT, sBTLFlag, EIB_FL.TS3_POS + EIB_FL.SORT + EIB_FL.USEUATTR) EgtBeamSetFlag(nFlag) Else - 'MessageBox.Show(EgtMsg(61871)) - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61871)) + MessageBox.Show(EgtMsg(61871)) Map.refSceneHostVM.MainController.NewProject() Map.refMainWindowVM.SetTitle("New - EgtBEAMWALL") End If @@ -462,8 +460,7 @@ Public Class ProdManagerVM Dim VerifyResult As MessageBoxResult = MessageBoxResult.None ' verifico se progetto modificato, e chiedo se salvare If EgtGetModified() OrElse CurrProd.bIsNew OrElse Map.refCALCPanelVM.IsMachineModified() Then - 'VerifyResult = MessageBox.Show(EgtMsg(61875), "", If(CurrProd.bIsNew, MessageBoxButton.OKCancel, MessageBoxButton.YesNoCancel), MessageBoxImage.Question) - VerifyResult = EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61875), "", If(CurrProd.bIsNew, MessageBoxButton.OKCancel, MessageBoxButton.YesNoCancel), MessageBoxImage.Question) + VerifyResult = MessageBox.Show(EgtMsg(61875), "", If(CurrProd.bIsNew, MessageBoxButton.OKCancel, MessageBoxButton.YesNoCancel), MessageBoxImage.Question) Select Case VerifyResult Case MessageBoxResult.Yes, MessageBoxResult.OK ' salvo proj @@ -494,18 +491,15 @@ Public Class ProdManagerVM End If Next If bFound Then - 'MessageBox.Show("Selezionato progetto che fa gia' parte di questa produzione!", "Errore", MessageBoxButton.OK, MessageBoxImage.Error) - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62565), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) + MessageBox.Show("Selezionato progetto che fa gia' parte di questa produzione!", "Errore", MessageBoxButton.OK, MessageBoxImage.Error) Else - 'MessageBox.Show("Progetto gia' collegato ad una produzione!", "Errore", MessageBoxButton.OK, MessageBoxImage.Error) - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62566), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) + MessageBox.Show("Progetto gia' collegato ad una produzione!", "Errore", MessageBoxButton.OK, MessageBoxImage.Error) End If Return End If ' verifico che sia associato alla stessa macchina If OpenProjectFileDialogVM.SelProject.sMachine <> CurrProd.sMachine Then - 'MessageBox.Show("Progetto per una macchina diversa da quella del progetto corrente!", "Errore", MessageBoxButton.OK, MessageBoxImage.Error) - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62567), EgtMsg(15001), MessageBoxButton.OK, MessageBoxImage.Error) + MessageBox.Show("Progetto per una macchina diversa da quella del progetto corrente!", "Errore", MessageBoxButton.OK, MessageBoxImage.Error) Return End If ' inserisco proj nel prod corrente diff --git a/EgtBEAMWALL.ViewerOptimizer/ProjManager/ProjManagerVM.vb b/EgtBEAMWALL.ViewerOptimizer/ProjManager/ProjManagerVM.vb index 73467d28..9ea352cc 100644 --- a/EgtBEAMWALL.ViewerOptimizer/ProjManager/ProjManagerVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/ProjManager/ProjManagerVM.vb @@ -383,8 +383,7 @@ Public Class ProjManagerVM End If Map.refProjectVM.SetOptimizePanel_Visibility(Map.refProjectVM.BTLStructureVM.nPROJTYPE = BWType.WALL AndAlso Map.refMainWindowVM.MainWindowM.GetKeyOption(KEY_OPT.NESTING_AUTO)) Else - 'MessageBox.Show(EgtMsg(61876)) - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61876)) + MessageBox.Show(EgtMsg(61876)) End If Map.refMainWindowVM.UpdateTitle() NotifyPropertyChanged(NameOf(MruFileNames)) @@ -475,8 +474,7 @@ Public Class ProjManagerVM PjFileVM = New ProjFileVM(DbControllers.m_ProjController.FindByProjIdConv(ProjId)) If Not IsNothing(PjFileVM.ProjFileM) AndAlso Not IsNothing(PjFileVM.sProjPath) Then Map.refProjManagerVM.m_MruFiles.Remove(PjFileVM.sProjPath) End If - 'MessageBox.Show(EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error + MessageBox.Show(EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error If bStart Then Map.refProjManagerVM.NewProject() Else If Map.refSceneHostVM.MainController.OpenProject(sFilePath, False) Then @@ -606,21 +604,13 @@ Public Class ProjManagerVM GetMainPrivateProfileString(S_GENERAL, K_LASTIMPDIR, "", sDir) If bWithDlg Then ' apro finestra scelta file - 'Dim BTLDlg As New Microsoft.Win32.OpenFileDialog() With { - ' .DefaultExt = ".btl", - ' .Filter = "BTL (*.btl)|*.btl" & - ' "|BTLX (*.btlx)|*.btlx", - ' .InitialDirectory = If(Directory.Exists(sDir), sDir, ""), - ' .CheckFileExists = True, - ' .ValidateNames = True} - Dim BTLDlg As New EgtBEAMWALL.Core.EgtManageFileDialogV(Application.Current.MainWindow, New EgtManageFileDialogVM()) With { - .Title = EgtMsg(61840), - .Filter = "BTL (*.btl)|*.btl" & - "|BTLX (*.btlx)|*.btlx", - .InitialDirectory = If(Directory.Exists(sDir), sDir, ""), - .CheckFileExists = True, - .ValidateNames = True - } + Dim BTLDlg As New Microsoft.Win32.OpenFileDialog() With { + .DefaultExt = ".btl", + .Filter = "BTL (*.btl)|*.btl" & + "|BTLX (*.btlx)|*.btlx", + .InitialDirectory = If(Directory.Exists(sDir), sDir, ""), + .CheckFileExists = True, + .ValidateNames = True} If BTLDlg.ShowDialog() Then sFile = BTLDlg.FileName Else @@ -637,8 +627,7 @@ Public Class ProjManagerVM Dim ToDeleteProj As ProjFileM = DbControllers.m_ProjController.FindByProjIdConv(nAlreadyImported) ' se esiste gia' un'ottimizzazione If ToDeleteProj.nProdId > 0 Then - 'Select Case MessageBox.Show(EgtMsg(61942), "Information", MessageBoxButton.YesNo, MessageBoxImage.Information) ' BTL file already imported and optimized. Do you want to import it again? - Select Case EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61942), EgtMsg(15003), MessageBoxButton.YesNo, MessageBoxImage.Information) ' BTL file already imported and optimized. Do you want to import it again? + Select Case MessageBox.Show(EgtMsg(61942), "Information", MessageBoxButton.YesNo, MessageBoxImage.Information) ' BTL file already imported and optimized. Do you want to import it again? Case MessageBoxResult.Yes ' lo importo, quindi non devo fare nulla Case MessageBoxResult.No @@ -646,8 +635,7 @@ Public Class ProjManagerVM End Select Else ' se non ha ottimizazione, chiedo se sovrascriverlo - 'Select Case MessageBox.Show(EgtMsg(61943), "Information", MessageBoxButton.YesNoCancel, MessageBoxImage.Information) ' BTL file already imported. Do you want to overwrite it? - Select Case EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61943), EgtMsg(15003), MessageBoxButton.YesNoCancel, MessageBoxImage.Information) ' BTL file already imported. Do you want to overwrite it? + Select Case MessageBox.Show(EgtMsg(61943), "Information", MessageBoxButton.YesNoCancel, MessageBoxImage.Information) ' BTL file already imported. Do you want to overwrite it? Case MessageBoxResult.Yes ' cancello BTLParts su DB DbControllers.m_ProjController.UpdateBtlParts(nAlreadyImported, New List(Of BTLPartM)) @@ -805,8 +793,7 @@ Public Class ProjManagerVM End Try ' se almeno un errore, mostro log If bGlobalError Then - 'MessageBox.Show(Application.Current.MainWindow, sImportMessage, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, sImportMessage, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error + MessageBox.Show(Application.Current.MainWindow, sImportMessage, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error End If End If End If @@ -835,15 +822,13 @@ Public Class ProjManagerVM If IsNothing(CurrProj) Then Return ' verifico se progetto modificato, e chiedo se salvare If CurrProj.bIsNew Or EgtGetModified() OrElse Map.refCALCPanelVM.IsMachineModified() Then - 'Select Case MessageBox.Show(EgtMsg(61877), "", MessageBoxButton.YesNoCancel, MessageBoxImage.Question) - Select Case EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61877), "", MessageBoxButton.YesNoCancel, MessageBoxImage.Question) + Select Case MessageBox.Show(EgtMsg(61877), "", MessageBoxButton.YesNoCancel, MessageBoxImage.Question) Case MessageBoxResult.Yes Save() Case MessageBoxResult.Cancel Return Case Else ' No - 'MessageBox.Show(EgtMsg(61892), "", MessageBoxButton.OK, MessageBoxImage.Exclamation) - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61892), "", MessageBoxButton.OK, MessageBoxImage.Exclamation) + MessageBox.Show(EgtMsg(61892), "", MessageBoxButton.OK, MessageBoxImage.Exclamation) Return End Select End If @@ -858,21 +843,13 @@ Public Class ProjManagerVM GetMainPrivateProfileString(S_GENERAL, K_LASTUPDATEDIR, "", sDir) If bWithDlg Then ' apro finestra scelta file - 'Dim BTLDlg As New Microsoft.Win32.OpenFileDialog() With { - ' .DefaultExt = ".btl", - ' .Filter = "BTL (*.btl)|*.btl" & - ' "|BTLX (*.btlx)|*.btlx", - ' .InitialDirectory = If(Directory.Exists(sDir), sDir, ""), - ' .CheckFileExists = True, - ' .ValidateNames = True} - Dim BTLDlg As New EgtBEAMWALL.Core.EgtManageFileDialogV(Application.Current.MainWindow, New EgtManageFileDialogVM()) With { - .Title = EgtMsg(61834), - .Filter = "BTL (*.btl)|*.btl" & - "|BTLX (*.btlx)|*.btlx", - .InitialDirectory = If(Directory.Exists(sDir), sDir, ""), - .CheckFileExists = True, - .ValidateNames = True - } + Dim BTLDlg As New Microsoft.Win32.OpenFileDialog() With { + .DefaultExt = ".btl", + .Filter = "BTL (*.btl)|*.btl" & + "|BTLX (*.btlx)|*.btlx", + .InitialDirectory = If(Directory.Exists(sDir), sDir, ""), + .CheckFileExists = True, + .ValidateNames = True} If BTLDlg.ShowDialog() Then sFile = BTLDlg.FileName Else @@ -1340,14 +1317,9 @@ Public Class ProjManagerVM End Select ' apro finestra di salvataggio progetto - 'Dim ExportDlg As New Microsoft.Win32.SaveFileDialog() With {.DefaultExt = ".ngexp", - ' .Filter = "ProjectExport (*.ngexp)|*.ngexp", - ' .FileName = CurrProj.nProjId.ToString("0000") & " - " & CurrProj.sBTLFileName & " - ProjectExport"} - Dim ExportDlg As New EgtBEAMWALL.Core.EgtManageFileDialogV(Application.Current.MainWindow, New EgtManageFileDialogVM()) With { - .Title = EgtMsg(61838), - .Filter = "ProjectExport (*.ngexp)|*.ngexp", - .FileName = CurrProj.nProjId.ToString("0000") & " - " & CurrProj.sBTLFileName & " - ProjectExport" - } + Dim ExportDlg As New Microsoft.Win32.SaveFileDialog() With {.DefaultExt = ".ngexp", + .Filter = "ProjectExport (*.ngexp)|*.ngexp", + .FileName = CurrProj.nProjId.ToString("0000") & " - " & CurrProj.sBTLFileName & " - ProjectExport"} If IsNothing(sExportFileName) Then 'If ExportDlg.ShowDialog() <> True Then Return Nothing If ExportDlg.ShowDialog() <> System.Windows.Forms.DialogResult.OK Then Return Nothing @@ -1401,8 +1373,7 @@ Public Class ProjManagerVM End Using Catch ex1 As Exception EgtOutLog("Exception in zip: " & ex1.ToString()) - 'MessageBox.Show("Error in export file creation!") - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62561)) + MessageBox.Show("Error in export file creation!") End Try ' elimino layer di esportazione EgtErase(nImpExpPartId) @@ -1446,14 +1417,6 @@ Public Class ProjManagerVM .CheckFileExists = True, .ValidateNames = True} If ImportDlg.ShowDialog() <> True Then Return - 'Dim ImportDlg As New EgtBEAMWALL.Core.EgtManageFileDialogV(Application.Current.MainWindow, New EgtManageFileDialogVM()) With { - ' .Title = EgtMsg(61839), - ' .Filter = "ProjectExport (*.ngexp)|*.ngexp", - ' .InitialDirectory = If(Directory.Exists(sDir), sDir, ""), - ' .CheckFileExists = True, - ' .ValidateNames = True - '} - 'If ImportDlg.ShowDialog() <> System.Windows.Forms.DialogResult.OK Then Return ' creo cartella temporanea di estrazione in Temp Dim sProjectimportDir As String = Map.refMainWindowVM.MainWindowM.sTempDir & "\ProjectImport" If Directory.Exists(sProjectimportDir) Then @@ -1467,8 +1430,7 @@ Public Class ProjManagerVM End Using Catch ex1 As Exception EgtOutLog("Exception in zip: " & ex1.ToString()) - 'MessageBox.Show("Impossibile importare file", "Errore") - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62562), EgtMsg(15001)) + MessageBox.Show("Impossibile importare file", "Errore") Return End Try LoadingWndHelper.OpenLoadingWnd(ActiveIds.IMPORTPROJECT, 2, EgtMsg(63018), EgtMsg(63019), 30) ' Project importing ' Loading project @@ -1477,8 +1439,7 @@ Public Class ProjManagerVM Dim bOk = EgtOpenFile(sProjFromPath(0)) If Not bOk Then LoadingWndHelper.CloseLoadingWnd(ActiveIds.IMPORTPROJECT) - 'MessageBox.Show("Impossibile aprire il file", "Errore") - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62562), EgtMsg(15001)) + MessageBox.Show("Impossibile aprire il file", "Errore") Return End If ' recupero e verifico se ho a disposizione la macchina con cui e' stato creato il progetto @@ -1488,8 +1449,7 @@ Public Class ProjManagerVM ' se la macchina del progetto in apertura non è tra le macchine disponibili lo segnalo e apro un progetto vuoto If IsNothing(Map.refMachinePanelVM.MachineList.FirstOrDefault(Function(x) x.Name = sMachine)) Then LoadingWndHelper.CloseLoadingWnd(ActiveIds.IMPORTPROJECT) - 'MessageBox.Show(EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error + MessageBox.Show(EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error Return End If Dim Machine As Machine = Map.refMachinePanelVM.MachineList.FirstOrDefault(Function(x) x.Name = sMachine) @@ -1497,8 +1457,7 @@ Public Class ProjManagerVM EgtGetInfo(nImpExpPartId, BTL_GEN_PROJTYPE, nType) If IsNothing(Machine) OrElse nType = BWType.NULL Then LoadingWndHelper.CloseLoadingWnd(ActiveIds.IMPORTPROJECT) - 'MessageBox.Show(EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error + MessageBox.Show(EgtMsg(61885), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error Return End If ' elimino part di esportazione @@ -1525,8 +1484,7 @@ Public Class ProjManagerVM nBTLInfoLayerId = EgtGetNextName(nBTLInfoLayerId, BTLINFO) End While If Not ImportProjIdList.Count > 0 Then - 'MessageBox.Show("Nessun progetto trovato all'interno del file importato", "Errore") - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62563), EgtMsg(15001)) + MessageBox.Show("Nessun progetto trovato all'interno del file importato", "Errore") End If ' carico i proj For nProjIndex = 0 To ImportProjIdList.Count - 1 @@ -1579,8 +1537,7 @@ Public Class ProjManagerVM Catch ex As Exception EgtOutLog("Impossibile copiare il file") LoadingWndHelper.CloseLoadingWnd(ActiveIds.IMPORTPROJECT) - 'MessageBox.Show("Impossibile copiare il file del progetto", "Errore") - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62564), EgtMsg(15001)) + MessageBox.Show("Impossibile copiare il file del progetto", "Errore") Return End Try End If @@ -1727,16 +1684,14 @@ Public Class ProjManagerVM ' verifico se progetto modificato, e chiedo se salvare Dim bSaved As Boolean = True If CurrProj.bIsNew Or EgtGetModified() OrElse Map.refCALCPanelVM.IsMachineModified() Then - 'Select Case MessageBox.Show(EgtMsg(61877), "", MessageBoxButton.YesNoCancel, MessageBoxImage.Question) - Select Case EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61877), "", MessageBoxButton.YesNoCancel, MessageBoxImage.Question) + Select Case MessageBox.Show(EgtMsg(61877), "", MessageBoxButton.YesNoCancel, MessageBoxImage.Question) Case MessageBoxResult.Yes Save() Case MessageBoxResult.Cancel Return Case Else ' No If ProjectManagerVM.CurrProj.bIsNew Then - 'MessageBox.Show(EgtMsg(61878), "", MessageBoxButton.OK, MessageBoxImage.Exclamation) - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61878), "", MessageBoxButton.OK, MessageBoxImage.Exclamation) + MessageBox.Show(EgtMsg(61878), "", MessageBoxButton.OK, MessageBoxImage.Exclamation) Return End If ' resetto stato modificato diff --git a/EgtBEAMWALL.ViewerOptimizer/ProjectFileVM/ProdFileVM.vb b/EgtBEAMWALL.ViewerOptimizer/ProjectFileVM/ProdFileVM.vb index a5d6af8d..75e75e7a 100644 --- a/EgtBEAMWALL.ViewerOptimizer/ProjectFileVM/ProdFileVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/ProjectFileVM/ProdFileVM.vb @@ -44,12 +44,7 @@ Public Class ProdFileVM Dim VerifyResult As MessageBoxResult = MessageBoxResult.None ' verifico se progetto modificato, e chiedo se salvare If EgtGetModified() OrElse CurrProject.bIsNew OrElse Map.refCALCPanelVM.IsMachineModified() Then - 'VerifyResult = MessageBox.Show(EgtMsg(61875), "", MessageBoxButton.YesNoCancel, MessageBoxImage.Question) - If bOnlyProd Then - VerifyResult = EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61875), "", MessageBoxButton.YesNoCancel, MessageBoxImage.Question) - Else - VerifyResult = EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61875), "", MessageBoxButton.YesNoCancel, MessageBoxImage.Question) - End If + VerifyResult = MessageBox.Show(EgtMsg(61875), "", MessageBoxButton.YesNoCancel, MessageBoxImage.Question) Select Case VerifyResult Case MessageBoxResult.Yes ' salvo proj diff --git a/EgtBEAMWALL.ViewerOptimizer/ProjectFileVM/ProjFileVM.vb b/EgtBEAMWALL.ViewerOptimizer/ProjectFileVM/ProjFileVM.vb index d37f2b7f..d449abc7 100644 --- a/EgtBEAMWALL.ViewerOptimizer/ProjectFileVM/ProjFileVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/ProjectFileVM/ProjFileVM.vb @@ -32,8 +32,7 @@ Public Class ProjFileVM sProjectDirPath = CurrProject.sProjDirPath ' verifico se progetto modificato, e chiedo se salvare If EgtGetModified() OrElse CurrProject.bIsNew OrElse Map.refCALCPanelVM.IsMachineModified() Then - 'Select Case MessageBox.Show(EgtMsg(61875), "", MessageBoxButton.YesNoCancel, MessageBoxImage.Question) - Select Case EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61875), "", MessageBoxButton.YesNoCancel, MessageBoxImage.Question) + Select Case MessageBox.Show(EgtMsg(61875), "", MessageBoxButton.YesNoCancel, MessageBoxImage.Question) Case MessageBoxResult.Yes ' salvo proj If Not IsNothing(Map.refProjManagerVM) Then diff --git a/EgtBEAMWALL.ViewerOptimizer/ProjectTypeWnd/ProjectTypeWndVM.vb b/EgtBEAMWALL.ViewerOptimizer/ProjectTypeWnd/ProjectTypeWndVM.vb index a63588d6..b1412f49 100644 --- a/EgtBEAMWALL.ViewerOptimizer/ProjectTypeWnd/ProjectTypeWndVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/ProjectTypeWnd/ProjectTypeWndVM.vb @@ -114,12 +114,7 @@ Public Class ProjectTypeWndVM RaiseEvent m_CloseWindow(True) Case Else ' se non seleziono nessuna tipo progetto lo segnalo con un MessageBox - 'MessageBox.Show(EgtMsg(61880), EgtMsg(30009)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61880), EgtMsg(30009)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61880), EgtMsg(30009)) - End If + MessageBox.Show(EgtMsg(61880), EgtMsg(30009)) End Select Else ' altrimenti setto la macchina e il tipo associato ad essa @@ -129,12 +124,7 @@ Public Class ProjectTypeWndVM End If Else ' se non seleziono nessuna macchina lo segnalo con un MessageBox - 'MessageBox.Show(EgtMsg(61880), EgtMsg(30009)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61880), EgtMsg(30009)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61880), EgtMsg(30009)) - End If + MessageBox.Show(EgtMsg(61880), EgtMsg(30009)) End If End Sub diff --git a/EgtBEAMWALL.ViewerOptimizer/RawPartManager/RawPartManagerVM.vb b/EgtBEAMWALL.ViewerOptimizer/RawPartManager/RawPartManagerVM.vb index 38769e3d..5cd94250 100644 --- a/EgtBEAMWALL.ViewerOptimizer/RawPartManager/RawPartManagerVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/RawPartManager/RawPartManagerVM.vb @@ -144,12 +144,7 @@ Public Class RawPartManagerVM Return End If If Not Produce(Map.refMachGroupPanelVM.SelectedMachGroup, ErrorMsg) AndAlso Not String.IsNullOrWhiteSpace(ErrorMsg) Then - 'MessageBox.Show(ErrorMsg) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, ErrorMsg) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, ErrorMsg) - End If + MessageBox.Show(ErrorMsg) End If End Sub @@ -227,12 +222,7 @@ Public Class RawPartManagerVM sMachGroups &= " " & MachGroup.Name & "," Next sMachGroups = sMachGroups.Trim({" "c, ","c}) - 'MessageBox.Show(String.Format("Impossible sending {0} to supervisor because not machinable!", sMachGroups)) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, String.Format(EgtMsg(62568), sMachGroups)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, String.Format(EgtMsg(62568), sMachGroups)) - End If + MessageBox.Show(String.Format("Impossible sending {0} to supervisor because not machinable!", sMachGroups)) End If End If End Sub diff --git a/EgtBEAMWALL.ViewerOptimizer/SceneHost/MySceneHostVM.vb b/EgtBEAMWALL.ViewerOptimizer/SceneHost/MySceneHostVM.vb index 39343667..7206a57e 100644 --- a/EgtBEAMWALL.ViewerOptimizer/SceneHost/MySceneHostVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/SceneHost/MySceneHostVM.vb @@ -4,6 +4,7 @@ Imports EgtUILib Imports EgtWPFLib5 Imports EgtBEAMWALL.Core Imports EgtBEAMWALL.DataLayer.DatabaseModels +Imports System.Windows.Forms Public Class MySceneHostVM Inherits EgtWPFLib5.SceneHostVM @@ -70,7 +71,7 @@ Public Class MySceneHostVM ' imposto direttorio BtlAux per geometrie Variant Dim sBtlAuxDir As String = "" GetMainPrivateProfileString(S_IMPORT, K_BTLAUXDIR, "", sBtlAuxDir) - EgtSetBtlAuxDir( sBtlAuxDir) + EgtSetBtlAuxDir(sBtlAuxDir) ' inizializzo gestore lavorazioni EgtInitMachMgr(Map.refMainWindowVM.MainWindowM.sMachinesRoot, Map.refMainWindowVM.MainWindowM.sToolMakersDir) ' Seleziono la macchina impostata nel file ini @@ -84,34 +85,17 @@ Public Class MySceneHostVM ' Box di avviso chiave mancante : "Chiave non presente. \n Inserirla e riavviare il programma." "Errore" Dim sText As String = EgtMsg(10102) & vbCrLf & EgtMsg(10103) Dim sTitle As String = EgtMsg(10101) - 'MessageBox.Show(sText, sTitle, MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, sText, sTitle, MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, sText, sTitle, MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(Application.Current.MainWindow, sText, sTitle, MessageBoxButton.OK, MessageBoxImage.Error) ' Altrimenti manca la licenza Else EgtOutLog("Problems with Licence") ' Box di avviso licenza con problemi : "Programma senza licenza. \n Caricala e riavvia il programma." "Errore" Dim sText As String = EgtMsg(10105) & vbCrLf & EgtMsg(10106) Dim sTitle As String = EgtMsg(10101) - Dim m_MessageBoxResult As MessageBoxResult - If bOnlyProd Then - m_MessageBoxResult = EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, sText, sTitle, MessageBoxButton.OKCancel, MessageBoxImage.Error) - Else - m_MessageBoxResult = EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, sText, sTitle, MessageBoxButton.OKCancel, MessageBoxImage.Error) - End If - If m_MessageBoxResult = MessageBoxResult.OK Then + If MessageBox.Show(Application.Current.MainWindow, sText, sTitle, MessageBoxButton.OKCancel, MessageBoxImage.Error) = MessageBoxResult.OK Then ' Apro dialogo per richiesta file licenza - 'Dim LicDlg As New Microsoft.Win32.OpenFileDialog() With { - ' .DefaultExt = ".lic", - ' .Filter = "Licences (.lic)|*.lic", - ' .CheckFileExists = True, - ' .ValidateNames = True - '} - Dim LicDlg As New EgtBEAMWALL.Core.EgtManageFileDialogV(Application.Current.MainWindow, New EgtManageFileDialogVM()) With { - .Title = EgtMsg(30006), + Dim LicDlg As New Microsoft.Win32.OpenFileDialog() With { + .DefaultExt = ".lic", .Filter = "Licences (.lic)|*.lic", .CheckFileExists = True, .ValidateNames = True @@ -652,12 +636,7 @@ Public Class MySceneHostVM End If End If If ProjectType = ProjectType.PROD Then Map.refProdManagerVM.m_MruFiles.Remove(sFile) - 'MessageBox.Show(EgtMsg(10003) & " '" & sFile & "'", EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error opening file - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(10003) & " '" & sFile & "'", EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error opening file - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(10003) & " '" & sFile & "'", EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error opening file - End If + MessageBox.Show(Application.Current.MainWindow, EgtMsg(10003) & " '" & sFile & "'", EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) 'Error opening file Map.refProjManagerVM.NewProject() If Map.refMainMenuVM.SelPage = Pages.MACHINING OrElse Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE Then Map.refProjectVM.MachGroupPanelVM = New MyMachGroupPanelVM(MyMachGroupPanelM.CreateMyMachGroupPanel(Map.refMachinePanelVM.MachineList.ToList())) @@ -688,12 +667,7 @@ Public Class MySceneHostVM End If If ProjectType = ProjectType.PROD Then Map.refProdManagerVM.m_MruFiles.Remove(sFile) Dim sMsg As String = EgtMsg(10004) & " '" & sFile & "'" 'Error saving file - 'MessageBox.Show(sMsg, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, sMsg, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, sMsg, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error - End If + MessageBox.Show(Application.Current.MainWindow, sMsg, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error Return End If ' in base al tipo progetto aggiungo il file in salvataggio alla lista degli MRU @@ -726,12 +700,7 @@ Public Class MySceneHostVM End If nFlag = GetMainPrivateProfileInt(S_IMPORT, sBTLFlag, EIB_FL.TS3_POS + EIB_FL.SORT + EIB_FL.USEUATTR) Else - 'MessageBox.Show(Application.Current.MainWindow, EgtMsg(10005), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' File type unknown - Error - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(10005), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' File type unknown - Error - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(10005), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' File type unknown - Error - End If + MessageBox.Show(Application.Current.MainWindow, EgtMsg(10005), EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' File type unknown - Error End If End Sub @@ -770,12 +739,7 @@ Public Class MySceneHostVM EgtSetInfo(nAsseBaseLayer, BTL_PRT_PROJ, ProjectManagerVM.nLoadingProjId) Else Dim sMsg As String = EgtMsg(10006) & " '" & sFile & "'" 'Error importing file - 'MessageBox.Show(Application.Current.MainWindow, sMsg, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, sMsg, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, sMsg, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error - End If + MessageBox.Show(Application.Current.MainWindow, sMsg, EgtMsg(10001), MessageBoxButton.OK, MessageBoxImage.Error) ' Error If Not IsNothing(Map.refProjManagerVM) Then Map.refProjManagerVM.NewProject() ElseIf Not IsNothing(Map.refOnlyProdManagerVM) Then diff --git a/EgtBEAMWALL.ViewerOptimizer/SetUp/SetUpVM.vb b/EgtBEAMWALL.ViewerOptimizer/SetUp/SetUpVM.vb index 91eb2665..71c78d0d 100644 --- a/EgtBEAMWALL.ViewerOptimizer/SetUp/SetUpVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/SetUp/SetUpVM.vb @@ -446,20 +446,10 @@ Public Class SetUpVM If String.IsNullOrWhiteSpace(sSearchedTool) Then sSearchedTool = sToolNameList(ToolIndex) If Not String.IsNullOrWhiteSpace(sSearchedTool) Then ' Impossibile trovare l'utensile xxx nel DB utensili - 'MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 3) & " " & sSearchedTool & " " & EgtMsg(MSG_SETUPERRORS + 4), EgtMsg(MSG_SETUPERRORS + 2), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6473) & " " & sSearchedTool & " " & EgtMsg(6474), EgtMsg(6472), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6473) & " " & sSearchedTool & " " & EgtMsg(6474), EgtMsg(6472), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 3) & " " & sSearchedTool & " " & EgtMsg(MSG_SETUPERRORS + 4), EgtMsg(MSG_SETUPERRORS + 2), MessageBoxButton.OK, MessageBoxImage.Error) Else ' Impossibile trovare l'utensile nel DB utensili - 'MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 3) & " " & EgtMsg(MSG_SETUPERRORS + 4), EgtMsg(MSG_SETUPERRORS + 2), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6473) & " " & EgtMsg(6474), EgtMsg(6472), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6473) & " " & EgtMsg(6474), EgtMsg(6472), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 3) & " " & EgtMsg(MSG_SETUPERRORS + 4), EgtMsg(MSG_SETUPERRORS + 2), MessageBoxButton.OK, MessageBoxImage.Error) End If End If End If @@ -575,12 +565,7 @@ Public Class SetUpVM For ErrorIndex = 0 To ErrorList.Count - 1 sError &= "- " & ErrorList(ErrorIndex) & Environment.NewLine Next - 'MessageBox.Show(sError, EgtMsg(MSG_SETUPERRORS + 2), MessageBoxButton.OK, MessageBoxImage.Exclamation) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, sError, EgtMsg(6472), MessageBoxButton.OK, MessageBoxImage.Exclamation) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, sError, EgtMsg(6472), MessageBoxButton.OK, MessageBoxImage.Exclamation) - End If + MessageBox.Show(sError, EgtMsg(MSG_SETUPERRORS + 2), MessageBoxButton.OK, MessageBoxImage.Exclamation) End If End If End Sub @@ -627,12 +612,7 @@ Public Class SetUpVM ' se la posizione non è valida, restituisco errore If sHead = INVALIDPOS Then EgtOutLog("SetUp warning: try to set " & SelTool.Name & " on " & Position.TcPos) - 'MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 5), EgtMsg(MSG_SETUPERRORS + 1), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6475), EgtMsg(6471), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6475), EgtMsg(6471), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 5), EgtMsg(MSG_SETUPERRORS + 1), MessageBoxButton.OK, MessageBoxImage.Error) Return False ' altrimenti, se la posizione nell'attrezzaggio è vuota ElseIf Not PosIsOccupied Then @@ -810,12 +790,7 @@ Public Class SetUpVM For ErrorIndex = 0 To ErrorList.Count - 1 sError &= "- " & ErrorList(ErrorIndex) & Environment.NewLine Next - 'MessageBox.Show(sError, EgtMsg(MSG_SETUPERRORS + 2), MessageBoxButton.OK, MessageBoxImage.Exclamation) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, sError, EgtMsg(6472), MessageBoxButton.OK, MessageBoxImage.Exclamation) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, sError, EgtMsg(6472), MessageBoxButton.OK, MessageBoxImage.Exclamation) - End If + MessageBox.Show(sError, EgtMsg(MSG_SETUPERRORS + 2), MessageBoxButton.OK, MessageBoxImage.Exclamation) End If ' abilito e disabilito tutte le uscite in base all'utensile selezionato diff --git a/EgtBEAMWALL.ViewerOptimizer/ToolsDbWindow/MyToolDbWindowVM.vb b/EgtBEAMWALL.ViewerOptimizer/ToolsDbWindow/MyToolDbWindowVM.vb index 6c09a24d..3a232b9f 100644 --- a/EgtBEAMWALL.ViewerOptimizer/ToolsDbWindow/MyToolDbWindowVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/ToolsDbWindow/MyToolDbWindowVM.vb @@ -59,12 +59,7 @@ Public Class MyToolDbWindowVM ' verifico che il file di configurazione attrezzaggio (lua) della macchina esista If Not File.Exists(CurrentMachine.sMachScriptDir & "\" & SETUP_LUA) Then EgtOutLog("SetUp error: SetUp configuration file doesn't exist ") - 'MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 7), EgtMsg(MSG_SETUPERRORS + 1), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6477), EgtMsg(6471), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6477), EgtMsg(6471), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 7), EgtMsg(MSG_SETUPERRORS + 1), MessageBoxButton.OK, MessageBoxImage.Error) Return End If ' carico Lua che contiene le funzioni per ottenere le posizioni valide dell'utensile selezionato, @@ -83,12 +78,7 @@ Public Class MyToolDbWindowVM EgtLuaGetGlobIntVar("STU.ERR", nErr) If nErr = 0 Then If EgtGetHeadExitCount(sHead) = 0 Then - 'MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 8), EgtMsg(MSG_SETUPERRORS + 1), MessageBoxButton.OK, MessageBoxImage.Error) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6478), EgtMsg(6471), MessageBoxButton.OK, MessageBoxImage.Error) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(6478), EgtMsg(6471), MessageBoxButton.OK, MessageBoxImage.Error) - End If + MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 8), EgtMsg(MSG_SETUPERRORS + 1), MessageBoxButton.OK, MessageBoxImage.Error) Return End If End If diff --git a/EgtBEAMWALL.ViewerOptimizer/Utility/DbControllers.vb b/EgtBEAMWALL.ViewerOptimizer/Utility/DbControllers.vb index 05f7573d..01cbbc7e 100644 --- a/EgtBEAMWALL.ViewerOptimizer/Utility/DbControllers.vb +++ b/EgtBEAMWALL.ViewerOptimizer/Utility/DbControllers.vb @@ -83,12 +83,7 @@ Public Module DbControllers End If Catch ex As Exception EgtOutLog("InitDb error: " & ex.ToString()) - 'MessageBox.Show(Application.Current.MainWindow, "Db connection error!!", "Error") - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62554), EgtMsg(15001)) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(62554), EgtMsg(15001)) - End If + MessageBox.Show(Application.Current.MainWindow, "Db connection error!!", "Error") End End Try diff --git a/EgtBEAMWALL.ViewerOptimizer/Utility/Dictionary.xaml b/EgtBEAMWALL.ViewerOptimizer/Utility/Dictionary.xaml index 3028ab5a..ee44310a 100644 --- a/EgtBEAMWALL.ViewerOptimizer/Utility/Dictionary.xaml +++ b/EgtBEAMWALL.ViewerOptimizer/Utility/Dictionary.xaml @@ -82,6 +82,11 @@ + + + + + @@ -197,7 +202,61 @@ - + + + + + + + + + + + + + + + + @@ -258,7 +317,7 @@ - + @@ -2258,8 +2317,8 @@ - --> + + + + diff --git a/EgtBEAMWALL.ViewerOptimizer/WarehouseWnd/WarehouseWndV.xaml b/EgtBEAMWALL.ViewerOptimizer/WarehouseWnd/WarehouseWndV.xaml index 326ecacc..359fef64 100644 --- a/EgtBEAMWALL.ViewerOptimizer/WarehouseWnd/WarehouseWndV.xaml +++ b/EgtBEAMWALL.ViewerOptimizer/WarehouseWnd/WarehouseWndV.xaml @@ -215,7 +215,7 @@ ScrollViewer.CanContentScroll="True" ScrollViewer.VerticalScrollBarVisibility="Auto" ScrollViewer.HorizontalScrollBarVisibility="Auto" - ColumnHeaderBackground="{DynamicResource {x:Static SystemColors.ControlBrushKey}}" + ColumnHeaderBackground="{StaticResource DataGrid.Static.Background}" ColumnHeaderForeground="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}" ColumnHeaderFontWeight="Normal" ColumnHeaderPadding="0,2,0,2" diff --git a/EgtBEAMWALL.ViewerOptimizer/WarehouseWnd/WarehouseWndVM.vb b/EgtBEAMWALL.ViewerOptimizer/WarehouseWnd/WarehouseWndVM.vb index d89359d3..be039aaf 100644 --- a/EgtBEAMWALL.ViewerOptimizer/WarehouseWnd/WarehouseWndVM.vb +++ b/EgtBEAMWALL.ViewerOptimizer/WarehouseWnd/WarehouseWndVM.vb @@ -624,12 +624,7 @@ Public Class WarehouseWndVM If Map.refProjectVM.BTLStructureVM.nPROJTYPE = MachineType.BEAM Then ' Verifico che i valori siano tutti > 0 If dStartOffset <= 0 OrElse dOffset <= 0 Then - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValues_Msg, Error_Msg) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValues_Msg, Error_Msg) - End If - 'MessageBox.Show(IncorrectValues_Msg, Error_Msg) + MessageBox.Show(IncorrectValues_Msg, Error_Msg) Return End If ' Se i valori sono tutti > 0 li scrivo nel file INI @@ -648,12 +643,7 @@ Public Class WarehouseWndVM ElseIf Map.refProjectVM.BTLStructureVM.nPROJTYPE = MachineType.WALL Then ' Verifico che i valori siano tutti > 0 If dKerf <= 0 OrElse dOffset <= 0 Then - 'MessageBox.Show(IncorrectValues_Msg, Error_Msg) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValues_Msg, Error_Msg) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValues_Msg, Error_Msg) - End If + MessageBox.Show(IncorrectValues_Msg, Error_Msg) Return End If ' Se i valori sono tutti > 0 li scrivo nel file INI @@ -677,22 +667,12 @@ Public Class WarehouseWndVM If Map.refProjectVM.BTLStructureVM.nPROJTYPE = MachineType.BEAM Then ' Verifico che i valori siano tutti > 0 If dStartOffset < 0 OrElse dOffset < 0 Then - 'MessageBox.Show(IncorrectValues_Msg, Error_Msg) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValues_Msg, Error_Msg) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValues_Msg, Error_Msg) - End If + MessageBox.Show(IncorrectValues_Msg, Error_Msg) Return End If For Each SPItem In SParamList If IsNothing(SParamList(ParamIndex - 1).SectXMat) OrElse SParamList(ParamIndex - 1).dL <= 0 Then - 'MessageBox.Show(IncorrectValues_Msg, Error_Msg) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValues_Msg, Error_Msg) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValues_Msg, Error_Msg) - End If + MessageBox.Show(IncorrectValues_Msg, Error_Msg) Return End If ParamIndex += 1 @@ -722,22 +702,12 @@ Public Class WarehouseWndVM ElseIf Map.refProjectVM.BTLStructureVM.nPROJTYPE = MachineType.WALL Then ' Verifico che i valori siano tutti > 0 If dKerf < 0 OrElse dOffset < 0 Then - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValues_Msg, Error_Msg) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValues_Msg, Error_Msg) - End If - 'MessageBox.Show(IncorrectValues_Msg, Error_Msg) + MessageBox.Show(IncorrectValues_Msg, Error_Msg) Return End If For Each SPItem In SParamList If IsNothing(SParamList(ParamIndex - 1).SectXMat) OrElse SParamList(ParamIndex - 1).dW <= 0 OrElse SParamList(ParamIndex - 1).dL <= 0 Then - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValues_Msg, Error_Msg) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValues_Msg, Error_Msg) - End If - 'MessageBox.Show(IncorrectValues_Msg, Error_Msg) + MessageBox.Show(IncorrectValues_Msg, Error_Msg) Return End If ParamIndex += 1 @@ -857,24 +827,14 @@ Public Class WarehouseWndVM End If Next If bExist Then - 'MessageBox.Show(ValueExists_Msg, Error_Msg) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, ValueExists_Msg, Error_Msg) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, ValueExists_Msg, Error_Msg) - End If + MessageBox.Show(ValueExists_Msg, Error_Msg) Else SParamList.Add(New SParam(dLValue)) sNewL = Nothing NewBeamParam_Visibility = Visibility.Collapsed End If Else - 'MessageBox.Show(IncorrectValue_Msg, Error_Msg) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValue_Msg, Error_Msg) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValue_Msg, Error_Msg) - End If + MessageBox.Show(IncorrectValue_Msg, Error_Msg) End If Case MachineType.WALL If Not IsNothing(sNewW) Then StringToLenAdv(sNewW, dWValue, True) @@ -889,12 +849,7 @@ Public Class WarehouseWndVM End If Next If bExist Then - 'MessageBox.Show(ValuesExist_Msg, Error_Msg) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, ValuesExist_Msg, Error_Msg) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, ValuesExist_Msg, Error_Msg) - End If + MessageBox.Show(ValuesExist_Msg, Error_Msg) Else SParamList.Add(New SParam(dWValue, dLValue)) sNewW = Nothing @@ -902,12 +857,7 @@ Public Class WarehouseWndVM NewWallParam_Visibility = Visibility.Collapsed End If Else - 'MessageBox.Show(IncorrectValues_Msg, Error_Msg) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValues_Msg, Error_Msg) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, IncorrectValues_Msg, Error_Msg) - End If + MessageBox.Show(IncorrectValues_Msg, Error_Msg) End If End Select End Sub @@ -948,13 +898,7 @@ Public Class WarehouseWndVM Public Sub RemoveParam() If Not IsNothing(SelSParam) Then If SelSParam.Equals(SelCurrentS) Then - Dim m_MessageBoxResult As MessageBoxResult - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, RemoveCurrent_Msg, Attention_Msg, MessageBoxButtons.YesNo, MessageBoxIcon.Question) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, RemoveCurrent_Msg, Attention_Msg, MessageBoxButtons.YesNo, MessageBoxIcon.Question) - End If - If m_MessageBoxResult = DialogResult.Yes Then + If MessageBox.Show(Application.Current.MainWindow, RemoveCurrent_Msg, Attention_Msg, MessageBoxButtons.YesNo, MessageBoxIcon.Question) = DialogResult.Yes Then SParamList.Remove(SelSParam) m_RemovedParamsCount += 1 If SParamList.Count > 0 Then @@ -1035,12 +979,7 @@ Public Class WarehouseWndVM If WhWallParamList.Last().dMaxThickness > WhWallParamList.Last().dMinThickness Then WhWallParamList.Add(New WhWallParam(0, CurrentMachine.dMaxRawH)) Else - 'System.Windows.MessageBox.Show(EgtMsg(61777), "", MessageBoxButton.OK, MessageBoxImage.Warning) - If bOnlyProd Then - EgtBEAMWALL.Core.OnlyProdEgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61777), "", MessageBoxButton.OK, MessageBoxImage.Warning) - Else - EgtBEAMWALL.Core.EgtMessageBoxV.Show(Application.Current.MainWindow, EgtMsg(61777), "", MessageBoxButton.OK, MessageBoxImage.Warning) - End If + System.Windows.MessageBox.Show(EgtMsg(61777), "", MessageBoxButton.OK, MessageBoxImage.Warning) End If Else WhWallParamList.Add(New WhWallParam(0, CurrentMachine.dMaxRawH))