Compare commits
18 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 4ac0507050 | |||
| a6a4f29bba | |||
| 0c9b37742a | |||
| ef5c98020e | |||
| c2a1fa3fdc | |||
| 319275f43c | |||
| 61d238e196 | |||
| 0900728bbf | |||
| ee83a453e7 | |||
| 7596849254 | |||
| e12eb2599e | |||
| a0754265ac | |||
| 1645a39506 | |||
| 9e2c2c1b98 | |||
| 51f15818c2 | |||
| b0081241d8 | |||
| 173230df5a | |||
| 367ac62fc8 |
@@ -107,6 +107,7 @@ Public Class CadCutPageUC
|
|||||||
|
|
||||||
Private Sub PhotoBtn_Click(sender As Object, e As RoutedEventArgs) Handles PhotoBtn.Click
|
Private Sub PhotoBtn_Click(sender As Object, e As RoutedEventArgs) Handles PhotoBtn.Click
|
||||||
m_MainWindow.TestOff()
|
m_MainWindow.TestOff()
|
||||||
|
m_MainWindow.DragRettangleOff()
|
||||||
m_CurrProjPage.m_SceneButtons.MeasureBtn.IsChecked = False
|
m_CurrProjPage.m_SceneButtons.MeasureBtn.IsChecked = False
|
||||||
EgtSetCurrentContext(m_MainWindow.m_CurrentProjectPageUC.CurrentProjectScene.GetCtx())
|
EgtSetCurrentContext(m_MainWindow.m_CurrentProjectPageUC.CurrentProjectScene.GetCtx())
|
||||||
' Se macchina fotografica collegata, faccio una foto
|
' Se macchina fotografica collegata, faccio una foto
|
||||||
@@ -140,6 +141,7 @@ Public Class CadCutPageUC
|
|||||||
|
|
||||||
Private Sub RawPartBtn_Click(sender As Object, e As RoutedEventArgs) Handles RawPartBtn.Click
|
Private Sub RawPartBtn_Click(sender As Object, e As RoutedEventArgs) Handles RawPartBtn.Click
|
||||||
m_MainWindow.TestOff()
|
m_MainWindow.TestOff()
|
||||||
|
m_MainWindow.DragRettangleOff()
|
||||||
m_CurrProjPage.CurrProjGrid.Visibility = Windows.Visibility.Hidden
|
m_CurrProjPage.CurrProjGrid.Visibility = Windows.Visibility.Hidden
|
||||||
m_CurrProjPage.CurrentProjectPageGrid.Children.Remove(Me)
|
m_CurrProjPage.CurrentProjectPageGrid.Children.Remove(Me)
|
||||||
m_CurrProjPage.CurrentProjectPageGrid.Children.Add(m_MainWindow.m_RawPartPage)
|
m_CurrProjPage.CurrentProjectPageGrid.Children.Add(m_MainWindow.m_RawPartPage)
|
||||||
@@ -165,6 +167,7 @@ Public Class CadCutPageUC
|
|||||||
|
|
||||||
Private Sub DrawBtn_Click(sender As Object, e As RoutedEventArgs) Handles DrawBtn.Click
|
Private Sub DrawBtn_Click(sender As Object, e As RoutedEventArgs) Handles DrawBtn.Click
|
||||||
m_MainWindow.TestOff()
|
m_MainWindow.TestOff()
|
||||||
|
m_MainWindow.DragRettangleOff()
|
||||||
m_MainWindow.MainWindowGrid.Children.Remove(m_MainWindow.m_CurrentProjectPageUC)
|
m_MainWindow.MainWindowGrid.Children.Remove(m_MainWindow.m_CurrentProjectPageUC)
|
||||||
m_MainWindow.MainWindowGrid.Children.Add(m_MainWindow.m_DrawPageUC)
|
m_MainWindow.MainWindowGrid.Children.Add(m_MainWindow.m_DrawPageUC)
|
||||||
m_MainWindow.m_ActivePage = MainWindow.Pages.Draw
|
m_MainWindow.m_ActivePage = MainWindow.Pages.Draw
|
||||||
@@ -172,6 +175,7 @@ Public Class CadCutPageUC
|
|||||||
|
|
||||||
Private Sub ImportBtn_Click(sender As Object, e As RoutedEventArgs) Handles ImportBtn.Click
|
Private Sub ImportBtn_Click(sender As Object, e As RoutedEventArgs) Handles ImportBtn.Click
|
||||||
m_MainWindow.TestOff()
|
m_MainWindow.TestOff()
|
||||||
|
m_MainWindow.DragRettangleOff()
|
||||||
m_MainWindow.MainWindowGrid.Children.Remove(m_MainWindow.m_CurrentProjectPageUC)
|
m_MainWindow.MainWindowGrid.Children.Remove(m_MainWindow.m_CurrentProjectPageUC)
|
||||||
m_MainWindow.MainWindowGrid.Children.Add(m_MainWindow.m_ImportPageUC)
|
m_MainWindow.MainWindowGrid.Children.Add(m_MainWindow.m_ImportPageUC)
|
||||||
m_MainWindow.m_ActivePage = MainWindow.Pages.Import
|
m_MainWindow.m_ActivePage = MainWindow.Pages.Import
|
||||||
@@ -193,10 +197,11 @@ Public Class CadCutPageUC
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub SplitBtn_Click(sender As Object, e As RoutedEventArgs) Handles SplitBtn.Click
|
Private Sub SplitBtn_Click(sender As Object, e As RoutedEventArgs) Handles SplitBtn.Click
|
||||||
|
m_MainWindow.DragRettangleOff()
|
||||||
m_CurrProjPage.m_SceneButtons.MeasureBtn.IsChecked = False
|
m_CurrProjPage.m_SceneButtons.MeasureBtn.IsChecked = False
|
||||||
EgtDeselectObj(m_NestPage.m_CurrSelectedCurv)
|
EgtDeselectObj(m_NestPage.m_CurrSelectedCurv)
|
||||||
m_ProjectMgr.TestBtn.IsChecked = False
|
m_ProjectMgr.TestBtn.IsChecked = False
|
||||||
m_CurrProjPage.m_bSelectCurv = False
|
m_MainWindow.m_CadCutPageUC.m_NestPage.m_bSelectCurv = False
|
||||||
Select Case m_CadCutMode
|
Select Case m_CadCutMode
|
||||||
Case CadCutModes.Nest, CadCutModes.FastGrid
|
Case CadCutModes.Nest, CadCutModes.FastGrid
|
||||||
' Passo alla pagina Split
|
' Passo alla pagina Split
|
||||||
@@ -206,9 +211,9 @@ Public Class CadCutPageUC
|
|||||||
SplitImage.Source = New System.Windows.Media.Imaging.BitmapImage(New Uri("/Resources/NewIcons/Nest.png", UriKind.Relative))
|
SplitImage.Source = New System.Windows.Media.Imaging.BitmapImage(New Uri("/Resources/NewIcons/Nest.png", UriKind.Relative))
|
||||||
End If
|
End If
|
||||||
If m_CadCutMode = CadCutModes.Nest Then
|
If m_CadCutMode = CadCutModes.Nest Then
|
||||||
CadCutPageGrid.Children.Remove(m_NestPage)
|
CadCutPageGrid.Children.Remove(m_NestPage)
|
||||||
Else
|
Else
|
||||||
CadCutPageGrid.Children.Remove(m_FastGridSlabManager)
|
CadCutPageGrid.Children.Remove(m_FastGridSlabManager)
|
||||||
End If
|
End If
|
||||||
CadCutPageGrid.Children.Add(m_SplitPage)
|
CadCutPageGrid.Children.Add(m_SplitPage)
|
||||||
m_CadCutMode = CadCutModes.Split
|
m_CadCutMode = CadCutModes.Split
|
||||||
|
|||||||
@@ -109,9 +109,14 @@
|
|||||||
</Button>
|
</Button>
|
||||||
</UniformGrid>
|
</UniformGrid>
|
||||||
|
|
||||||
<Button Name="RemovePartBtn" Grid.ColumnSpan="3" Grid.Row="6" Style="{DynamicResource OmagCut_YellowIconButton}">
|
<UniformGrid Name ="UG1" Grid.Column="0" Grid.Row="6" Grid.ColumnSpan="3" Columns="2" >
|
||||||
<Image Source="{DynamicResource Elimina-pezzoImg}" Style="{StaticResource OmagCut_ArrowButtonIcon}"/>
|
<Button Name="RemovePartBtn" Style="{DynamicResource OmagCut_YellowIconButton}">
|
||||||
</Button>
|
<Image Source="{DynamicResource Elimina-pezzoImg}" Style="{StaticResource OmagCut_ArrowButtonIcon}"/>
|
||||||
|
</Button>
|
||||||
|
<ToggleButton Name="DragRettanleBtn" Style="{DynamicResource OmagCut_YellowIconToggleButton}">
|
||||||
|
<Image Source="{DynamicResource Drag_RettangleImg}" Style="{StaticResource OmagCut_ArrowButtonIcon}"/>
|
||||||
|
</ToggleButton>
|
||||||
|
</UniformGrid>
|
||||||
|
|
||||||
<UniformGrid Grid.Column="0" Grid.Row="7" Grid.ColumnSpan="3" Columns="2" >
|
<UniformGrid Grid.Column="0" Grid.Row="7" Grid.ColumnSpan="3" Columns="2" >
|
||||||
<Button Name="SelectAllBtn" Style="{DynamicResource OmagCut_YellowIconButton}">
|
<Button Name="SelectAllBtn" Style="{DynamicResource OmagCut_YellowIconButton}">
|
||||||
|
|||||||
+387
-26
@@ -12,10 +12,27 @@ Public Class NestPageUC
|
|||||||
Friend m_bRegister As Boolean = False
|
Friend m_bRegister As Boolean = False
|
||||||
' Flag per pezzi selezionati in tavola o fuori
|
' Flag per pezzi selezionati in tavola o fuori
|
||||||
Private m_nPartPos As Integer = PART_POS.NONE_TABLE
|
Private m_nPartPos As Integer = PART_POS.NONE_TABLE
|
||||||
|
' Flag per impostata per selezionare di una curva
|
||||||
|
Friend m_bSelectCurv As Boolean = False
|
||||||
|
' dati per DragRettangoli (estensio/accorciamento dei rettangoli trascinando un lato)
|
||||||
|
Private m_bIsVisibleDragRettangle As Boolean = False
|
||||||
|
Friend m_bIsCheckedDragRettangle As Boolean = False
|
||||||
|
|
||||||
|
' Id della curva e del taglio selezionati per eseguire il test
|
||||||
Friend m_CurrSelectedCurv As Integer = GDB_ID.NULL
|
Friend m_CurrSelectedCurv As Integer = GDB_ID.NULL
|
||||||
Friend m_CurrSelectedSawCurv As Integer = GDB_ID.NULL
|
Friend m_CurrSelectedSawCurv As Integer = GDB_ID.NULL
|
||||||
|
|
||||||
|
' Id del rettangolo, del traglio e della curva da modificare tramite Drag
|
||||||
|
Private m_nIdSelectedOutLoopRettangle As Integer = GDB_ID.NULL
|
||||||
|
Private m_nIdSelectedRegionRettangle As Integer = GDB_ID.NULL
|
||||||
|
Private m_nIdSelectedSawRettangle As Integer = GDB_ID.NULL
|
||||||
|
Private m_nIdSelectedCurvRettangle As Integer = GDB_ID.NULL
|
||||||
|
Private m_nIdSelectedTextRettangle As Integer = GDB_ID.NULL
|
||||||
|
Private m_nIdSelectedTextTopRettangle As Integer = GDB_ID.NULL
|
||||||
|
Private m_nIdSelectedFlatSurfRettangle As Integer = GDB_ID.NULL
|
||||||
|
Private m_SideListRettangle(4) As Integer
|
||||||
|
Private m_sTextContent As String = String.Empty
|
||||||
|
|
||||||
Enum PART_POS As Integer
|
Enum PART_POS As Integer
|
||||||
IN_TABLE = -1
|
IN_TABLE = -1
|
||||||
NONE_TABLE = 0
|
NONE_TABLE = 0
|
||||||
@@ -61,6 +78,14 @@ Public Class NestPageUC
|
|||||||
RemovePartBtn.ToolTip = EgtMsg(MSG_NESTPAGEUC + 3) 'Remove part - Elimina pezzo
|
RemovePartBtn.ToolTip = EgtMsg(MSG_NESTPAGEUC + 3) 'Remove part - Elimina pezzo
|
||||||
SelectAllBtn.ToolTip = EgtMsg(MSG_NESTPAGEUC + 4) 'Select All - Seleziona Tutto
|
SelectAllBtn.ToolTip = EgtMsg(MSG_NESTPAGEUC + 4) 'Select All - Seleziona Tutto
|
||||||
DeselectAllBtn.ToolTip = EgtMsg(MSG_NESTPAGEUC + 5) 'Deselect All - Deseleziona Tutto
|
DeselectAllBtn.ToolTip = EgtMsg(MSG_NESTPAGEUC + 5) 'Deselect All - Deseleziona Tutto
|
||||||
|
|
||||||
|
' gestisco la visualizzazione del comando PAN (per il drag dei rettangoli)
|
||||||
|
m_bIsVisibleDragRettangle = (GetPrivateProfileInt(S_NEST, K_DRAG_RETTANGLE, 0, m_MainWindow.GetIniFile()) <> 0)
|
||||||
|
If Not m_bIsVisibleDragRettangle Then
|
||||||
|
UG1.Columns = 1
|
||||||
|
DragRettanleBtn.Visibility = Visibility.Collapsed
|
||||||
|
End If
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub NestPage_Loaded(sender As Object, e As RoutedEventArgs)
|
Private Sub NestPage_Loaded(sender As Object, e As RoutedEventArgs)
|
||||||
@@ -108,6 +133,7 @@ Public Class NestPageUC
|
|||||||
m_dRegStep = GetPrivateProfileDouble(S_REG, K_REGSTEP, 10, m_MainWindow.GetIniFile())
|
m_dRegStep = GetPrivateProfileDouble(S_REG, K_REGSTEP, 10, m_MainWindow.GetIniFile())
|
||||||
m_dRegAngStep = GetPrivateProfileDouble(S_REG, K_REGANGSTEP, 1, m_MainWindow.GetIniFile())
|
m_dRegAngStep = GetPrivateProfileDouble(S_REG, K_REGANGSTEP, 1, m_MainWindow.GetIniFile())
|
||||||
m_dMaxRegAng = GetPrivateProfileDouble(S_MACH_REG, K_MACH_MAX_ROT_ANG, 10, m_MainWindow.GetMachIniFile())
|
m_dMaxRegAng = GetPrivateProfileDouble(S_MACH_REG, K_MACH_MAX_ROT_ANG, 10, m_MainWindow.GetMachIniFile())
|
||||||
|
|
||||||
' Garantisco visibilità pezzi parcheggiati
|
' Garantisco visibilità pezzi parcheggiati
|
||||||
ShowParkedParts()
|
ShowParkedParts()
|
||||||
' Garantisco visibilità eventuale contorno da foto
|
' Garantisco visibilità eventuale contorno da foto
|
||||||
@@ -124,14 +150,17 @@ Public Class NestPageUC
|
|||||||
End If
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub OnMyMouseDownSceneSelCurv(sender As Object, e As System.Windows.Forms.MouseEventArgs) Handles m_CurrProjPage.OnMouseDownSceneSelCurv
|
' funzione utilizzata per la selezione dei tagli quando il comando TEST è attivo
|
||||||
|
Private Sub OnMyMouseDownSceneSelCurv(sender As Object, e As System.Windows.Forms.MouseEventArgs)
|
||||||
' Verifico di essere il gestore attivo e non in modalità registrazione
|
' Verifico di essere il gestore attivo e non in modalità registrazione
|
||||||
If Not m_bActive Or m_bRegister Then Return
|
If Not m_bActive Or m_bRegister Then Return
|
||||||
' Si può selezionare solo con il tasto sinistro e se il bottone TEST Attivo
|
' Si può selezionare solo con il tasto sinistro e se il bottone TEST Attivo
|
||||||
If e.Button <> Windows.Forms.MouseButtons.Left Or
|
If e.Button <> Windows.Forms.MouseButtons.Left Or
|
||||||
Not m_CurrProjPage.m_bSelectCurv Then
|
Not m_bSelectCurv Then
|
||||||
Return
|
Return
|
||||||
End If
|
End If
|
||||||
|
' Se esiste un elemento selezionato
|
||||||
|
EgtResetMark(m_CurrSelectedSawCurv)
|
||||||
' provo a riconoscere il valore medio del segmento
|
' provo a riconoscere il valore medio del segmento
|
||||||
' Verifico se selezionato indicativo di pezzo
|
' Verifico se selezionato indicativo di pezzo
|
||||||
EgtSetObjFilterForSelWin(False, True, False, False, False)
|
EgtSetObjFilterForSelWin(False, True, False, False, False)
|
||||||
@@ -152,7 +181,6 @@ Public Class NestPageUC
|
|||||||
Dim ptE As Point3d
|
Dim ptE As Point3d
|
||||||
EgtEndPoint(nIdMy, ptE)
|
EgtEndPoint(nIdMy, ptE)
|
||||||
If m_CurrSelectedCurv <> GDB_ID.NULL Or m_CurrSelectedCurv = nIdMy Then
|
If m_CurrSelectedCurv <> GDB_ID.NULL Or m_CurrSelectedCurv = nIdMy Then
|
||||||
EgtDeselectObj(m_CurrSelectedSawCurv)
|
|
||||||
EgtDeselectObj(m_CurrSelectedCurv)
|
EgtDeselectObj(m_CurrSelectedCurv)
|
||||||
End If
|
End If
|
||||||
' recupero il gruppo della lavorazione associata
|
' recupero il gruppo della lavorazione associata
|
||||||
@@ -160,10 +188,9 @@ Public Class NestPageUC
|
|||||||
Dim nIdPV As Integer = EgtGetFirstNameInGroup(nIdParentPart, "PV")
|
Dim nIdPV As Integer = EgtGetFirstNameInGroup(nIdParentPart, "PV")
|
||||||
Dim nIdSaw As Integer = EgtGetFirstNameInGroup(nIdPV, "Saw" & nIdMy.ToString)
|
Dim nIdSaw As Integer = EgtGetFirstNameInGroup(nIdPV, "Saw" & nIdMy.ToString)
|
||||||
If Not EgtGetGroupObjs(nIdSaw) Then
|
If Not EgtGetGroupObjs(nIdSaw) Then
|
||||||
EgtSelectObj(nIdSaw)
|
|
||||||
m_CurrSelectedSawCurv = nIdSaw
|
m_CurrSelectedSawCurv = nIdSaw
|
||||||
m_CurrSelectedCurv = nIdMy
|
m_CurrSelectedCurv = nIdMy
|
||||||
EgtSelectObj(nIdSaw)
|
EgtSetMark(nIdSaw)
|
||||||
EgtSelectObj(nIdMy)
|
EgtSelectObj(nIdMy)
|
||||||
EgtDraw()
|
EgtDraw()
|
||||||
Exit While
|
Exit While
|
||||||
@@ -176,6 +203,293 @@ Public Class NestPageUC
|
|||||||
Return
|
Return
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
#Region "DRAG RETTANGLE"
|
||||||
|
|
||||||
|
' funzione chiamata da OnMyMouseMoveScene: verifica che la selezione sia corretta (deve essere il lato di una figura rettangolare)
|
||||||
|
Private Sub OnMyMouseDownSceneSelSideRettangle(sender As Object, e As System.Windows.Forms.MouseEventArgs)
|
||||||
|
' Verifico di essere il gestore attivo e non in modalità registrazione
|
||||||
|
If Not m_bActive Or m_bRegister Then Return
|
||||||
|
' Si può selezionare solo con il tasto sinistro e se il bottone TEST Attivo
|
||||||
|
If e.Button <> Windows.Forms.MouseButtons.Left then
|
||||||
|
Return
|
||||||
|
End If
|
||||||
|
' Verifico se selezionato indicativo di pezzo
|
||||||
|
EgtSetObjFilterForSelWin(False, True, False, False, False)
|
||||||
|
Dim nSelMy As Integer
|
||||||
|
EgtSelect(e.Location, Scene.DIM_SEL, Scene.DIM_SEL, nSelMy)
|
||||||
|
Dim nIdMy As Integer = EgtGetFirstObjInSelWin()
|
||||||
|
While nIdMy <> GDB_ID.NULL
|
||||||
|
Dim sLayer As String = String.Empty
|
||||||
|
' layer di origine
|
||||||
|
Dim nIdParent As Integer = EgtGetParent(nIdMy)
|
||||||
|
' recupero il nome del Layer
|
||||||
|
EgtGetName(nIdParent, sLayer)
|
||||||
|
' solo se il nome del layer è quello associato ad un lato esterno allora procedo con l'evidenziazione
|
||||||
|
If sLayer = NAME_OUTLOOP Then
|
||||||
|
If EgtGetType(nIdMy) = GDB_TY.CRV_LINE Then
|
||||||
|
' -------------------------------- INIZIO VERIFICHE --------------------------------
|
||||||
|
m_nIdSelectedOutLoopRettangle = nIdParent
|
||||||
|
If Not IsRettangle(m_SideListRettangle) Then
|
||||||
|
m_CurrProjPage.ClearMessage()
|
||||||
|
m_CurrProjPage.SetWarningMessage("Non è un rettangolo (0)")
|
||||||
|
Return
|
||||||
|
End If
|
||||||
|
' recupero il gruppo della lavorazione associata
|
||||||
|
Dim nIdParentPart As Integer = EgtGetParent(nIdParent)
|
||||||
|
Dim nIdPV As Integer = EgtGetFirstNameInGroup(nIdParentPart, "PV")
|
||||||
|
' se non esiste un gruppo di lavorazione associato allora esco
|
||||||
|
If nIdPV = GDB_ID.NULL Then
|
||||||
|
m_CurrProjPage.ClearMessage()
|
||||||
|
m_CurrProjPage.SetWarningMessage("Pezzo in parcheggio (1)")
|
||||||
|
Return
|
||||||
|
End If
|
||||||
|
' se esiste ma è vuoto (pezzo scaricato da tavola)
|
||||||
|
If EgtGetFirstInGroup(nIdPV) = GDB_ID.NULL Then
|
||||||
|
m_CurrProjPage.ClearMessage()
|
||||||
|
m_CurrProjPage.SetWarningMessage("Pezzo in parcheggio (2)")
|
||||||
|
Return
|
||||||
|
End If
|
||||||
|
' Devo verificare che sia una lavorazione solo di lama?
|
||||||
|
Dim nIdSaw As Integer = EgtGetFirstNameInGroup(nIdPV, "Saw" & nIdMy.ToString)
|
||||||
|
' -------------------------------- FINE VERIFICHE --------------------------------
|
||||||
|
|
||||||
|
If Not EgtGetGroupObjs(nIdSaw) Then
|
||||||
|
m_nIdSelectedSawRettangle = nIdSaw
|
||||||
|
m_nIdSelectedCurvRettangle = nIdMy
|
||||||
|
|
||||||
|
m_nIdSelectedRegionRettangle = EgtGetFirstNameInGroup(nIdParentPart, NAME_REGION)
|
||||||
|
' recupero i testi cintenuti nel layer Region
|
||||||
|
If m_nIdSelectedRegionRettangle <> GDB_ID.NULL Then
|
||||||
|
Dim nCurrId As Integer = EgtGetFirstInGroup(m_nIdSelectedRegionRettangle)
|
||||||
|
While nCurrId <> GDB_ID.NULL
|
||||||
|
If EgtGetType(nCurrId) = GDB_TY.EXT_TEXT Then
|
||||||
|
Dim sVal As String = String.Empty
|
||||||
|
EgtTextGetContent(nCurrId, sVal)
|
||||||
|
If sVal = "*TOP*" Then
|
||||||
|
m_nIdSelectedTextTopRettangle = nCurrId
|
||||||
|
Else
|
||||||
|
m_nIdSelectedTextRettangle = nCurrId
|
||||||
|
m_sTextContent = GetMyRettangleText(sVal)
|
||||||
|
End If
|
||||||
|
ElseIf EgtGetType(nCurrId) = GDB_TY.SRF_FRGN Then
|
||||||
|
m_nIdSelectedFlatSurfRettangle = nCurrId
|
||||||
|
End If
|
||||||
|
nCurrId = EgtGetNext(nCurrId)
|
||||||
|
End While
|
||||||
|
End If
|
||||||
|
' seleziono ed evidenzio il lato selezionato
|
||||||
|
EgtSelectObj(nIdSaw)
|
||||||
|
EgtSetMark(nIdSaw)
|
||||||
|
EgtSelectObj(nIdMy)
|
||||||
|
EgtDraw()
|
||||||
|
Exit While
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
' se le'elemto corrente non è una linea
|
||||||
|
End If
|
||||||
|
' se le'elemto corrente non appartiene al layer OutLoop passo al prossimo elemento dell'elenco
|
||||||
|
nIdMy = EgtGetNextObjInSelWin()
|
||||||
|
End While
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
' restituisce il valore del Text ripulito dalle dimensioni
|
||||||
|
Private Function GetMyRettangleText(sTextPz As String) As String
|
||||||
|
' da DrawPageUC.xaml.vb/MultipleInsert
|
||||||
|
Dim sText As String = String.Empty
|
||||||
|
If sTextPz.Contains("<br/>") Then
|
||||||
|
Dim nLastIndex As Integer = sTextPz.LastIndexOf(">")
|
||||||
|
sText = sTextPz.Remove(nLastIndex + 1)
|
||||||
|
Return sText
|
||||||
|
End If
|
||||||
|
If sTextPz.Contains(" ") Then
|
||||||
|
Dim sInfo() As String = sTextPz.Split(" ")
|
||||||
|
If sInfo.Count > 3 Then
|
||||||
|
Return sText = sInfo(0) & " " & sInfo(1) & " "
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
Return sText
|
||||||
|
End Function
|
||||||
|
|
||||||
|
' verifico che la figura selezionata sia realmente un rettangolo
|
||||||
|
Private Function IsRettangle(ByRef IdSideList() As Integer) As Boolean
|
||||||
|
' creo una lista con i lati del rettangolo
|
||||||
|
Dim nCounter As Integer = 0
|
||||||
|
' recupero i lati dal leyer "OutLoop"
|
||||||
|
Dim IdSideRettangle As Integer = EgtGetFirstInGroup(m_nIdSelectedOutLoopRettangle)
|
||||||
|
While IdSideRettangle <> GDB_ID.NULL And nCounter < 4
|
||||||
|
Dim sVal As String = String.Empty
|
||||||
|
Dim dPrevAng As Double = 0
|
||||||
|
EgtGetInfo(IdSideRettangle, "PrevAng", sVal)
|
||||||
|
StringToDouble(sVal, dPrevAng)
|
||||||
|
Dim dNextAng As Double = 0
|
||||||
|
EgtGetInfo(IdSideRettangle, "NextAng", sVal)
|
||||||
|
StringToDouble(sVal, dNextAng)
|
||||||
|
' se gli angoli non sono retti allora esco senza caricare il lato corrente
|
||||||
|
If Math.Abs(dPrevAng - 90) > EPS_ANG_SMALL OrElse Math.Abs(dNextAng - 90) > EPS_ANG_SMALL Then
|
||||||
|
Exit While
|
||||||
|
End If
|
||||||
|
IdSideList(nCounter) = IdSideRettangle
|
||||||
|
nCounter += 1
|
||||||
|
IdSideRettangle = EgtGetNext(IdSideRettangle)
|
||||||
|
End While
|
||||||
|
' verifico che siano solo quattro lati
|
||||||
|
If IdSideRettangle = GDB_ID.NULL And nCounter = 4 Then
|
||||||
|
' solo se la figura ha 4 lati ortogonali
|
||||||
|
Return True
|
||||||
|
End If
|
||||||
|
|
||||||
|
m_nIdSelectedOutLoopRettangle = GDB_ID.NULL
|
||||||
|
' la figura presenta più/meno di 4 lati
|
||||||
|
Return False
|
||||||
|
End Function
|
||||||
|
|
||||||
|
' recupero le informazioni correnti per sapere se la figura è mdificabile
|
||||||
|
Private Function GetRettangleInfoScale(ByRef frFixed As Frame3d, ByRef MaxLen As Double, ByRef MinLen As Double) As Vector3d
|
||||||
|
' determino la direzione del lato selezionato
|
||||||
|
Dim vtDirSelectedCurv As New Vector3d
|
||||||
|
EgtStartVector(m_nIdSelectedCurvRettangle, GDB_ID.ROOT, vtDirSelectedCurv)
|
||||||
|
|
||||||
|
' recupero il lato successivo a quello selezionato
|
||||||
|
Dim Index As Integer = 0
|
||||||
|
Dim Len As Double = 0
|
||||||
|
For Ind As Integer = 0 To 3
|
||||||
|
If m_SideListRettangle(Ind) = m_nIdSelectedCurvRettangle Then
|
||||||
|
' verifico se esiste un lato Precedente altrimenti recupero l'ultimo della lista
|
||||||
|
If Ind = 0 Then
|
||||||
|
Index = 3
|
||||||
|
Else
|
||||||
|
Index = Ind - 1
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
' recupero la dimensione del lato
|
||||||
|
EgtCurveLength(m_SideListRettangle(Index), MaxLen)
|
||||||
|
EgtCurveLength(m_nIdSelectedCurvRettangle, MinLen)
|
||||||
|
|
||||||
|
' verifico che il lato selezionato sia il maggiore
|
||||||
|
If MinLen > MaxLen Then Return Nothing
|
||||||
|
|
||||||
|
' determimo il versore dal lato appena calcolato
|
||||||
|
Dim vtDir As New Vector3d
|
||||||
|
|
||||||
|
EgtStartVector(m_SideListRettangle(Index), GDB_ID.ROOT, vtDir)
|
||||||
|
vtDir.Normalize()
|
||||||
|
Dim dProjectionBaseX As Double = vtDir * Vector3d.X_AX
|
||||||
|
Dim ptFixed As New Point3d
|
||||||
|
EgtStartPoint(m_SideListRettangle(Index), GDB_ID.ROOT, ptFixed)
|
||||||
|
|
||||||
|
Dim vtPerp As New Vector3d(vtDir.x, vtDir.y, vtDir.z)
|
||||||
|
vtPerp.Rotate(Vector3d.Z_AX, 90)
|
||||||
|
|
||||||
|
' determino il Frame corrente
|
||||||
|
frFixed = New Frame3d(ptFixed, vtDir, vtPerp, Vector3d.Z_AX)
|
||||||
|
|
||||||
|
Return vtDir
|
||||||
|
|
||||||
|
End Function
|
||||||
|
|
||||||
|
' funzione chiamata da OnMyMouseMoveScene: gestisce la modifica lungo una dimensione del rettangolo selezionato
|
||||||
|
Private Sub OnMyMouseMoveSawRettangle(sender As Object, e As System.Windows.Forms.MouseEventArgs)
|
||||||
|
' Verifico di essere il gestore attivo
|
||||||
|
If Not m_bActive Then Return
|
||||||
|
' Se drag non abilitato o già in esecuzione, esco
|
||||||
|
If Not m_bDrag Or m_bDragging Then Return
|
||||||
|
' Se primo movimento di drag, verifico di aver superato la soglia di movimento in pixel
|
||||||
|
If m_bDragToStart Then
|
||||||
|
If Math.Abs(e.Location.X - m_locPrev.X) < m_nRestRadius And
|
||||||
|
Math.Abs(e.Location.Y - m_locPrev.Y) < m_nRestRadius Then
|
||||||
|
Return
|
||||||
|
End If
|
||||||
|
m_bDragToStart = False
|
||||||
|
End If
|
||||||
|
|
||||||
|
' riferiemento che deve rimanere fisso del rettangolo
|
||||||
|
Dim frFixed As Frame3d = Nothing
|
||||||
|
' lunghezza del lato da modificare
|
||||||
|
Dim MaxLen As Double = 0
|
||||||
|
Dim MinLen As Double = 0
|
||||||
|
' recupero info sul rettangolo selezionato
|
||||||
|
Dim vtDir As Vector3d = GetRettangleInfoScale(frFixed, MaxLen, MinLen)
|
||||||
|
If vtDir.Equals(Vector3d.NULL) Then
|
||||||
|
Return
|
||||||
|
End If
|
||||||
|
|
||||||
|
' Inizio esecuzione di drag
|
||||||
|
m_bDragging = True
|
||||||
|
|
||||||
|
' Ricavo il punto corrente in coordinate mondo
|
||||||
|
Dim ptCurr As Point3d
|
||||||
|
EgtUnProjectPoint(e.Location, ptCurr)
|
||||||
|
' Ricavo il vettore di movimento
|
||||||
|
Dim vtMove As Vector3d = ptCurr - m_ptPrev
|
||||||
|
' ricavo il valore efficace di allungamento (la proiezione)
|
||||||
|
Dim dProjection As Double = vtMove * vtDir
|
||||||
|
vtMove = vtDir * dProjection
|
||||||
|
' recupero il valore di scalatura
|
||||||
|
Dim dScalefactor = dProjection / MaxLen + 1
|
||||||
|
|
||||||
|
' Modifico dimensione figura
|
||||||
|
If Math.Abs(dScalefactor) > EPS_SMALL * EPS_SMALL Then
|
||||||
|
EgtScale(m_nIdSelectedOutLoopRettangle, frFixed, dScalefactor, 1, 1, GDB_ID.ROOT)
|
||||||
|
EgtScale(m_nIdSelectedFlatSurfRettangle, frFixed, dScalefactor, 1, 1, GDB_ID.ROOT)
|
||||||
|
Dim ptCen As Point3d
|
||||||
|
EgtCenterPoint(m_nIdSelectedTextRettangle, ptCen)
|
||||||
|
EgtModifyText(m_nIdSelectedTextRettangle, m_sTextContent & LenToString(MaxLen + dProjection, 2) & " x " & LenToString(MinLen, 2))
|
||||||
|
EgtMove(m_nIdSelectedTextRettangle, vtMove * 0.5)
|
||||||
|
If m_nIdSelectedTextTopRettangle <> GDB_ID.NULL Then
|
||||||
|
EgtMove(m_nIdSelectedTextTopRettangle, vtMove * 0.5)
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
|
Dim nWarn As Integer = 0
|
||||||
|
ResetAllMachinings(nWarn)
|
||||||
|
EnableReferenceRegion(False)
|
||||||
|
' se la modifica genera un errore allora ripristino la figura prima della defomrazione
|
||||||
|
If Not EgtVerifyPart(EgtGetParent(m_nIdSelectedOutLoopRettangle), True) Then
|
||||||
|
EgtScale(m_nIdSelectedOutLoopRettangle, frFixed, 1 / dScalefactor, 1, 1, GDB_ID.ROOT)
|
||||||
|
EgtScale(m_nIdSelectedFlatSurfRettangle, frFixed, 1 / dScalefactor, 1, 1, GDB_ID.ROOT)
|
||||||
|
Dim ptCen As Point3d
|
||||||
|
EgtCenterPoint(m_nIdSelectedTextRettangle, ptCen)
|
||||||
|
EgtModifyText(m_nIdSelectedTextRettangle, m_sTextContent & LenToString(MaxLen, 2) & " x " & LenToString(MinLen, 2))
|
||||||
|
EgtMove(m_nIdSelectedTextRettangle, -vtMove * 0.5)
|
||||||
|
If m_nIdSelectedTextTopRettangle <> GDB_ID.NULL Then
|
||||||
|
EgtMove(m_nIdSelectedTextTopRettangle, -vtMove * 0.5)
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
|
EgtDraw()
|
||||||
|
' Aggiorno il punto precedente
|
||||||
|
m_ptPrev = ptCurr
|
||||||
|
' Terminata esecuzione di drag
|
||||||
|
m_bDragging = False
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
' funzione chiamata da OnMyMouseUp: gestisce il reset di tutti gli indici in uso
|
||||||
|
Public Sub ResetDragRettangleParam()
|
||||||
|
' deseleziono l'elemento corrente
|
||||||
|
EgtDeselectObj(m_nIdSelectedSawRettangle)
|
||||||
|
EgtDeselectObj(m_nIdSelectedCurvRettangle)
|
||||||
|
EgtResetMark(m_nIdSelectedSawRettangle)
|
||||||
|
' resetto gli indici
|
||||||
|
m_nIdSelectedOutLoopRettangle = GDB_ID.NULL
|
||||||
|
m_nIdSelectedRegionRettangle = GDB_ID.NULL
|
||||||
|
m_nIdSelectedSawRettangle = GDB_ID.NULL
|
||||||
|
m_nIdSelectedCurvRettangle = GDB_ID.NULL
|
||||||
|
m_nIdSelectedTextRettangle = GDB_ID.NULL
|
||||||
|
m_nIdSelectedTextTopRettangle = GDB_ID.NULL
|
||||||
|
m_nIdSelectedFlatSurfRettangle = GDB_ID.NULL
|
||||||
|
m_SideListRettangle = {GDB_ID.NULL, GDB_ID.NULL, GDB_ID.NULL, GDB_ID.NULL}
|
||||||
|
m_sTextContent = String.Empty
|
||||||
|
' disattivo il drag
|
||||||
|
m_bDrag = False
|
||||||
|
' aggiorno le lavorazioni
|
||||||
|
Dim nWarn As Integer = 0
|
||||||
|
ResetAllMachinings(nWarn)
|
||||||
|
EgtDraw()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
#End Region ' Drag Rettangolo
|
||||||
|
|
||||||
Private Sub OnMyMouseDownScene(sender As Object, e As System.Windows.Forms.MouseEventArgs) Handles m_CurrProjPage.OnMouseDownScene
|
Private Sub OnMyMouseDownScene(sender As Object, e As System.Windows.Forms.MouseEventArgs) Handles m_CurrProjPage.OnMouseDownScene
|
||||||
' Verifico di essere il gestore attivo e non in modalità registrazione
|
' Verifico di essere il gestore attivo e non in modalità registrazione
|
||||||
If Not m_bActive Or m_bRegister Then Return
|
If Not m_bActive Or m_bRegister Then Return
|
||||||
@@ -184,6 +498,25 @@ Public Class NestPageUC
|
|||||||
Not m_CurrProjPage.CurrentProjectScene.IsStatusNull() Then
|
Not m_CurrProjPage.CurrentProjectScene.IsStatusNull() Then
|
||||||
Return
|
Return
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
' se in modalità slezione tagli
|
||||||
|
If m_bSelectCurv Then
|
||||||
|
OnMyMouseDownSceneSelCurv(sender, e)
|
||||||
|
Return
|
||||||
|
End If
|
||||||
|
|
||||||
|
' se in modalità DragRettangle (deformazione delle componenti rettangolari)
|
||||||
|
If m_bIsCheckedDragRettangle Then
|
||||||
|
OnMyMouseDownSceneSelSideRettangle(sender, e)
|
||||||
|
' Dati per drag (abilito il Drag)
|
||||||
|
m_locPrev = e.Location
|
||||||
|
m_bDrag = EgtUnProjectPoint(e.Location, m_ptPrev) And m_nIdSelectedCurvRettangle <> GDB_ID.NULL
|
||||||
|
m_bDragToStart = m_bDrag
|
||||||
|
m_bVerify = m_bDrag AndAlso (Keyboard.Modifiers And ModifierKeys.Shift) > 0
|
||||||
|
m_vtTotMove = Vector3d.NULL()
|
||||||
|
Return
|
||||||
|
End If
|
||||||
|
|
||||||
' Per default no drag
|
' Per default no drag
|
||||||
m_bDrag = False
|
m_bDrag = False
|
||||||
' Verifico se selezionato indicativo di pezzo
|
' Verifico se selezionato indicativo di pezzo
|
||||||
@@ -218,15 +551,15 @@ Public Class NestPageUC
|
|||||||
' se non è stata eseguita nessuna scelta esco dal ciclo
|
' se non è stata eseguita nessuna scelta esco dal ciclo
|
||||||
If nRes = 0 Then Exit While
|
If nRes = 0 Then Exit While
|
||||||
' imposto l'altra tavola
|
' imposto l'altra tavola
|
||||||
Dim sOtherTab = If( sNamePartId = MAIN_TAB, SECOND_TAB, MAIN_TAB)
|
Dim sOtherTab = If(sNamePartId = MAIN_TAB, SECOND_TAB, MAIN_TAB)
|
||||||
EgtChangeTable( sOtherTab, True)
|
EgtChangeTable(sOtherTab, True)
|
||||||
m_CurrProjPage.AdjustAdditionalTable( True)
|
m_CurrProjPage.AdjustAdditionalTable(True)
|
||||||
EgtSetMachineLook(MCH_LOOK.TAB)
|
EgtSetMachineLook(MCH_LOOK.TAB)
|
||||||
' aggiorno le lavorazioni
|
' aggiorno le lavorazioni
|
||||||
UpdateAllMachiningsToolpaths()
|
UpdateAllMachiningsToolpaths()
|
||||||
' aggiorno i movimenti pezzi tra disposizioni
|
' aggiorno i movimenti pezzi tra disposizioni
|
||||||
For nI As Integer = 1 To EgtGetPhaseCount()
|
For nI As Integer = 1 To EgtGetPhaseCount()
|
||||||
EgtSetCurrPhase( nI)
|
EgtSetCurrPhase(nI)
|
||||||
Dim nDispId As Integer = EgtGetPhaseDisposition(nI)
|
Dim nDispId As Integer = EgtGetPhaseDisposition(nI)
|
||||||
SpecialApplyDisposition(nDispId, True)
|
SpecialApplyDisposition(nDispId, True)
|
||||||
Next
|
Next
|
||||||
@@ -239,31 +572,31 @@ Public Class NestPageUC
|
|||||||
Dim nPPId As Integer = EgtGetFirstPart()
|
Dim nPPId As Integer = EgtGetFirstPart()
|
||||||
While nPPId <> GDB_ID.NULL
|
While nPPId <> GDB_ID.NULL
|
||||||
PackPartInStore(nPPId)
|
PackPartInStore(nPPId)
|
||||||
nPPId = EgtGetNextPart( nPPId)
|
nPPId = EgtGetNextPart(nPPId)
|
||||||
End While
|
End While
|
||||||
' se prevista rotazione
|
' se prevista rotazione
|
||||||
If GetPrivateProfileInt(S_TABLE, K_CHANGETABWD, 0, m_MainWindow.GetMachIniFile()) = 2 Then
|
If GetPrivateProfileInt(S_TABLE, K_CHANGETABWD, 0, m_MainWindow.GetMachIniFile()) = 2 Then
|
||||||
' Dati tavola
|
' Dati tavola
|
||||||
Dim b3Tab As New BBox3d
|
Dim b3Tab As New BBox3d
|
||||||
EgtGetTableArea( 1, b3Tab)
|
EgtGetTableArea(1, b3Tab)
|
||||||
' Box lastra
|
' Box lastra
|
||||||
Dim b3OrigRaw As New BBox3d
|
Dim b3OrigRaw As New BBox3d
|
||||||
GetRawBox( b3OrigRaw)
|
GetRawBox(b3OrigRaw)
|
||||||
' Allargo i limiti della tavola in tutte le fasi
|
' Allargo i limiti della tavola in tutte le fasi
|
||||||
Const TAB_OFFS As Double = 3000
|
Const TAB_OFFS As Double = 3000
|
||||||
For nI As Integer = 1 To EgtGetPhaseCount()
|
For nI As Integer = 1 To EgtGetPhaseCount()
|
||||||
EgtSetCurrPhase(nI)
|
EgtSetCurrPhase(nI)
|
||||||
EgtSetTableAreaOffset( TAB_OFFS, TAB_OFFS, TAB_OFFS, TAB_OFFS)
|
EgtSetTableAreaOffset(TAB_OFFS, TAB_OFFS, TAB_OFFS, TAB_OFFS)
|
||||||
Next
|
Next
|
||||||
EgtSetCurrPhase(1)
|
EgtSetCurrPhase(1)
|
||||||
' Rotazione
|
' Rotazione
|
||||||
Dim dAngRot As Double = If(sOtherTab = SECOND_TAB, 180, -180)
|
Dim dAngRot As Double = If(sOtherTab = SECOND_TAB, 180, -180)
|
||||||
if Not RotateAllRawParts(dAngRot, False) Then
|
If Not RotateAllRawParts(dAngRot, False) Then
|
||||||
m_CurrProjPage.SetWarningMessage(EgtMsg(90339)) 'Rotazione impossibile
|
m_CurrProjPage.SetWarningMessage(EgtMsg(90339)) 'Rotazione impossibile
|
||||||
End If
|
End If
|
||||||
' Traslazione per riportare la lastra nella stessa posizione rispetto all'angolo BL che diveta TR e viceversa
|
' Traslazione per riportare la lastra nella stessa posizione rispetto all'angolo BL che diveta TR e viceversa
|
||||||
Dim b3Raw As New BBox3d
|
Dim b3Raw As New BBox3d
|
||||||
GetRawBox( b3Raw)
|
GetRawBox(b3Raw)
|
||||||
Dim vtMove As Vector3d
|
Dim vtMove As Vector3d
|
||||||
If sOtherTab = SECOND_TAB Then
|
If sOtherTab = SECOND_TAB Then
|
||||||
Dim vtDiffIni As Vector3d = b3OrigRaw.Min() - b3Tab.Min()
|
Dim vtDiffIni As Vector3d = b3OrigRaw.Min() - b3Tab.Min()
|
||||||
@@ -272,14 +605,14 @@ Public Class NestPageUC
|
|||||||
Else
|
Else
|
||||||
Dim vtDiffIni As Vector3d = b3Tab.Max() - b3OrigRaw.Max()
|
Dim vtDiffIni As Vector3d = b3Tab.Max() - b3OrigRaw.Max()
|
||||||
Dim vtDiffFin As Vector3d = b3Raw.Min() - b3Tab.Min()
|
Dim vtDiffFin As Vector3d = b3Raw.Min() - b3Tab.Min()
|
||||||
vtMove = -( vtDiffFin - vtDiffIni)
|
vtMove = -(vtDiffFin - vtDiffIni)
|
||||||
End If
|
End If
|
||||||
vtMove.z = 0
|
vtMove.z = 0
|
||||||
MoveAllRawParts(vtMove)
|
MoveAllRawParts(vtMove)
|
||||||
' Ripristino i limiti della tavola in tutte le fasi
|
' Ripristino i limiti della tavola in tutte le fasi
|
||||||
For nI As Integer = 1 To EgtGetPhaseCount()
|
For nI As Integer = 1 To EgtGetPhaseCount()
|
||||||
EgtSetCurrPhase(nI)
|
EgtSetCurrPhase(nI)
|
||||||
EgtSetTableAreaOffset( 0, 0, 0, 0)
|
EgtSetTableAreaOffset(0, 0, 0, 0)
|
||||||
Next
|
Next
|
||||||
EgtSetCurrPhase(1)
|
EgtSetCurrPhase(1)
|
||||||
HideAllMachinings()
|
HideAllMachinings()
|
||||||
@@ -312,6 +645,13 @@ Public Class NestPageUC
|
|||||||
End If
|
End If
|
||||||
m_bDragToStart = False
|
m_bDragToStart = False
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
' se devo muovere un lato del rettangolo
|
||||||
|
If m_bIsCheckedDragRettangle Then
|
||||||
|
OnMyMouseMoveSawRettangle(sender, e)
|
||||||
|
Return
|
||||||
|
End If
|
||||||
|
|
||||||
' Determino cosa muovere
|
' Determino cosa muovere
|
||||||
Dim nMoveId = If(m_nIdToSel <> GDB_ID.NULL, m_nIdToSel, GDB_ID.SEL)
|
Dim nMoveId = If(m_nIdToSel <> GDB_ID.NULL, m_nIdToSel, GDB_ID.SEL)
|
||||||
' Verifico se in tavola o in parcheggio
|
' Verifico se in tavola o in parcheggio
|
||||||
@@ -402,6 +742,15 @@ Public Class NestPageUC
|
|||||||
Private Sub OnMyMouseUpScene(sender As Object, e As System.Windows.Forms.MouseEventArgs) Handles m_CurrProjPage.OnMouseUpScene
|
Private Sub OnMyMouseUpScene(sender As Object, e As System.Windows.Forms.MouseEventArgs) Handles m_CurrProjPage.OnMouseUpScene
|
||||||
' Verifico di essere il gestore attivo
|
' Verifico di essere il gestore attivo
|
||||||
If Not m_bActive Then Return
|
If Not m_bActive Then Return
|
||||||
|
' verifico che non sia attivo il comando Test
|
||||||
|
If m_bSelectCurv Then Return
|
||||||
|
' verifico che non sia attivo il comando di Drag dei rettangoli
|
||||||
|
If m_bIsCheckedDragRettangle Then
|
||||||
|
' deseleziono gli oggeti, resetto le variabili usate, aggiorno il disegno
|
||||||
|
ResetDragRettangleParam()
|
||||||
|
Return
|
||||||
|
End If
|
||||||
|
|
||||||
' Se eseguito drag
|
' Se eseguito drag
|
||||||
If Not m_bDragToStart Then
|
If Not m_bDragToStart Then
|
||||||
' Se movimento con sola verifica finale
|
' Se movimento con sola verifica finale
|
||||||
@@ -412,16 +761,16 @@ Public Class NestPageUC
|
|||||||
UpdateNestRegions()
|
UpdateNestRegions()
|
||||||
EnableReferenceRegion(False)
|
EnableReferenceRegion(False)
|
||||||
' Eseguo verifica
|
' Eseguo verifica
|
||||||
If VerifyTrfData( nMoveId) And EgtVerifyPart( nMoveId, m_bReducedCut) Then
|
If VerifyTrfData(nMoveId) And EgtVerifyPart(nMoveId, m_bReducedCut) Then
|
||||||
m_CurrProjPage.ResetOrderMachiningFlag()
|
m_CurrProjPage.ResetOrderMachiningFlag()
|
||||||
' Non superata riporto alla posizione iniziale
|
' Non superata riporto alla posizione iniziale
|
||||||
Else
|
Else
|
||||||
If m_bFromParking Then
|
If m_bFromParking Then
|
||||||
m_CurrProjPage.ClearMessage()
|
m_CurrProjPage.ClearMessage()
|
||||||
PreRemoveOnePart( nMoveId)
|
PreRemoveOnePart(nMoveId)
|
||||||
VeinMatching.OnRemovePartFromRaw( nMoveId)
|
VeinMatching.OnRemovePartFromRaw(nMoveId)
|
||||||
Else
|
Else
|
||||||
EgtMove( nMoveId, -m_vtTotMove)
|
EgtMove(nMoveId, -m_vtTotMove)
|
||||||
' Eventuale notifica al VeinMatching
|
' Eventuale notifica al VeinMatching
|
||||||
If nMoveId = GDB_ID.SEL Then
|
If nMoveId = GDB_ID.SEL Then
|
||||||
Dim nId As Integer = EgtGetFirstSelectedObj()
|
Dim nId As Integer = EgtGetFirstSelectedObj()
|
||||||
@@ -435,11 +784,11 @@ Public Class NestPageUC
|
|||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
m_bFromParking = False
|
m_bFromParking = False
|
||||||
' altrimenti caso con verifica durante il movimento
|
' altrimenti caso con verifica durante il movimento
|
||||||
Else
|
Else
|
||||||
' Basta reset alla fine
|
' Basta reset alla fine
|
||||||
End If
|
End If
|
||||||
' Se selezione da eseguire
|
' Se selezione da eseguire
|
||||||
ElseIf m_nIdToSel <> GDB_ID.NULL Then
|
ElseIf m_nIdToSel <> GDB_ID.NULL Then
|
||||||
' Determino se pezzo in tavola o in parcheggio
|
' Determino se pezzo in tavola o in parcheggio
|
||||||
Dim bPartInTable As Boolean = (EgtGetParent(m_nIdToSel) = m_nRawId)
|
Dim bPartInTable As Boolean = (EgtGetParent(m_nIdToSel) = m_nRawId)
|
||||||
@@ -456,7 +805,7 @@ Public Class NestPageUC
|
|||||||
VeinMatching.OnSelectPart(m_nIdToSel)
|
VeinMatching.OnSelectPart(m_nIdToSel)
|
||||||
' Set flag posizione selezionati
|
' Set flag posizione selezionati
|
||||||
m_nPartPos = If(bPartInTable, PART_POS.IN_TABLE, PART_POS.OUT_TABLE)
|
m_nPartPos = If(bPartInTable, PART_POS.IN_TABLE, PART_POS.OUT_TABLE)
|
||||||
' Se deselezione da eseguire
|
' Se deselezione da eseguire
|
||||||
ElseIf m_nIdToDesel <> GDB_ID.NULL Then
|
ElseIf m_nIdToDesel <> GDB_ID.NULL Then
|
||||||
EgtDeselectObj(m_nIdToDesel)
|
EgtDeselectObj(m_nIdToDesel)
|
||||||
' Eventuale aggiornamento VeinMatching
|
' Eventuale aggiornamento VeinMatching
|
||||||
@@ -1232,6 +1581,18 @@ Public Class NestPageUC
|
|||||||
Return True
|
Return True
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
|
Private Sub DragRettangle_Click() Handles DragRettanleBtn.Click
|
||||||
|
If DragRettanleBtn.IsChecked Then
|
||||||
|
m_bIsCheckedDragRettangle = True
|
||||||
|
Else
|
||||||
|
m_bIsCheckedDragRettangle = False
|
||||||
|
ResetDragRettangleParam()
|
||||||
|
m_CurrProjPage.ClearMessage()
|
||||||
|
ShowParkedParts()
|
||||||
|
End If
|
||||||
|
EgtDraw()
|
||||||
|
End Sub
|
||||||
|
|
||||||
Private Sub StorePartBtn_Click(sender As Object, e As RoutedEventArgs) Handles StorePartBtn.Click
|
Private Sub StorePartBtn_Click(sender As Object, e As RoutedEventArgs) Handles StorePartBtn.Click
|
||||||
EgtSetCurrentContext(m_CurrProjPage.CurrentProjectScene.GetCtx())
|
EgtSetCurrentContext(m_CurrProjPage.CurrentProjectScene.GetCtx())
|
||||||
' Ciclo di parcheggio dei pezzi selezionati
|
' Ciclo di parcheggio dei pezzi selezionati
|
||||||
|
|||||||
@@ -1191,8 +1191,8 @@ Public Class SplitPageUC
|
|||||||
UpdateMachiningPreview(m_MachiningList(nI).m_nId, True)
|
UpdateMachiningPreview(m_MachiningList(nI).m_nId, True)
|
||||||
bRepeat = Not UpdateMachiningPreview(m_MachiningList(nI).m_nId, True)
|
bRepeat = Not UpdateMachiningPreview(m_MachiningList(nI).m_nId, True)
|
||||||
If bRepeat Then
|
If bRepeat Then
|
||||||
EgtSetMachiningParam(MCH_MP.STARTADDLEN, dOrigUeal)
|
EgtSetMachiningParam(MCH_MP.ENDADDLEN, dOrigUeal)
|
||||||
EgtSetInfo(nOperId, INFO_MCH_USER_SAL, dOrigUeal)
|
EgtSetInfo(nOperId, INFO_MCH_USER_EAL, dOrigUeal)
|
||||||
dUeal = dOrigUeal
|
dUeal = dOrigUeal
|
||||||
End If
|
End If
|
||||||
Loop Until Not bRepeat
|
Loop Until Not bRepeat
|
||||||
|
|||||||
@@ -148,6 +148,7 @@ Module ConstIni
|
|||||||
Public Const K_TEXTCOLOR As String = "TextColor"
|
Public Const K_TEXTCOLOR As String = "TextColor"
|
||||||
Public Const K_AUTOMATICOPTIMIZE As String = "AutomaticOptimize"
|
Public Const K_AUTOMATICOPTIMIZE As String = "AutomaticOptimize"
|
||||||
Public Const K_AUTOMATICMAXTIME As String = "AutomaticMaxTime"
|
Public Const K_AUTOMATICMAXTIME As String = "AutomaticMaxTime"
|
||||||
|
Public Const K_DRAG_RETTANGLE As String = "DragRettangle"
|
||||||
|
|
||||||
Public Const S_SPLIT As String = "Split"
|
Public Const S_SPLIT As String = "Split"
|
||||||
Public Const K_MOVE_LEV As String = "MoveLevel"
|
Public Const K_MOVE_LEV As String = "MoveLevel"
|
||||||
|
|||||||
@@ -282,5 +282,6 @@
|
|||||||
Public Const S_MATERIALS As String = "Materials"
|
Public Const S_MATERIALS As String = "Materials"
|
||||||
Public Const K_CURRMATERIAL As String = "CurrMaterial"
|
Public Const K_CURRMATERIAL As String = "CurrMaterial"
|
||||||
Public Const K_MATERIAL As String = "Material"
|
Public Const K_MATERIAL As String = "Material"
|
||||||
|
Public Const K_FROMDBWATERJET As String = "FromDBWaterJet"
|
||||||
|
|
||||||
End Module
|
End Module
|
||||||
|
|||||||
@@ -133,25 +133,6 @@ Public Class DirectCutPageUC
|
|||||||
' leggo il numero di assi attivi nella macchina
|
' leggo il numero di assi attivi nella macchina
|
||||||
Dim AxesNumber = GetPrivateProfileInt(S_AXES, K_AXESNUM, 5, m_MainWindow.GetMachIniFile())
|
Dim AxesNumber = GetPrivateProfileInt(S_AXES, K_AXESNUM, 5, m_MainWindow.GetMachIniFile())
|
||||||
|
|
||||||
'' leggo se è stata configurata la nuova conole
|
|
||||||
'If GetPrivateProfileInt(S_NCDATA, K_NEWCONSOLE, 0, m_MainWindow.GetMachIniFile()) = 1 And Not bCollapsedNewBottonsConsole Then
|
|
||||||
' XYBtn.Content = "X - Y"
|
|
||||||
' XYBtn.Foreground = Brushes.White
|
|
||||||
' ZCBtn.Content = "Z - C"
|
|
||||||
' ZCBtn.Foreground = Brushes.White
|
|
||||||
' If AxesNumber < 5 Then
|
|
||||||
' ZBBtn.Visibility = Windows.Visibility.Collapsed
|
|
||||||
' End If
|
|
||||||
' ZBBtn.Content = "Z - B"
|
|
||||||
' ZBBtn.Foreground = Brushes.White
|
|
||||||
' RemoteBtn.Content = "Remote"
|
|
||||||
' RemoteBtn.Foreground = Brushes.White
|
|
||||||
'Else
|
|
||||||
' XYBtn.Visibility = Windows.Visibility.Collapsed
|
|
||||||
' ZCBtn.Visibility = Windows.Visibility.Collapsed
|
|
||||||
' ZBBtn.Visibility = Windows.Visibility.Collapsed
|
|
||||||
'End If
|
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub DirectCutPage_Loaded(sender As Object, e As RoutedEventArgs) Handles Me.Loaded
|
Private Sub DirectCutPage_Loaded(sender As Object, e As RoutedEventArgs) Handles Me.Loaded
|
||||||
@@ -228,8 +209,12 @@ Public Class DirectCutPageUC
|
|||||||
' Se macchina fotografica abilitata
|
' Se macchina fotografica abilitata
|
||||||
PhotoBtn.IsEnabled = m_MainWindow.GetKeyOption(MainWindow.KEY_OPT.MAN_PHOTO)
|
PhotoBtn.IsEnabled = m_MainWindow.GetKeyOption(MainWindow.KEY_OPT.MAN_PHOTO)
|
||||||
|
|
||||||
' Attivo le lavorazioni solo se esiste il grezzo
|
' Attivo le lavorazioni solo se esiste il grezzo e se presente testa H1
|
||||||
Dim bRawOk As Boolean = (GetRawHeight() > EPS_SMALL)
|
Dim bRawOk As Boolean = (GetRawHeight() > EPS_SMALL)
|
||||||
|
Dim bH1Exists As Boolean = (EgtGetHeadId("H1") <> GDB_ID.NULL)
|
||||||
|
|
||||||
|
ManualBtn.IsEnabled = bH1Exists
|
||||||
|
' sviluppo rimasto in sospeso
|
||||||
If m_bManulaCut Then
|
If m_bManulaCut Then
|
||||||
' anche se non è presente un grezzo mantengo abilitato il bottone
|
' anche se non è presente un grezzo mantengo abilitato il bottone
|
||||||
SingleCutBtn.IsEnabled = True
|
SingleCutBtn.IsEnabled = True
|
||||||
@@ -238,10 +223,14 @@ Public Class DirectCutPageUC
|
|||||||
End If
|
End If
|
||||||
MultipleCutBtn.IsEnabled = bRawOk
|
MultipleCutBtn.IsEnabled = bRawOk
|
||||||
GridCutBtn.IsEnabled = bRawOk
|
GridCutBtn.IsEnabled = bRawOk
|
||||||
SingleDrillBtn.IsEnabled = bRawOk
|
SingleDrillBtn.IsEnabled = (bRawOk And bH1Exists)
|
||||||
FlatteningCutBtn.IsEnabled = bRawOk
|
FlatteningCutBtn.IsEnabled = (bRawOk And bH1Exists)
|
||||||
PolishingBtn.IsEnabled = (bRawOk And m_MainWindow.m_CurrentMachine.bPolishing)
|
PolishingBtn.IsEnabled = (bRawOk And m_MainWindow.m_CurrentMachine.bPolishing)
|
||||||
SawTestBtn.IsEnabled = bRawOk
|
SawTestBtn.IsEnabled = (bRawOk And bH1Exists)
|
||||||
|
CopyTemplateBtn.IsEnabled = bH1Exists
|
||||||
|
|
||||||
|
' aggiorno la visualizzazione dei parametri
|
||||||
|
ReloadParam()
|
||||||
|
|
||||||
' Nascondo i pezzi in parcheggio
|
' Nascondo i pezzi in parcheggio
|
||||||
HideParkedParts()
|
HideParkedParts()
|
||||||
@@ -249,6 +238,20 @@ Public Class DirectCutPageUC
|
|||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Public Sub ReloadParam()
|
||||||
|
Dim sCurrSawing As String = m_MainWindow.m_CurrentMachine.sCurrSawing
|
||||||
|
Dim sCurrSaw As String = m_MainWindow.m_CurrentMachine.sCurrSaw
|
||||||
|
Dim bSaw As Boolean = False
|
||||||
|
|
||||||
|
' se esiste una lavorazione di lama corrente vuol dire che deve essere preferita
|
||||||
|
If Not String.IsNullOrEmpty(sCurrSaw) And Not String.IsNullOrEmpty(sCurrSawing) Then
|
||||||
|
bSaw = EgtSetCalcTool(sCurrSaw, "H1", 1)
|
||||||
|
End If
|
||||||
|
m_SingleCut.SetEnableParam(bSaw)
|
||||||
|
m_MultipleCut.SetEnableParam(bSaw)
|
||||||
|
m_GridCut.SetEnableParam(bSaw)
|
||||||
|
End Sub
|
||||||
|
|
||||||
Private Sub SetVisibilityJogButtuns()
|
Private Sub SetVisibilityJogButtuns()
|
||||||
XYBtn.Visibility = Visibility.Collapsed
|
XYBtn.Visibility = Visibility.Collapsed
|
||||||
ZCBtn.Visibility = Visibility.Collapsed
|
ZCBtn.Visibility = Visibility.Collapsed
|
||||||
|
|||||||
+30
-16
@@ -152,6 +152,7 @@ Public Class GridCut
|
|||||||
EgtDraw()
|
EgtDraw()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
Friend Sub GridCut_Unloaded(sender As Object, e As RoutedEventArgs) Handles Me.Unloaded
|
Friend Sub GridCut_Unloaded(sender As Object, e As RoutedEventArgs) Handles Me.Unloaded
|
||||||
' Salvo i dati correnti
|
' Salvo i dati correnti
|
||||||
WritePrivateProfileString( S_DIRECTCUTS, K_DC_GRID_DEPTH, DoubleToString( m_dDepth, 2), m_MainWindow.GetIniFile())
|
WritePrivateProfileString( S_DIRECTCUTS, K_DC_GRID_DEPTH, DoubleToString( m_dDepth, 2), m_MainWindow.GetIniFile())
|
||||||
@@ -185,6 +186,11 @@ Public Class GridCut
|
|||||||
m_bActive = False
|
m_bActive = False
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Public Sub SetEnableParam(ByVal bIsSaw As Boolean)
|
||||||
|
' se macchina solo WaterJet Disabilito/Nascondo parametri della lama
|
||||||
|
DepthTxBx.IsEnabled = bIsSaw
|
||||||
|
End Sub
|
||||||
|
|
||||||
Private Sub UpdateSimulOkBtn()
|
Private Sub UpdateSimulOkBtn()
|
||||||
If m_bCutOk Then
|
If m_bCutOk Then
|
||||||
SimulBtn.IsEnabled = True
|
SimulBtn.IsEnabled = True
|
||||||
@@ -242,6 +248,12 @@ Public Class GridCut
|
|||||||
' Verifico configurazione tavola e grezzo
|
' Verifico configurazione tavola e grezzo
|
||||||
If Not m_bRawOk Then Return
|
If Not m_bRawOk Then Return
|
||||||
|
|
||||||
|
' Recupero dati utensile e testa corrente
|
||||||
|
Dim sTool As String = ""
|
||||||
|
Dim sHead As String = ""
|
||||||
|
Dim nExit As Integer = 0
|
||||||
|
EgtGetCalcTool(sTool, sHead, nExit)
|
||||||
|
|
||||||
' Se acquisizone lama o laser
|
' Se acquisizone lama o laser
|
||||||
If PointModeCmBx.SelectedIndex = PT_MODE.SAW Or PointModeCmBx.SelectedIndex = PT_MODE.LASER Then
|
If PointModeCmBx.SelectedIndex = PT_MODE.SAW Or PointModeCmBx.SelectedIndex = PT_MODE.LASER Then
|
||||||
|
|
||||||
@@ -256,12 +268,12 @@ Public Class GridCut
|
|||||||
If Not EgtSetCalcTool("", "H3", 1) Then Return
|
If Not EgtSetCalcTool("", "H3", 1) Then Return
|
||||||
' Trasformo in posizione punta utensile in basso
|
' Trasformo in posizione punta utensile in basso
|
||||||
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP1) Then Return
|
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP1) Then Return
|
||||||
' Ora imposto la lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
' Altrimenti da lama
|
' Altrimenti da lama
|
||||||
Else
|
Else
|
||||||
' Imposto la lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
' Trasformo in posizione punta utensile in basso
|
' Trasformo in posizione punta utensile in basso
|
||||||
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP1) Then Return
|
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP1) Then Return
|
||||||
End If
|
End If
|
||||||
@@ -285,10 +297,8 @@ Public Class GridCut
|
|||||||
' Porto il tip nell'origine tavola
|
' Porto il tip nell'origine tavola
|
||||||
m_ptTipP1.ToLoc(New Frame3d(m_ptTabOri))
|
m_ptTipP1.ToLoc(New Frame3d(m_ptTabOri))
|
||||||
m_bPointP1Ok = True
|
m_bPointP1Ok = True
|
||||||
' Ricavo dati lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
Dim sSaw As String = m_MainWindow.m_CurrentMachine.sCurrSaw
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
' Imposto la lama corrente
|
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
' Disegno il taglio
|
' Disegno il taglio
|
||||||
@@ -317,6 +327,12 @@ Public Class GridCut
|
|||||||
' Verifico configurazione tavola e grezzo
|
' Verifico configurazione tavola e grezzo
|
||||||
If Not m_bRawOk Then Return
|
If Not m_bRawOk Then Return
|
||||||
|
|
||||||
|
' Recupero dati utensile e testa corrente
|
||||||
|
Dim sTool As String = ""
|
||||||
|
Dim sHead As String = ""
|
||||||
|
Dim nExit As Integer = 0
|
||||||
|
EgtGetCalcTool(sTool, sHead, nExit)
|
||||||
|
|
||||||
' Se acquisizone lama o laser
|
' Se acquisizone lama o laser
|
||||||
If PointModeCmBx.SelectedIndex = PT_MODE.SAW Or PointModeCmBx.SelectedIndex = PT_MODE.LASER Then
|
If PointModeCmBx.SelectedIndex = PT_MODE.SAW Or PointModeCmBx.SelectedIndex = PT_MODE.LASER Then
|
||||||
|
|
||||||
@@ -331,12 +347,12 @@ Public Class GridCut
|
|||||||
If Not EgtSetCalcTool("", "H3", 1) Then Return
|
If Not EgtSetCalcTool("", "H3", 1) Then Return
|
||||||
' Trasformo in posizione punta utensile in basso
|
' Trasformo in posizione punta utensile in basso
|
||||||
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP2) Then Return
|
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP2) Then Return
|
||||||
' Ora imposto la lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
' Altrimenti da lama
|
' Altrimenti da lama
|
||||||
Else
|
Else
|
||||||
' Imposto la lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
' Trasformo in posizione punta utensile in basso
|
' Trasformo in posizione punta utensile in basso
|
||||||
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP2) Then Return
|
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP2) Then Return
|
||||||
End If
|
End If
|
||||||
@@ -358,10 +374,8 @@ Public Class GridCut
|
|||||||
' Porto il tip nell'origine tavola
|
' Porto il tip nell'origine tavola
|
||||||
m_ptTipP2.ToLoc(New Frame3d(m_ptTabOri))
|
m_ptTipP2.ToLoc(New Frame3d(m_ptTabOri))
|
||||||
m_bPointP2Ok = True
|
m_bPointP2Ok = True
|
||||||
' Ricavo dati lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
Dim sSaw As String = m_MainWindow.m_CurrentMachine.sCurrSaw
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
' Imposto la lama corrente
|
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
' Se il secondo punto non coincide con il primo, disegno il taglio
|
' Se il secondo punto non coincide con il primo, disegno il taglio
|
||||||
|
|||||||
@@ -213,6 +213,10 @@ Public Class MultipleCut
|
|||||||
m_bActive = False
|
m_bActive = False
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Public Sub SetEnableParam(ByVal bIsSaw As Boolean)
|
||||||
|
DepthTxBx.IsEnabled = bIsSaw
|
||||||
|
End Sub
|
||||||
|
|
||||||
Private Sub UpdateSimulOkBtn()
|
Private Sub UpdateSimulOkBtn()
|
||||||
If m_bCutOk Then
|
If m_bCutOk Then
|
||||||
SimulBtn.IsEnabled = True
|
SimulBtn.IsEnabled = True
|
||||||
@@ -270,6 +274,12 @@ Public Class MultipleCut
|
|||||||
' Verifico configurazione tavola e grezzo
|
' Verifico configurazione tavola e grezzo
|
||||||
If Not m_bRawOk Then Return
|
If Not m_bRawOk Then Return
|
||||||
|
|
||||||
|
' Recupero dati utensile e testa corrente
|
||||||
|
Dim sTool As String = ""
|
||||||
|
Dim sHead As String = ""
|
||||||
|
Dim nExit As Integer = 0
|
||||||
|
EgtGetCalcTool(sTool, sHead, nExit)
|
||||||
|
|
||||||
' Se acquisizone lama o laser
|
' Se acquisizone lama o laser
|
||||||
If PointModeCmBx.SelectedIndex = PT_MODE.SAW Or PointModeCmBx.SelectedIndex = PT_MODE.LASER Then
|
If PointModeCmBx.SelectedIndex = PT_MODE.SAW Or PointModeCmBx.SelectedIndex = PT_MODE.LASER Then
|
||||||
|
|
||||||
@@ -284,12 +294,14 @@ Public Class MultipleCut
|
|||||||
If Not EgtSetCalcTool("", "H3", 1) Then Return
|
If Not EgtSetCalcTool("", "H3", 1) Then Return
|
||||||
' Trasformo in posizione punta utensile in basso
|
' Trasformo in posizione punta utensile in basso
|
||||||
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP1) Then Return
|
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP1) Then Return
|
||||||
' Ora imposto la lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
' Altrimenti da lama
|
|
||||||
|
' Altrimenti da lama
|
||||||
Else
|
Else
|
||||||
' Imposto la lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
|
|
||||||
' Trasformo in posizione punta utensile in basso
|
' Trasformo in posizione punta utensile in basso
|
||||||
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP1) Then Return
|
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP1) Then Return
|
||||||
End If
|
End If
|
||||||
@@ -312,10 +324,9 @@ Public Class MultipleCut
|
|||||||
' Porto il tip nell'origine tavola
|
' Porto il tip nell'origine tavola
|
||||||
m_ptTipP1.ToLoc(New Frame3d(m_ptTabOri))
|
m_ptTipP1.ToLoc(New Frame3d(m_ptTabOri))
|
||||||
m_bPointP1Ok = True
|
m_bPointP1Ok = True
|
||||||
' Ricavo dati lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
Dim sSaw As String = m_MainWindow.m_CurrentMachine.sCurrSaw
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
' Imposto la lama corrente
|
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
|
||||||
End If
|
End If
|
||||||
' Disegno il taglio
|
' Disegno il taglio
|
||||||
CreateMultipleCut()
|
CreateMultipleCut()
|
||||||
@@ -343,6 +354,12 @@ Public Class MultipleCut
|
|||||||
' Verifico configurazione tavola e grezzo
|
' Verifico configurazione tavola e grezzo
|
||||||
If Not m_bRawOk Then Return
|
If Not m_bRawOk Then Return
|
||||||
|
|
||||||
|
' Recupero dati utensile e testa corrente
|
||||||
|
Dim sTool As String = ""
|
||||||
|
Dim sHead As String = ""
|
||||||
|
Dim nExit As Integer = 0
|
||||||
|
EgtGetCalcTool(sTool, sHead, nExit)
|
||||||
|
|
||||||
' Se acquisizone lama o laser
|
' Se acquisizone lama o laser
|
||||||
If PointModeCmBx.SelectedIndex = PT_MODE.SAW Or PointModeCmBx.SelectedIndex = PT_MODE.LASER Then
|
If PointModeCmBx.SelectedIndex = PT_MODE.SAW Or PointModeCmBx.SelectedIndex = PT_MODE.LASER Then
|
||||||
|
|
||||||
@@ -357,12 +374,12 @@ Public Class MultipleCut
|
|||||||
If Not EgtSetCalcTool("", "H3", 1) Then Return
|
If Not EgtSetCalcTool("", "H3", 1) Then Return
|
||||||
' Trasformo in posizione punta utensile in basso
|
' Trasformo in posizione punta utensile in basso
|
||||||
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP2) Then Return
|
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP2) Then Return
|
||||||
' Ora imposto la lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
' Altrimenti da lama
|
' Altrimenti da lama
|
||||||
Else
|
Else
|
||||||
' Imposto la lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
' Trasformo in posizione punta utensile in basso
|
' Trasformo in posizione punta utensile in basso
|
||||||
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP2) Then Return
|
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP2) Then Return
|
||||||
End If
|
End If
|
||||||
@@ -383,10 +400,9 @@ Public Class MultipleCut
|
|||||||
' Porto il tip nell'origine tavola
|
' Porto il tip nell'origine tavola
|
||||||
m_ptTipP2.ToLoc(New Frame3d(m_ptTabOri))
|
m_ptTipP2.ToLoc(New Frame3d(m_ptTabOri))
|
||||||
m_bPointP2Ok = True
|
m_bPointP2Ok = True
|
||||||
' Ricavo dati lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
Dim sSaw As String = m_MainWindow.m_CurrentMachine.sCurrSaw
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
' Imposto la lama corrente
|
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
' Se il secondo punto non coincide con il primo, disegno il taglio
|
' Se il secondo punto non coincide con il primo, disegno il taglio
|
||||||
|
|||||||
@@ -137,6 +137,9 @@ Public Class SingleCutUC
|
|||||||
Point2Btn.IsEnabled = False
|
Point2Btn.IsEnabled = False
|
||||||
' Deseleziono bottone primo punto
|
' Deseleziono bottone primo punto
|
||||||
Point1Btn.IsChecked = False
|
Point1Btn.IsChecked = False
|
||||||
|
|
||||||
|
' la visualizzazione dei comandi è gestira dalla DirectCutPageUC richiamando la funzione ReloadParam
|
||||||
|
|
||||||
' Aggiorno visualizzazione
|
' Aggiorno visualizzazione
|
||||||
EgtDraw()
|
EgtDraw()
|
||||||
End Sub
|
End Sub
|
||||||
@@ -172,6 +175,12 @@ Public Class SingleCutUC
|
|||||||
m_bActive = False
|
m_bActive = False
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Public Sub SetEnableParam(ByVal bIsSaw As Boolean)
|
||||||
|
' se macchina solo WaterJet Disabilito/Nascondo parametri della lama
|
||||||
|
DepthTxBx.IsEnabled = bIsSaw
|
||||||
|
SawThChBx.IsEnabled = bIsSaw
|
||||||
|
End Sub
|
||||||
|
|
||||||
Private Sub UpdateSimulOkBtn()
|
Private Sub UpdateSimulOkBtn()
|
||||||
If m_bCutOk Then
|
If m_bCutOk Then
|
||||||
SimulBtn.IsEnabled = True
|
SimulBtn.IsEnabled = True
|
||||||
@@ -229,6 +238,12 @@ Public Class SingleCutUC
|
|||||||
' Verifico configurazione tavola e grezzo
|
' Verifico configurazione tavola e grezzo
|
||||||
If Not m_bRawOk Then Return
|
If Not m_bRawOk Then Return
|
||||||
|
|
||||||
|
' Recupero dati utensile e testa corrente
|
||||||
|
Dim sTool As String = ""
|
||||||
|
Dim sHead As String = ""
|
||||||
|
Dim nExit As Integer = 0
|
||||||
|
EgtGetCalcTool(sTool, sHead, nExit)
|
||||||
|
|
||||||
' Se acquisizione lama o laser
|
' Se acquisizione lama o laser
|
||||||
If PointModeCmBx.SelectedIndex = PT_MODE.SAW Or PointModeCmBx.SelectedIndex = PT_MODE.LASER Then
|
If PointModeCmBx.SelectedIndex = PT_MODE.SAW Or PointModeCmBx.SelectedIndex = PT_MODE.LASER Then
|
||||||
' Recupero la posizione macchina
|
' Recupero la posizione macchina
|
||||||
@@ -242,12 +257,12 @@ Public Class SingleCutUC
|
|||||||
If Not EgtSetCalcTool("", "H3", 1) Then Return
|
If Not EgtSetCalcTool("", "H3", 1) Then Return
|
||||||
' Trasformo in posizione punta utensile in basso
|
' Trasformo in posizione punta utensile in basso
|
||||||
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP1) Then Return
|
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP1) Then Return
|
||||||
' Ora imposto la lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
' Altrimenti da lama
|
' Altrimenti da lama
|
||||||
Else
|
Else
|
||||||
' Imposto la lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
' Trasformo in posizione punta utensile in basso
|
' Trasformo in posizione punta utensile in basso
|
||||||
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP1) Then Return
|
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP1) Then Return
|
||||||
End If
|
End If
|
||||||
@@ -271,10 +286,9 @@ Public Class SingleCutUC
|
|||||||
' Porto il tip nell'origine tavola
|
' Porto il tip nell'origine tavola
|
||||||
m_ptTipP1.ToLoc(New Frame3d(m_ptTabOri))
|
m_ptTipP1.ToLoc(New Frame3d(m_ptTabOri))
|
||||||
m_bPointP1Ok = True
|
m_bPointP1Ok = True
|
||||||
' Ricavo dati lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
Dim sSaw As String = m_MainWindow.m_CurrentMachine.sCurrSaw
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
' Imposto la lama corrente
|
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
' Disegno il taglio
|
' Disegno il taglio
|
||||||
@@ -303,6 +317,12 @@ Public Class SingleCutUC
|
|||||||
' Verifico configurazione tavola e grezzo
|
' Verifico configurazione tavola e grezzo
|
||||||
If Not m_bRawOk Then Return
|
If Not m_bRawOk Then Return
|
||||||
|
|
||||||
|
' Recupero dati utensile e testa corrente
|
||||||
|
Dim sTool As String = ""
|
||||||
|
Dim sHead As String = ""
|
||||||
|
Dim nExit As Integer = 0
|
||||||
|
EgtGetCalcTool(sTool, sHead, nExit)
|
||||||
|
|
||||||
' Se acquisizone lama o laser
|
' Se acquisizone lama o laser
|
||||||
If PointModeCmBx.SelectedIndex = PT_MODE.SAW Or PointModeCmBx.SelectedIndex = PT_MODE.LASER Then
|
If PointModeCmBx.SelectedIndex = PT_MODE.SAW Or PointModeCmBx.SelectedIndex = PT_MODE.LASER Then
|
||||||
' Recupero la posizione macchina
|
' Recupero la posizione macchina
|
||||||
@@ -316,12 +336,14 @@ Public Class SingleCutUC
|
|||||||
If Not EgtSetCalcTool("", "H3", 1) Then Return
|
If Not EgtSetCalcTool("", "H3", 1) Then Return
|
||||||
' Trasformo in posizione punta utensile in basso
|
' Trasformo in posizione punta utensile in basso
|
||||||
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP2) Then Return
|
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP2) Then Return
|
||||||
' Ora imposto la lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
' Altrimenti da lama
|
|
||||||
|
' Altrimenti da lama
|
||||||
Else
|
Else
|
||||||
' Imposto la lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
|
|
||||||
' Trasformo in posizione punta utensile in basso
|
' Trasformo in posizione punta utensile in basso
|
||||||
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP2) Then Return
|
If Not EgtGetCalcTipFromPositions(dL1, dL2, dL3, dR1, dR2, True, m_ptTipP2) Then Return
|
||||||
End If
|
End If
|
||||||
@@ -343,10 +365,8 @@ Public Class SingleCutUC
|
|||||||
' Porto il tip nell'origine tavola
|
' Porto il tip nell'origine tavola
|
||||||
m_ptTipP2.ToLoc(New Frame3d(m_ptTabOri))
|
m_ptTipP2.ToLoc(New Frame3d(m_ptTabOri))
|
||||||
m_bPointP2Ok = True
|
m_bPointP2Ok = True
|
||||||
' Ricavo dati lama corrente
|
' Reimposto eventuale precedente utensile
|
||||||
Dim sSaw As String = m_MainWindow.m_CurrentMachine.sCurrSaw
|
EgtSetCalcTool(sTool, sHead, nExit)
|
||||||
' Imposto la lama corrente
|
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
' Se il secondo punto non coincide con il primo, disegno il taglio
|
' Se il secondo punto non coincide con il primo, disegno il taglio
|
||||||
@@ -559,9 +579,13 @@ Public Class SingleCutUC
|
|||||||
Dim dRawHeight As Double = m_ptRawMax.z - m_ptRawMin.z
|
Dim dRawHeight As Double = m_ptRawMax.z - m_ptRawMin.z
|
||||||
' Recupero spessore lama corrente
|
' Recupero spessore lama corrente
|
||||||
Dim sSaw As String = m_MainWindow.m_CurrentMachine.sCurrSaw
|
Dim sSaw As String = m_MainWindow.m_CurrentMachine.sCurrSaw
|
||||||
|
Dim sSawing As String = m_MainWindow.m_CurrentMachine.sCurrSawing
|
||||||
EgtTdbSetCurrTool(sSaw)
|
EgtTdbSetCurrTool(sSaw)
|
||||||
Dim dThick As Double = 0
|
Dim dThick As Double = 0
|
||||||
EgtTdbGetCurrToolParam(MCH_TP.THICK, dThick)
|
' se è impostata una lavorazione di lama
|
||||||
|
If Not String.IsNullOrEmpty(sSawing) Then
|
||||||
|
EgtTdbGetCurrToolParam(MCH_TP.THICK, dThick)
|
||||||
|
End If
|
||||||
' Rimuovo eventuale vecchio pezzo per taglio diretto
|
' Rimuovo eventuale vecchio pezzo per taglio diretto
|
||||||
EraseDirectCutPart()
|
EraseDirectCutPart()
|
||||||
' Disattivo eventuali lavorazioni presenti
|
' Disattivo eventuali lavorazioni presenti
|
||||||
|
|||||||
@@ -755,6 +755,10 @@ Public Class SideAngleUC
|
|||||||
vJoint.Add(False)
|
vJoint.Add(False)
|
||||||
End If
|
End If
|
||||||
Next
|
Next
|
||||||
|
|
||||||
|
' se non riesco a generare un elenco allora esco
|
||||||
|
If vJoint.Count < 1 Then Return
|
||||||
|
|
||||||
If vJoint(0) And vJoint(vJoint.Count - 1) Then
|
If vJoint(0) And vJoint(vJoint.Count - 1) Then
|
||||||
bJointStart = True
|
bJointStart = True
|
||||||
End If
|
End If
|
||||||
|
|||||||
@@ -437,10 +437,24 @@ Public Class AlarmsPageUC
|
|||||||
End If
|
End If
|
||||||
If m_CurrentMachine.sCurrWaterJetting <> String.Empty Then
|
If m_CurrentMachine.sCurrWaterJetting <> String.Empty Then
|
||||||
CurrWaterJettingTxBx.Text = m_CurrentMachine.sCurrWaterJetting
|
CurrWaterJettingTxBx.Text = m_CurrentMachine.sCurrWaterJetting
|
||||||
CurrWaterJettingQualityTxBx.Text = m_CurrentMachine.sCurrWaterJettingQuality
|
|
||||||
CurrWaterJettingTxBl.Visibility = Windows.Visibility.Visible
|
CurrWaterJettingTxBl.Visibility = Windows.Visibility.Visible
|
||||||
CurrWaterJettingTxBx.Visibility = Windows.Visibility.Visible
|
CurrWaterJettingTxBx.Visibility = Windows.Visibility.Visible
|
||||||
CurrWaterJettingQualityTxBx.Visibility = Windows.Visibility.Visible
|
If m_MainWindow.m_CurrentMachine.bFromDBWaterJet Then
|
||||||
|
CurrWaterJettingTxBx.SetValue(Grid.ColumnSpanProperty, 1)
|
||||||
|
CurrWaterJettingTxBx.SetValue(MarginProperty, New Thickness(CurrWaterJettingTxBx.Margin.Left,
|
||||||
|
CurrWaterJettingTxBx.Margin.Top,
|
||||||
|
5,
|
||||||
|
CurrWaterJettingTxBx.Margin.Bottom))
|
||||||
|
CurrWaterJettingQualityTxBx.Text = m_CurrentMachine.sCurrWaterJettingQuality
|
||||||
|
CurrWaterJettingQualityTxBx.Visibility = Windows.Visibility.Visible
|
||||||
|
Else
|
||||||
|
CurrWaterJettingTxBx.SetValue(Grid.ColumnSpanProperty, 2)
|
||||||
|
CurrWaterJettingTxBx.SetValue(MarginProperty, New Thickness(CurrWaterJettingTxBx.Margin.Left,
|
||||||
|
CurrWaterJettingTxBx.Margin.Top,
|
||||||
|
10,
|
||||||
|
CurrWaterJettingTxBx.Margin.Bottom))
|
||||||
|
CurrWaterJettingQualityTxBx.Visibility = Windows.Visibility.Collapsed
|
||||||
|
End If
|
||||||
Else
|
Else
|
||||||
CurrWaterJettingTxBl.Visibility = Windows.Visibility.Hidden
|
CurrWaterJettingTxBl.Visibility = Windows.Visibility.Hidden
|
||||||
CurrWaterJettingTxBx.Visibility = Windows.Visibility.Hidden
|
CurrWaterJettingTxBx.Visibility = Windows.Visibility.Hidden
|
||||||
|
|||||||
@@ -77,6 +77,9 @@ Public Class CurrentMachine
|
|||||||
Private m_bPolishingWheel As Boolean = False
|
Private m_bPolishingWheel As Boolean = False
|
||||||
Private m_bWaterJet As Boolean = False
|
Private m_bWaterJet As Boolean = False
|
||||||
|
|
||||||
|
' Abilitazione DB WaterJet
|
||||||
|
Private m_bFromDBWaterJet As Boolean = False
|
||||||
|
|
||||||
' Flag per visualizzazione TcPos, Testa/uscita e Note utente
|
' Flag per visualizzazione TcPos, Testa/uscita e Note utente
|
||||||
Private m_nShowToolChanger As Integer = 0 ' 0=no, 1=tutti utensili, 2=solo lame
|
Private m_nShowToolChanger As Integer = 0 ' 0=no, 1=tutti utensili, 2=solo lame
|
||||||
Private m_bShowHeadExit As Boolean = False
|
Private m_bShowHeadExit As Boolean = False
|
||||||
@@ -436,6 +439,12 @@ Public Class CurrentMachine
|
|||||||
End Get
|
End Get
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
|
Friend ReadOnly Property bFromDBWaterJet As Boolean
|
||||||
|
Get
|
||||||
|
Return m_bFromDBWaterJet
|
||||||
|
End Get
|
||||||
|
End Property
|
||||||
|
|
||||||
Friend ReadOnly Property ShowToolChanger As Integer
|
Friend ReadOnly Property ShowToolChanger As Integer
|
||||||
Get
|
Get
|
||||||
Return m_nShowToolChanger
|
Return m_nShowToolChanger
|
||||||
@@ -1006,7 +1015,7 @@ Public Class CurrentMachine
|
|||||||
End Get
|
End Get
|
||||||
Set(value As Material)
|
Set(value As Material)
|
||||||
Dim CurrMatId As String = If(Not IsNothing(value), value.nId.ToString, "")
|
Dim CurrMatId As String = If(Not IsNothing(value), value.nId.ToString, "")
|
||||||
If bWaterJet Then
|
If bWaterJet And bFromDBWaterJet Then
|
||||||
WritePrivateProfileString(S_MATERIALS, K_CURRMATERIAL, CurrMatId & If(Not IsNothing(value), "." & value.SubId, ""), sMachIniFile)
|
WritePrivateProfileString(S_MATERIALS, K_CURRMATERIAL, CurrMatId & If(Not IsNothing(value), "." & value.SubId, ""), sMachIniFile)
|
||||||
Else
|
Else
|
||||||
WritePrivateProfileString(S_MATERIALS, K_CURRMATERIAL, CurrMatId, sMachIniFile)
|
WritePrivateProfileString(S_MATERIALS, K_CURRMATERIAL, CurrMatId, sMachIniFile)
|
||||||
@@ -1108,6 +1117,8 @@ Public Class CurrentMachine
|
|||||||
' waterjet
|
' waterjet
|
||||||
m_bWaterJet = (GetPrivateProfileInt(S_TOOLS, K_WATERJET, 0, sMachIniFile) > 0) And
|
m_bWaterJet = (GetPrivateProfileInt(S_TOOLS, K_WATERJET, 0, sMachIniFile) > 0) And
|
||||||
m_MainWindow.GetKeyOption(MainWindow.KEY_OPT.ENABLE_WJ)
|
m_MainWindow.GetKeyOption(MainWindow.KEY_OPT.ENABLE_WJ)
|
||||||
|
' Leggo abilitazione DB WaterJet
|
||||||
|
m_bFromDBWaterJet = (GetPrivateProfileInt(S_MATERIALS, K_FROMDBWATERJET, 0, sMachIniFile) > 0)
|
||||||
' Leggo abilitazione visualizzazione TcPos, Head/exit e Note utente
|
' Leggo abilitazione visualizzazione TcPos, Head/exit e Note utente
|
||||||
m_nShowToolChanger = GetPrivateProfileInt(S_TOOLS, K_SHOWTOOLCHANGER, 0, sMachIniFile)
|
m_nShowToolChanger = GetPrivateProfileInt(S_TOOLS, K_SHOWTOOLCHANGER, 0, sMachIniFile)
|
||||||
m_bShowHeadExit = (GetPrivateProfileInt(S_TOOLS, K_SHOWHEADEXIT, 0, sMachIniFile) > 0)
|
m_bShowHeadExit = (GetPrivateProfileInt(S_TOOLS, K_SHOWHEADEXIT, 0, sMachIniFile) > 0)
|
||||||
@@ -1247,7 +1258,7 @@ Public Class CurrentMachine
|
|||||||
Dim Material As Material = Nothing
|
Dim Material As Material = Nothing
|
||||||
Dim nIndex As Integer = 1
|
Dim nIndex As Integer = 1
|
||||||
|
|
||||||
If m_bWaterJet Then
|
If m_bWaterJet And m_bFromDBWaterJet Then
|
||||||
LoadWJMaterial(True)
|
LoadWJMaterial(True)
|
||||||
Else
|
Else
|
||||||
While (GetPrivateProfileMaterial(S_MATERIALS, K_MATERIAL & nIndex, Material, sMachIniFile))
|
While (GetPrivateProfileMaterial(S_MATERIALS, K_MATERIAL & nIndex, Material, sMachIniFile))
|
||||||
@@ -1262,7 +1273,7 @@ Public Class CurrentMachine
|
|||||||
' Leggo materiale correntemente attivo
|
' Leggo materiale correntemente attivo
|
||||||
Dim sCurrMatId As String = String.Empty
|
Dim sCurrMatId As String = String.Empty
|
||||||
EgtUILib.GetPrivateProfileString(S_MATERIALS, K_CURRMATERIAL, "0", sCurrMatId, sMachIniFile)
|
EgtUILib.GetPrivateProfileString(S_MATERIALS, K_CURRMATERIAL, "0", sCurrMatId, sMachIniFile)
|
||||||
If bWaterJet Then
|
If bWaterJet And bFromDBWaterJet Then
|
||||||
Dim sCurrMatIds As String()
|
Dim sCurrMatIds As String()
|
||||||
sCurrMatIds = sCurrMatId.Split("."c)
|
sCurrMatIds = sCurrMatId.Split("."c)
|
||||||
If sCurrMatIds.Length > 1 Then
|
If sCurrMatIds.Length > 1 Then
|
||||||
@@ -1303,7 +1314,6 @@ Public Class CurrentMachine
|
|||||||
Local_MaterialList = EgtWPFLib5.WaterjetDbWindowVM.LoadWjMaterials(sFilePath)
|
Local_MaterialList = EgtWPFLib5.WaterjetDbWindowVM.LoadWjMaterials(sFilePath)
|
||||||
' definisco la lista delle qualità (solo se è vuota)
|
' definisco la lista delle qualità (solo se è vuota)
|
||||||
If m_Qualities.Count < 1 Then
|
If m_Qualities.Count < 1 Then
|
||||||
m_Qualities.Add("")
|
|
||||||
m_Qualities.Add("Q1")
|
m_Qualities.Add("Q1")
|
||||||
m_Qualities.Add("Q2")
|
m_Qualities.Add("Q2")
|
||||||
m_Qualities.Add("Q3")
|
m_Qualities.Add("Q3")
|
||||||
|
|||||||
@@ -64,7 +64,7 @@ Public Class MachinePageUC
|
|||||||
PolishingsBtn.IsEnabled = False
|
PolishingsBtn.IsEnabled = False
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Not m_MainWindow.m_CurrentMachine.bWaterJet Then
|
If Not m_MainWindow.m_CurrentMachine.bWaterJet Or Not m_MainWindow.m_CurrentMachine.bFromDBWaterJet Then
|
||||||
WaterJetBtn.IsEnabled = False
|
WaterJetBtn.IsEnabled = False
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|||||||
@@ -552,12 +552,15 @@ Public Class MachiningDbPageUC
|
|||||||
HeadSideCmBx.SelectedIndex = ToolInt - 1
|
HeadSideCmBx.SelectedIndex = ToolInt - 1
|
||||||
EgtMdbGetCurrMachiningParam(MCH_MP.LEADINTYPE, ToolInt)
|
EgtMdbGetCurrMachiningParam(MCH_MP.LEADINTYPE, ToolInt)
|
||||||
If LeadInTypeCmBx.Items.Count > 0 Then
|
If LeadInTypeCmBx.Items.Count > 0 Then
|
||||||
LeadInTypeCmBx.SelectedItem = LeadInTypeCmBx.Items(0)
|
LeadInTypeCmBx.SelectedItem = LeadInTypeCmBx.Items(0)
|
||||||
Else
|
Else
|
||||||
LeadInTypeCmBx.SelectedItem = Nothing
|
LeadInTypeCmBx.SelectedItem = Nothing
|
||||||
End If
|
End If
|
||||||
For Each LInType As IdNameStruct In LeadInTypeCmBx.Items
|
For Each LInType As IdNameStruct In LeadInTypeCmBx.Items
|
||||||
If ToolInt = LInType.Id Then LeadInTypeCmBx.SelectedItem = LInType
|
If ToolInt = LInType.Id Then
|
||||||
|
LeadInTypeCmBx.SelectedItem = LInType
|
||||||
|
Exit For
|
||||||
|
End If
|
||||||
Next
|
Next
|
||||||
EgtMdbGetCurrMachiningParam(MCH_MP.EXTLINKTYPE, ToolInt)
|
EgtMdbGetCurrMachiningParam(MCH_MP.EXTLINKTYPE, ToolInt)
|
||||||
ExtLinkTypeCmBx.SelectedIndex = ToolInt
|
ExtLinkTypeCmBx.SelectedIndex = ToolInt
|
||||||
@@ -705,7 +708,7 @@ Public Class MachiningDbPageUC
|
|||||||
' Lista materiali
|
' Lista materiali
|
||||||
m_MaterialsList.Clear()
|
m_MaterialsList.Clear()
|
||||||
For Each Material As Material In m_MainWindow.m_CurrentMachine.Materials
|
For Each Material As Material In m_MainWindow.m_CurrentMachine.Materials
|
||||||
If m_MainWindow.m_CurrentMachine.bWaterJet Then
|
If m_MainWindow.m_CurrentMachine.bWaterJet And m_MainWindow.m_CurrentMachine.bFromDBWaterJet Then
|
||||||
m_MaterialsList.Add(New MachiningMaterial(Material.nId, Material.sName, Material.SubId))
|
m_MaterialsList.Add(New MachiningMaterial(Material.nId, Material.sName, Material.SubId))
|
||||||
Else
|
Else
|
||||||
m_MaterialsList.Add(New MachiningMaterial(Material.nId, Material.sName))
|
m_MaterialsList.Add(New MachiningMaterial(Material.nId, Material.sName))
|
||||||
@@ -720,7 +723,7 @@ Public Class MachiningDbPageUC
|
|||||||
Dim SubParam() As String = Param(0).Split(".".ToCharArray)
|
Dim SubParam() As String = Param(0).Split(".".ToCharArray)
|
||||||
Dim nParId As Integer = 0
|
Dim nParId As Integer = 0
|
||||||
Dim nSubParId As Integer = 0
|
Dim nSubParId As Integer = 0
|
||||||
If m_MainWindow.m_CurrentMachine.bWaterJet Then
|
If m_MainWindow.m_CurrentMachine.bWaterJet And m_MainWindow.m_CurrentMachine.bFromDBWaterJet Then
|
||||||
If StringToInt(SubParam(0), nParId) AndAlso nParId = Material.nId AndAlso SubParam.Count > 1 AndAlso
|
If StringToInt(SubParam(0), nParId) AndAlso nParId = Material.nId AndAlso SubParam.Count > 1 AndAlso
|
||||||
StringToInt(SubParam(1), nSubParId) AndAlso nSubParId = Material.nSubId Then
|
StringToInt(SubParam(1), nSubParId) AndAlso nSubParId = Material.nSubId Then
|
||||||
|
|
||||||
@@ -819,13 +822,13 @@ Public Class MachiningDbPageUC
|
|||||||
' Parmetri nascosti di svuotatura
|
' Parmetri nascosti di svuotatura
|
||||||
If nMachiningType = MCH_MY.POCKETING Then
|
If nMachiningType = MCH_MY.POCKETING Then
|
||||||
EgtMdbSetCurrMachiningParam(MCH_MP.SUBTYPE, MCH_POCK_SUB.SPIRALOUT)
|
EgtMdbSetCurrMachiningParam(MCH_MP.SUBTYPE, MCH_POCK_SUB.SPIRALOUT)
|
||||||
EgtMdbSetCurrMachiningParam( MCH_MP.LEADINTYPE, MCH_POCK_LI.HELIX)
|
' EgtMdbSetCurrMachiningParam( MCH_MP.LEADINTYPE, MCH_POCK_LI.HELIX)
|
||||||
Dim dToolDiam As Double = 100
|
Dim dToolDiam As Double = 100
|
||||||
If Not IsNothing(ToolCmBx.SelectedItem) Then
|
If Not IsNothing(ToolCmBx.SelectedItem) Then
|
||||||
EgtTdbSetCurrTool( ToolCmBx.SelectedItem.ToString())
|
EgtTdbSetCurrTool( ToolCmBx.SelectedItem.ToString())
|
||||||
EgtTdbGetCurrToolParam( MCH_TP.DIAM, dToolDiam)
|
EgtTdbGetCurrToolParam( MCH_TP.DIAM, dToolDiam)
|
||||||
End If
|
End If
|
||||||
EgtMdbSetCurrMachiningParam( MCH_MP.LITANG, 0.495 * dToolDiam)
|
EgtMdbSetCurrMachiningParam(MCH_MP.LITANG, 0.99 * dToolDiam)
|
||||||
EgtMdbSetCurrMachiningParam( MCH_MP.LIELEV, 2.0)
|
EgtMdbSetCurrMachiningParam( MCH_MP.LIELEV, 2.0)
|
||||||
End If
|
End If
|
||||||
' Parametri WaterJetting
|
' Parametri WaterJetting
|
||||||
@@ -894,7 +897,7 @@ Public Class MachiningDbPageUC
|
|||||||
' Scrivo stringa materiali da lista
|
' Scrivo stringa materiali da lista
|
||||||
Dim sMaterialString As String = String.Empty
|
Dim sMaterialString As String = String.Empty
|
||||||
For Each Material As MachiningMaterial In m_MaterialsList
|
For Each Material As MachiningMaterial In m_MaterialsList
|
||||||
If m_MainWindow.m_CurrentMachine.bWaterJet Then
|
If m_MainWindow.m_CurrentMachine.bWaterJet And m_MainWindow.m_CurrentMachine.bFromDBWaterJet Then
|
||||||
If Material.bIsActive Then
|
If Material.bIsActive Then
|
||||||
sMaterialString += Material.nId.ToString & "." & Material.nSubId.ToString & "," & DoubleToString(Material.dMinThickness, 0) & "," & DoubleToString(Material.dMaxThickness, 0) & ";"
|
sMaterialString += Material.nId.ToString & "." & Material.nSubId.ToString & "," & DoubleToString(Material.dMinThickness, 0) & "," & DoubleToString(Material.dMaxThickness, 0) & ";"
|
||||||
End If
|
End If
|
||||||
@@ -1138,30 +1141,26 @@ Public Class MachiningDbPageUC
|
|||||||
' Definizione della grid TypeGrd con la giusta altezza e numero di righe
|
' Definizione della grid TypeGrd con la giusta altezza e numero di righe
|
||||||
Dim RowNum As Integer = TypeGrd.RowDefinitions.Count
|
Dim RowNum As Integer = TypeGrd.RowDefinitions.Count
|
||||||
If RowNum > 2 Then
|
If RowNum > 2 Then
|
||||||
|
' elimino eventuali righe in eccesso
|
||||||
For Index As Integer = RowNum - 1 To 2 Step -1
|
For Index As Integer = RowNum - 1 To 2 Step -1
|
||||||
TypeGrd.RowDefinitions.RemoveAt(Index)
|
TypeGrd.RowDefinitions.RemoveAt(Index)
|
||||||
Next
|
Next
|
||||||
LeadInTypeTxBl.SetValue(Grid.ColumnProperty, 2)
|
|
||||||
LeadInTypeCmBx.SetValue(Grid.ColumnProperty, 3)
|
|
||||||
LeadOutTypeTxBl.SetValue(Grid.RowProperty, 1)
|
|
||||||
LeadOutTypeTxBl.SetValue(Grid.ColumnProperty, 2)
|
|
||||||
LeadOutTypeCmBx.SetValue(Grid.RowProperty, 1)
|
|
||||||
LeadOutTypeCmBx.SetValue(Grid.ColumnProperty, 3)
|
|
||||||
TypeBrd.SetValue(Grid.RowProperty, 12)
|
|
||||||
TypeBrd.SetValue(Grid.RowSpanProperty, 6)
|
|
||||||
ElseIf RowNum < 2 Then
|
ElseIf RowNum < 2 Then
|
||||||
' costruiso una riga in più da inserire
|
' costruiso una riga in più da inserire
|
||||||
Dim Row As New RowDefinition
|
Dim Row As New RowDefinition
|
||||||
TypeGrd.RowDefinitions.Add(Row)
|
TypeGrd.RowDefinitions.Add(Row)
|
||||||
LeadInTypeTxBl.SetValue(Grid.ColumnProperty, 2)
|
|
||||||
LeadInTypeCmBx.SetValue(Grid.ColumnProperty, 3)
|
|
||||||
LeadOutTypeTxBl.SetValue(Grid.RowProperty, 1)
|
|
||||||
LeadOutTypeTxBl.SetValue(Grid.ColumnProperty, 2)
|
|
||||||
LeadOutTypeCmBx.SetValue(Grid.RowProperty, 1)
|
|
||||||
LeadOutTypeCmBx.SetValue(Grid.ColumnProperty, 3)
|
|
||||||
TypeBrd.SetValue(Grid.RowProperty, 12)
|
|
||||||
TypeBrd.SetValue(Grid.RowSpanProperty, 6)
|
|
||||||
End If
|
End If
|
||||||
|
LeadInTypeTxBl.SetValue(Grid.RowProperty, 1)
|
||||||
|
LeadInTypeTxBl.SetValue(Grid.ColumnProperty, 0)
|
||||||
|
LeadInTypeCmBx.SetValue(Grid.RowProperty, 1)
|
||||||
|
LeadInTypeCmBx.SetValue(Grid.ColumnProperty, 1)
|
||||||
|
LeadOutTypeTxBl.SetValue(Grid.RowProperty, 1)
|
||||||
|
LeadOutTypeTxBl.SetValue(Grid.ColumnProperty, 2)
|
||||||
|
LeadOutTypeCmBx.SetValue(Grid.RowProperty, 1)
|
||||||
|
LeadOutTypeCmBx.SetValue(Grid.ColumnProperty, 3)
|
||||||
|
TypeBrd.SetValue(Grid.RowProperty, 12)
|
||||||
|
TypeBrd.SetValue(Grid.RowSpanProperty, 6)
|
||||||
|
|
||||||
LeadInTypeTxBl.Visibility = Windows.Visibility.Visible
|
LeadInTypeTxBl.Visibility = Windows.Visibility.Visible
|
||||||
LeadInTypeCmBx.Visibility = Windows.Visibility.Visible
|
LeadInTypeCmBx.Visibility = Windows.Visibility.Visible
|
||||||
ExtLinkTypeTxBl.Visibility = Windows.Visibility.Hidden
|
ExtLinkTypeTxBl.Visibility = Windows.Visibility.Hidden
|
||||||
@@ -1779,7 +1778,7 @@ Public Class MachiningDbPageUC
|
|||||||
StepTypeTxBl.Visibility = Windows.Visibility.Hidden
|
StepTypeTxBl.Visibility = Windows.Visibility.Hidden
|
||||||
StepTypeCmBx.Visibility = Windows.Visibility.Hidden
|
StepTypeCmBx.Visibility = Windows.Visibility.Hidden
|
||||||
SideBrd.SetValue(Grid.RowProperty, 9)
|
SideBrd.SetValue(Grid.RowProperty, 9)
|
||||||
SideBrd.Visibility = Windows.Visibility.Visible
|
SideBrd.Visibility = Windows.Visibility.Hidden
|
||||||
WorkSideTxBl.Visibility = Windows.Visibility.Hidden
|
WorkSideTxBl.Visibility = Windows.Visibility.Hidden
|
||||||
WorkSideCmBx.Visibility = Windows.Visibility.Hidden
|
WorkSideCmBx.Visibility = Windows.Visibility.Hidden
|
||||||
HeadSideTxBl.Visibility = Windows.Visibility.Hidden
|
HeadSideTxBl.Visibility = Windows.Visibility.Hidden
|
||||||
@@ -1791,15 +1790,22 @@ Public Class MachiningDbPageUC
|
|||||||
For Index As Integer = RowNum - 1 To 2 Step -1
|
For Index As Integer = RowNum - 1 To 2 Step -1
|
||||||
TypeGrd.RowDefinitions.RemoveAt(Index)
|
TypeGrd.RowDefinitions.RemoveAt(Index)
|
||||||
Next
|
Next
|
||||||
LeadInTypeTxBl.SetValue(Grid.ColumnProperty, 2)
|
ElseIf RowNum < 2 Then
|
||||||
LeadInTypeCmBx.SetValue(Grid.ColumnProperty, 3)
|
' costruiso una riga in più da inserire
|
||||||
LeadOutTypeTxBl.SetValue(Grid.RowProperty, 1)
|
Dim Row As New RowDefinition
|
||||||
LeadOutTypeTxBl.SetValue(Grid.ColumnProperty, 2)
|
TypeGrd.RowDefinitions.Add(Row)
|
||||||
LeadOutTypeCmBx.SetValue(Grid.RowProperty, 1)
|
|
||||||
LeadOutTypeCmBx.SetValue(Grid.ColumnProperty, 3)
|
|
||||||
TypeBrd.SetValue(Grid.RowProperty, 12)
|
|
||||||
TypeBrd.SetValue(Grid.RowSpanProperty, 6)
|
|
||||||
End If
|
End If
|
||||||
|
LeadInTypeTxBl.SetValue(Grid.RowProperty, 1)
|
||||||
|
LeadInTypeTxBl.SetValue(Grid.ColumnProperty, 0)
|
||||||
|
LeadInTypeCmBx.SetValue(Grid.RowProperty, 1)
|
||||||
|
LeadInTypeCmBx.SetValue(Grid.ColumnProperty, 1)
|
||||||
|
LeadOutTypeTxBl.SetValue(Grid.RowProperty, 1)
|
||||||
|
LeadOutTypeTxBl.SetValue(Grid.ColumnProperty, 2)
|
||||||
|
LeadOutTypeCmBx.SetValue(Grid.RowProperty, 1)
|
||||||
|
LeadOutTypeCmBx.SetValue(Grid.ColumnProperty, 3)
|
||||||
|
TypeBrd.SetValue(Grid.RowProperty, 12)
|
||||||
|
TypeBrd.SetValue(Grid.RowSpanProperty, 6)
|
||||||
|
|
||||||
LeadInTypeTxBl.Visibility = Windows.Visibility.Visible
|
LeadInTypeTxBl.Visibility = Windows.Visibility.Visible
|
||||||
LeadInTypeCmBx.Visibility = Windows.Visibility.Visible
|
LeadInTypeCmBx.Visibility = Windows.Visibility.Visible
|
||||||
ExtLinkTypeTxBl.Visibility = Windows.Visibility.Hidden
|
ExtLinkTypeTxBl.Visibility = Windows.Visibility.Hidden
|
||||||
@@ -2285,7 +2291,7 @@ Public Class MachiningDbPageUC
|
|||||||
Private Sub MaxThicknessTxBx_EgtClosed(sender As Object, e As EventArgs) Handles MaxThicknessTxBx.EgtClosed
|
Private Sub MaxThicknessTxBx_EgtClosed(sender As Object, e As EventArgs) Handles MaxThicknessTxBx.EgtClosed
|
||||||
Dim SelectedMaterial As MachiningMaterial = MaterialsList.SelectedItem
|
Dim SelectedMaterial As MachiningMaterial = MaterialsList.SelectedItem
|
||||||
Dim dMaxThick As Double = 0
|
Dim dMaxThick As Double = 0
|
||||||
If m_MainWindow.m_CurrentMachine.bWaterJet Then
|
If m_MainWindow.m_CurrentMachine.bWaterJet And m_MainWindow.m_CurrentMachine.bFromDBWaterJet Then
|
||||||
' solo per water jet controllo lo spessore massimo ammissibile
|
' solo per water jet controllo lo spessore massimo ammissibile
|
||||||
dMaxThick = m_MainWindow.m_CurrentMachine.GetMaxThicknessCurrMaterial(SelectedMaterial.Name)
|
dMaxThick = m_MainWindow.m_CurrentMachine.GetMaxThicknessCurrMaterial(SelectedMaterial.Name)
|
||||||
Dim dVal As Double
|
Dim dVal As Double
|
||||||
@@ -2369,7 +2375,6 @@ Public Class MachiningDbPageUC
|
|||||||
Case MCH_MY.POCKETING
|
Case MCH_MY.POCKETING
|
||||||
LeadInTypeCmBx.ItemsSource = New ObservableCollection(Of IdNameStruct)(
|
LeadInTypeCmBx.ItemsSource = New ObservableCollection(Of IdNameStruct)(
|
||||||
{New IdNameStruct(MCH_POCK_LI.NONE, EgtMsg(MSG_COMBOBOXPARAM + 42)),
|
{New IdNameStruct(MCH_POCK_LI.NONE, EgtMsg(MSG_COMBOBOXPARAM + 42)),
|
||||||
New IdNameStruct(MCH_POCK_LI.GLIDE, EgtMsg(MSG_COMBOBOXPARAM + 48)),
|
|
||||||
New IdNameStruct(MCH_POCK_LI.ZIGZAG, EgtMsg(MSG_COMBOBOXPARAM + 38)),
|
New IdNameStruct(MCH_POCK_LI.ZIGZAG, EgtMsg(MSG_COMBOBOXPARAM + 38)),
|
||||||
New IdNameStruct(MCH_POCK_LI.HELIX, EgtMsg(MSG_COMBOBOXPARAM + 49))})
|
New IdNameStruct(MCH_POCK_LI.HELIX, EgtMsg(MSG_COMBOBOXPARAM + 49))})
|
||||||
LeadOutTypeCmBx.ItemsSource = New ObservableCollection(Of IdNameStruct)(
|
LeadOutTypeCmBx.ItemsSource = New ObservableCollection(Of IdNameStruct)(
|
||||||
|
|||||||
+20
-4
@@ -323,8 +323,8 @@ Class MainWindow
|
|||||||
' Verifico abilitazione nesting automatico
|
' Verifico abilitazione nesting automatico
|
||||||
m_bAutoNest = Not String.IsNullOrWhiteSpace(sNestKey)
|
m_bAutoNest = Not String.IsNullOrWhiteSpace(sNestKey)
|
||||||
' Recupero opzioni della chiave
|
' Recupero opzioni della chiave
|
||||||
Dim bKey As Boolean = EgtGetKeyLevel(9423, 2312, 1, m_nKeyLevel) And
|
Dim bKey As Boolean = EgtGetKeyLevel(9423, 2401, 1, m_nKeyLevel) And
|
||||||
EgtGetKeyOptions(9423, 2312, 1, m_nKeyOptions)
|
EgtGetKeyOptions(9423, 2401, 1, m_nKeyOptions)
|
||||||
' Verifico abilitazione prodotto
|
' Verifico abilitazione prodotto
|
||||||
Dim bProd As Boolean = GetKeyOption(KEY_OPT.CUT_BASE)
|
Dim bProd As Boolean = GetKeyOption(KEY_OPT.CUT_BASE)
|
||||||
' Inizializzazione generale di EgtInterface
|
' Inizializzazione generale di EgtInterface
|
||||||
@@ -569,6 +569,8 @@ Class MainWindow
|
|||||||
m_CurrentProjectPageUC.m_SceneButtons.MeasureBtn.IsChecked = False
|
m_CurrentProjectPageUC.m_SceneButtons.MeasureBtn.IsChecked = False
|
||||||
' disbilito Test
|
' disbilito Test
|
||||||
TestOff()
|
TestOff()
|
||||||
|
' disabilito DragRettangle
|
||||||
|
DragRettangleOff()
|
||||||
Select Case m_ActivePage
|
Select Case m_ActivePage
|
||||||
Case Pages.WorkInProgress
|
Case Pages.WorkInProgress
|
||||||
WorkInProgressBtn.IsChecked = True
|
WorkInProgressBtn.IsChecked = True
|
||||||
@@ -625,6 +627,7 @@ Class MainWindow
|
|||||||
EgtMdbGetGeneralParam(MCH_GP.SAFEZ, DirectCutPageUC.m_dZSafe)
|
EgtMdbGetGeneralParam(MCH_GP.SAFEZ, DirectCutPageUC.m_dZSafe)
|
||||||
m_CurrentProjectPageUC.m_SceneButtons.MeasureBtn.IsChecked = False
|
m_CurrentProjectPageUC.m_SceneButtons.MeasureBtn.IsChecked = False
|
||||||
TestOff()
|
TestOff()
|
||||||
|
DragRettangleOff()
|
||||||
Select Case m_ActivePage
|
Select Case m_ActivePage
|
||||||
Case Pages.WorkInProgress
|
Case Pages.WorkInProgress
|
||||||
WorkInProgressBtn.IsChecked = False
|
WorkInProgressBtn.IsChecked = False
|
||||||
@@ -678,6 +681,7 @@ Class MainWindow
|
|||||||
Private Sub CadCutBtn_Click(sender As Object, e As RoutedEventArgs) Handles CadCutBtn.Click
|
Private Sub CadCutBtn_Click(sender As Object, e As RoutedEventArgs) Handles CadCutBtn.Click
|
||||||
m_CurrentProjectPageUC.m_SceneButtons.MeasureBtn.IsChecked = False
|
m_CurrentProjectPageUC.m_SceneButtons.MeasureBtn.IsChecked = False
|
||||||
TestOff()
|
TestOff()
|
||||||
|
DragRettangleOff()
|
||||||
Select Case m_ActivePage
|
Select Case m_ActivePage
|
||||||
Case Pages.WorkInProgress
|
Case Pages.WorkInProgress
|
||||||
WorkInProgressBtn.IsChecked = False
|
WorkInProgressBtn.IsChecked = False
|
||||||
@@ -730,6 +734,7 @@ Class MainWindow
|
|||||||
Private Sub FrameCutBtn_Click(sender As Object, e As RoutedEventArgs) Handles FrameCutBtn.Click
|
Private Sub FrameCutBtn_Click(sender As Object, e As RoutedEventArgs) Handles FrameCutBtn.Click
|
||||||
m_CurrentProjectPageUC.m_SceneButtons.MeasureBtn.IsChecked = False
|
m_CurrentProjectPageUC.m_SceneButtons.MeasureBtn.IsChecked = False
|
||||||
TestOff()
|
TestOff()
|
||||||
|
DragRettangleOff()
|
||||||
Select Case m_ActivePage
|
Select Case m_ActivePage
|
||||||
Case Pages.WorkInProgress
|
Case Pages.WorkInProgress
|
||||||
WorkInProgressBtn.IsChecked = False
|
WorkInProgressBtn.IsChecked = False
|
||||||
@@ -783,6 +788,7 @@ Class MainWindow
|
|||||||
Private Sub MachineBtn_Click(sender As Object, e As RoutedEventArgs) Handles MachineBtn.Click
|
Private Sub MachineBtn_Click(sender As Object, e As RoutedEventArgs) Handles MachineBtn.Click
|
||||||
m_CurrentProjectPageUC.m_SceneButtons.MeasureBtn.IsChecked = False
|
m_CurrentProjectPageUC.m_SceneButtons.MeasureBtn.IsChecked = False
|
||||||
TestOff()
|
TestOff()
|
||||||
|
DragRettangleOff()
|
||||||
Select Case m_ActivePage
|
Select Case m_ActivePage
|
||||||
Case Pages.WorkInProgress
|
Case Pages.WorkInProgress
|
||||||
WorkInProgressBtn.IsChecked = False
|
WorkInProgressBtn.IsChecked = False
|
||||||
@@ -831,6 +837,7 @@ Class MainWindow
|
|||||||
Private Sub OptionsBtn_Click(sender As Object, e As RoutedEventArgs) Handles OptionsBtn.Click
|
Private Sub OptionsBtn_Click(sender As Object, e As RoutedEventArgs) Handles OptionsBtn.Click
|
||||||
m_CurrentProjectPageUC.m_SceneButtons.MeasureBtn.IsChecked = False
|
m_CurrentProjectPageUC.m_SceneButtons.MeasureBtn.IsChecked = False
|
||||||
TestOff()
|
TestOff()
|
||||||
|
DragRettangleOff()
|
||||||
Select Case m_ActivePage
|
Select Case m_ActivePage
|
||||||
Case Pages.WorkInProgress
|
Case Pages.WorkInProgress
|
||||||
WorkInProgressBtn.IsChecked = False
|
WorkInProgressBtn.IsChecked = False
|
||||||
@@ -1140,7 +1147,7 @@ Class MainWindow
|
|||||||
' Aggiorno interfaccia
|
' Aggiorno interfaccia
|
||||||
CadCutBtn.IsEnabled = (nPrjType <> CurrentProjectPageUC.PRJ_TYPE.FRAMES)
|
CadCutBtn.IsEnabled = (nPrjType <> CurrentProjectPageUC.PRJ_TYPE.FRAMES)
|
||||||
FrameCutBtn.IsEnabled = (nPrjType <> CurrentProjectPageUC.PRJ_TYPE.FLATS) AndAlso (EgtGetHeadId("H1") <> GDB_ID.NULL)
|
FrameCutBtn.IsEnabled = (nPrjType <> CurrentProjectPageUC.PRJ_TYPE.FLATS) AndAlso (EgtGetHeadId("H1") <> GDB_ID.NULL)
|
||||||
DirectCutBtn.IsEnabled = (EgtGetHeadId("H1") <> GDB_ID.NULL)
|
' DirectCutBtn.IsEnabled = (EgtGetHeadId("H1") <> GDB_ID.NULL)
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
' Nomi dei file per OmagVIEW
|
' Nomi dei file per OmagVIEW
|
||||||
@@ -1885,8 +1892,17 @@ Class MainWindow
|
|||||||
' deseleziono gli oggetti e spengo il bottone
|
' deseleziono gli oggetti e spengo il bottone
|
||||||
EgtDeselectObj(m_CadCutPageUC.m_NestPage.m_CurrSelectedCurv)
|
EgtDeselectObj(m_CadCutPageUC.m_NestPage.m_CurrSelectedCurv)
|
||||||
EgtDeselectObj(m_CadCutPageUC.m_NestPage.m_CurrSelectedSawCurv)
|
EgtDeselectObj(m_CadCutPageUC.m_NestPage.m_CurrSelectedSawCurv)
|
||||||
|
EgtResetMark(m_CadCutPageUC.m_NestPage.m_CurrSelectedSawCurv)
|
||||||
m_CadCutPageUC.m_ProjectMgr.TestBtn.IsChecked = False
|
m_CadCutPageUC.m_ProjectMgr.TestBtn.IsChecked = False
|
||||||
m_CurrentProjectPageUC.m_bSelectCurv = False
|
Me.m_CadCutPageUC.m_NestPage.m_bSelectCurv = False
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
' spegne il comando per la mofica dei rettangoli
|
||||||
|
Public Sub DragRettangleOff()
|
||||||
|
m_CadCutPageUC.m_NestPage.DragRettanleBtn.IsChecked = False
|
||||||
|
Me.m_CadCutPageUC.m_NestPage.m_bIsCheckedDragRettangle = False
|
||||||
|
ShowParkedParts()
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
End Class
|
End Class
|
||||||
@@ -62,5 +62,5 @@ Imports System.Windows
|
|||||||
' by using the '*' as shown below:
|
' by using the '*' as shown below:
|
||||||
' <Assembly: AssemblyVersion("1.0.*")>
|
' <Assembly: AssemblyVersion("1.0.*")>
|
||||||
|
|
||||||
<Assembly: AssemblyVersion("2.4.1.1")>
|
<Assembly: AssemblyVersion("2.4.1.3")>
|
||||||
<Assembly: AssemblyFileVersion("2.4.1.1")>
|
<Assembly: AssemblyFileVersion("2.4.1.3")>
|
||||||
|
|||||||
@@ -1238,6 +1238,9 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Resource Include="Resources\NewIcons\Acquisisci-P.png" />
|
<Resource Include="Resources\NewIcons\Acquisisci-P.png" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Resource Include="Resources\NewIcons\Drag_Rettangle.png" />
|
||||||
|
</ItemGroup>
|
||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
|
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<PostBuildEvent>IF "$(PlatformName)"=="x86" IF "$(ConfigurationName)" == "Release" copy $(TargetPath) c:\EgtProg\OmagCUT\OmagCUTR32.exe
|
<PostBuildEvent>IF "$(PlatformName)"=="x86" IF "$(ConfigurationName)" == "Release" copy $(TargetPath) c:\EgtProg\OmagCUT\OmagCUTR32.exe
|
||||||
|
|||||||
@@ -105,6 +105,7 @@
|
|||||||
<BitmapImage x:Key="Elimina-pezzoImg" UriSource="Resources/NewIcons/Elimina-pezzo.png"></BitmapImage>
|
<BitmapImage x:Key="Elimina-pezzoImg" UriSource="Resources/NewIcons/Elimina-pezzo.png"></BitmapImage>
|
||||||
<BitmapImage x:Key="Seleziona-tuttoImg" UriSource="Resources/NewIcons/Seleziona-tutto.png"></BitmapImage>
|
<BitmapImage x:Key="Seleziona-tuttoImg" UriSource="Resources/NewIcons/Seleziona-tutto.png"></BitmapImage>
|
||||||
<BitmapImage x:Key="Deseleziona-tuttoImg" UriSource="Resources/NewIcons/Deseleziona-tutto.png"></BitmapImage>
|
<BitmapImage x:Key="Deseleziona-tuttoImg" UriSource="Resources/NewIcons/Deseleziona-tutto.png"></BitmapImage>
|
||||||
|
<BitmapImage x:Key="Drag_RettangleImg" UriSource="Resources/NewIcons/Drag_Rettangle.png"></BitmapImage>
|
||||||
|
|
||||||
<!--Machine-->
|
<!--Machine-->
|
||||||
<BitmapImage x:Key="DatiMacchinaImg" UriSource="Resources/NewIcons/DatiMacchina.png"></BitmapImage>
|
<BitmapImage x:Key="DatiMacchinaImg" UriSource="Resources/NewIcons/DatiMacchina.png"></BitmapImage>
|
||||||
|
|||||||
@@ -173,6 +173,7 @@
|
|||||||
<BitmapImage x:Key="Elimina-pezzoImg" UriSource="Resources/NewIcons/Elimina-pezzo.png"></BitmapImage>
|
<BitmapImage x:Key="Elimina-pezzoImg" UriSource="Resources/NewIcons/Elimina-pezzo.png"></BitmapImage>
|
||||||
<BitmapImage x:Key="Seleziona-tuttoImg" UriSource="Resources/NewIcons/Seleziona-tutto.png"></BitmapImage>
|
<BitmapImage x:Key="Seleziona-tuttoImg" UriSource="Resources/NewIcons/Seleziona-tutto.png"></BitmapImage>
|
||||||
<BitmapImage x:Key="Deseleziona-tuttoImg" UriSource="Resources/NewIcons/Deseleziona-tutto.png"></BitmapImage>
|
<BitmapImage x:Key="Deseleziona-tuttoImg" UriSource="Resources/NewIcons/Deseleziona-tutto.png"></BitmapImage>
|
||||||
|
<BitmapImage x:Key="Drag_RettangleImg" UriSource="Resources/NewIcons/Drag_Rettangle.png"></BitmapImage>
|
||||||
|
|
||||||
<!--Machine-->
|
<!--Machine-->
|
||||||
<BitmapImage x:Key="DatiMacchinaImg" UriSource="Resources/NewIcons/DatiMacchina.png"></BitmapImage>
|
<BitmapImage x:Key="DatiMacchinaImg" UriSource="Resources/NewIcons/DatiMacchina.png"></BitmapImage>
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ Class CicloStartWD
|
|||||||
Me.Top = Owner.Top + Owner.Height / 2 - Me.Height / 2
|
Me.Top = Owner.Top + Owner.Height / 2 - Me.Height / 2
|
||||||
Me.Left = Owner.Left + Owner.Width / 2 - Me.Width / 2
|
Me.Left = Owner.Left + Owner.Width / 2 - Me.Width / 2
|
||||||
' imopposto il messaggio di avvio
|
' imopposto il messaggio di avvio
|
||||||
CicloStartTxbl.Text = "Avvio Ciclo-Start"
|
CicloStartTxbl.Text = EgtMsg(91130) ' Esegui programma?
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
' creo un progetto nuovo
|
' creo un progetto nuovo
|
||||||
|
|||||||
@@ -6,7 +6,6 @@ Imports EgtWPFLib5
|
|||||||
|
|
||||||
Public Class CurrentProjectPageUC
|
Public Class CurrentProjectPageUC
|
||||||
' Dichiarazione eventi
|
' Dichiarazione eventi
|
||||||
Friend Event OnMouseDownSceneSelCurv(sender As Object, e As System.Windows.Forms.MouseEventArgs)
|
|
||||||
Friend Event OnMouseDownScene(sender As Object, e As System.Windows.Forms.MouseEventArgs)
|
Friend Event OnMouseDownScene(sender As Object, e As System.Windows.Forms.MouseEventArgs)
|
||||||
Friend Event OnMouseMoveScene(sender As Object, e As System.Windows.Forms.MouseEventArgs)
|
Friend Event OnMouseMoveScene(sender As Object, e As System.Windows.Forms.MouseEventArgs)
|
||||||
Friend Event OnMouseUpScene(sender As Object, e As System.Windows.Forms.MouseEventArgs)
|
Friend Event OnMouseUpScene(sender As Object, e As System.Windows.Forms.MouseEventArgs)
|
||||||
@@ -24,8 +23,8 @@ Public Class CurrentProjectPageUC
|
|||||||
' Dati del grezzo
|
' Dati del grezzo
|
||||||
Friend m_nRawId As Integer = GDB_ID.NULL
|
Friend m_nRawId As Integer = GDB_ID.NULL
|
||||||
Friend m_dRawHeight As Double
|
Friend m_dRawHeight As Double
|
||||||
' pagina impostata per selezionare una lavorazione
|
'' Flag per impostata per selezionare di una curva
|
||||||
Friend m_bSelectCurv As Boolean = False
|
'Friend m_bSelectCurv As Boolean = False
|
||||||
' Costanti tipo progetto
|
' Costanti tipo progetto
|
||||||
Friend Enum PRJ_TYPE As Integer
|
Friend Enum PRJ_TYPE As Integer
|
||||||
EMPTY = 0
|
EMPTY = 0
|
||||||
@@ -328,12 +327,7 @@ Public Class CurrentProjectPageUC
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub OnMyMouseDownScene(sender As Object, e As System.Windows.Forms.MouseEventArgs) Handles CurrentProjectScene.OnMouseDownScene
|
Private Sub OnMyMouseDownScene(sender As Object, e As System.Windows.Forms.MouseEventArgs) Handles CurrentProjectScene.OnMouseDownScene
|
||||||
If m_bSelectCurv Then
|
RaiseEvent OnMouseDownScene(sender, e)
|
||||||
RaiseEvent OnMouseDownSceneSelCurv(sender, e)
|
|
||||||
Else
|
|
||||||
RaiseEvent OnMouseDownScene(sender, e)
|
|
||||||
End If
|
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub OnMyMouseMoveScene(sender As Object, e As System.Windows.Forms.MouseEventArgs) Handles CurrentProjectScene.OnMouseMoveScene
|
Private Sub OnMyMouseMoveScene(sender As Object, e As System.Windows.Forms.MouseEventArgs) Handles CurrentProjectScene.OnMouseMoveScene
|
||||||
|
|||||||
@@ -276,7 +276,7 @@ Public Class ProjectMgrUC
|
|||||||
m_CurrProjPage.SetWarningMessage("Trial Version")
|
m_CurrProjPage.SetWarningMessage("Trial Version")
|
||||||
#Else
|
#Else
|
||||||
' se sono in modalità Test allora eseguo solo il posizionamento della lama
|
' se sono in modalità Test allora eseguo solo il posizionamento della lama
|
||||||
If m_CurrProjPage.m_bSelectCurv Then
|
If m_MainWindow.m_CadCutPageUC.m_NestPage.m_bSelectCurv Then
|
||||||
' Verifico non sia versione Ufficio
|
' Verifico non sia versione Ufficio
|
||||||
If m_MainWindow.GetKeyOption(MainWindow.KEY_OPT.OFFICE_TYPE) Then
|
If m_MainWindow.GetKeyOption(MainWindow.KEY_OPT.OFFICE_TYPE) Then
|
||||||
m_CurrProjPage.SetWarningMessage("Office Version")
|
m_CurrProjPage.SetWarningMessage("Office Version")
|
||||||
@@ -336,7 +336,7 @@ Public Class ProjectMgrUC
|
|||||||
' verifica assi lineari
|
' verifica assi lineari
|
||||||
EgtVerifyOutstroke(dX, dY, dZ, dC1, dB1, nStat)
|
EgtVerifyOutstroke(dX, dY, dZ, dC1, dB1, nStat)
|
||||||
If nStat <> 0 Then
|
If nStat <> 0 Then
|
||||||
vtDirT = - vtDirT
|
vtDirT = -vtDirT
|
||||||
ptMid -= vtDirT * dThick
|
ptMid -= vtDirT * dThick
|
||||||
EgtGetCalcAngles(vtDirT, Vector3d.Z_AX(), nStat, dC1, dB1, dC2, dB2)
|
EgtGetCalcAngles(vtDirT, Vector3d.Z_AX(), nStat, dC1, dB1, dC2, dB2)
|
||||||
' calcolo la posizione degli assi lineari X, Y, Z ( correggere il punto ptMid.z sommando il raggio utensile)
|
' calcolo la posizione degli assi lineari X, Y, Z ( correggere il punto ptMid.z sommando il raggio utensile)
|
||||||
@@ -736,11 +736,11 @@ Public Class ProjectMgrUC
|
|||||||
|
|
||||||
Private Sub TestBtn_Click(sender As Object, e As RoutedEventArgs) Handles TestBtn.Click
|
Private Sub TestBtn_Click(sender As Object, e As RoutedEventArgs) Handles TestBtn.Click
|
||||||
If TestBtn.IsChecked Then
|
If TestBtn.IsChecked Then
|
||||||
m_CurrProjPage.m_bSelectCurv = True
|
m_MainWindow.m_CadCutPageUC.m_NestPage.m_bSelectCurv = True
|
||||||
' deseleziono tutto
|
' deseleziono tutto
|
||||||
EgtDeselectAll()
|
EgtDeselectAll()
|
||||||
Else
|
Else
|
||||||
m_CurrProjPage.m_bSelectCurv = False
|
m_MainWindow.m_CadCutPageUC.m_NestPage.m_bSelectCurv = False
|
||||||
EgtDeselectObj(m_MainWindow.m_CadCutPageUC.m_NestPage.m_CurrSelectedCurv)
|
EgtDeselectObj(m_MainWindow.m_CadCutPageUC.m_NestPage.m_CurrSelectedCurv)
|
||||||
EgtDeselectObj(m_MainWindow.m_CadCutPageUC.m_NestPage.m_CurrSelectedSawCurv)
|
EgtDeselectObj(m_MainWindow.m_CadCutPageUC.m_NestPage.m_CurrSelectedSawCurv)
|
||||||
End If
|
End If
|
||||||
|
|||||||
@@ -263,7 +263,7 @@ Public Class ChooseMachining
|
|||||||
If SysNotes <> String.Empty Then
|
If SysNotes <> String.Empty Then
|
||||||
Dim MachiningMaterials() = SysNotes.Split(";".ToCharArray)
|
Dim MachiningMaterials() = SysNotes.Split(";".ToCharArray)
|
||||||
SysNotes = String.Empty
|
SysNotes = String.Empty
|
||||||
If m_CurrentMachine.bWaterJet Then
|
If m_CurrentMachine.bWaterJet And m_CurrentMachine.bFromDBWaterJet Then
|
||||||
For Each Material As Object In MachiningMaterials
|
For Each Material As Object In MachiningMaterials
|
||||||
Dim Param() As String = Material.Split(",".ToCharArray)
|
Dim Param() As String = Material.Split(",".ToCharArray)
|
||||||
Dim SubParam() As String = Param(0).Split(".".ToCharArray)
|
Dim SubParam() As String = Param(0).Split(".".ToCharArray)
|
||||||
@@ -589,18 +589,24 @@ Public Class ChooseMachining
|
|||||||
' verifico che sia stato inserito veramente una lavorazione prima di comunicare una modifica
|
' verifico che sia stato inserito veramente una lavorazione prima di comunicare una modifica
|
||||||
If CurrMillingCmBx.SelectedItem <> m_CurrentMachine.sCurrWaterJetting Then m_MachIsModified = True
|
If CurrMillingCmBx.SelectedItem <> m_CurrentMachine.sCurrWaterJetting Then m_MachIsModified = True
|
||||||
End If
|
End If
|
||||||
If String.IsNullOrEmpty(CurrWJettingQualityCmBx.SelectedItem) Then
|
|
||||||
CurrWJettingQualityCmBx.SelectedItem = m_CurrentMachine.sCurrWaterJettingQuality
|
|
||||||
End If
|
|
||||||
' verifico che la selezione sia andata a buon fine, altrimenti comunico l'avvenuta modifica
|
|
||||||
If String.IsNullOrEmpty(CurrWJettingQualityCmBx.SelectedItem) Then
|
|
||||||
' verifico che sia stato inserito veramente una lavorazione prima di comunicare una modifica
|
|
||||||
If CurrWJettingQualityCmBx.SelectedItem <> m_CurrentMachine.sCurrWaterJettingQuality Then m_MachIsModified = True
|
|
||||||
End If
|
|
||||||
|
|
||||||
CurrWJettingQualityCmBx.Visibility = Windows.Visibility.Visible
|
|
||||||
CurrWJettingTxBl.Visibility = Windows.Visibility.Visible
|
CurrWJettingTxBl.Visibility = Windows.Visibility.Visible
|
||||||
CurrWJettingCmBx.Visibility = Windows.Visibility.Visible
|
CurrWJettingCmBx.Visibility = Windows.Visibility.Visible
|
||||||
|
' se DB WaterJet abilitato avrò anche la CmBx della Quality altrimenti espando la CmBx del Waterjetting corrente su tutta la riga
|
||||||
|
If m_MainWindow.m_CurrentMachine.bFromDBWaterJet Then
|
||||||
|
CurrWJettingCmBx.SetValue(Grid.ColumnSpanProperty, 1)
|
||||||
|
If String.IsNullOrEmpty(CurrWJettingQualityCmBx.SelectedItem) Then
|
||||||
|
CurrWJettingQualityCmBx.SelectedItem = m_CurrentMachine.sCurrWaterJettingQuality
|
||||||
|
End If
|
||||||
|
' verifico che la selezione sia andata a buon fine, altrimenti comunico l'avvenuta modifica
|
||||||
|
If String.IsNullOrEmpty(CurrWJettingQualityCmBx.SelectedItem) Then
|
||||||
|
' verifico che sia stato inserito veramente una lavorazione prima di comunicare una modifica
|
||||||
|
If CurrWJettingQualityCmBx.SelectedItem <> m_CurrentMachine.sCurrWaterJettingQuality Then m_MachIsModified = True
|
||||||
|
End If
|
||||||
|
CurrWJettingQualityCmBx.Visibility = Windows.Visibility.Visible
|
||||||
|
Else
|
||||||
|
CurrWJettingCmBx.SetValue(Grid.ColumnSpanProperty, 3)
|
||||||
|
CurrWJettingQualityCmBx.Visibility = Windows.Visibility.Collapsed
|
||||||
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Me.Height = 42 * m_RowNumber
|
Me.Height = 42 * m_RowNumber
|
||||||
@@ -633,10 +639,14 @@ Public Class ChooseMachining
|
|||||||
|
|
||||||
Private Sub OkBtn_Click(sender As Object, e As RoutedEventArgs) Handles OkBtn.Click
|
Private Sub OkBtn_Click(sender As Object, e As RoutedEventArgs) Handles OkBtn.Click
|
||||||
DialogResult = True
|
DialogResult = True
|
||||||
|
' Aggiorno i parametri dei tagli diretti
|
||||||
|
m_MainWindow.m_DirectCutPageUC.ReloadParam()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub ExitBtn_Click(sender As Object, e As RoutedEventArgs) Handles ExitBtn.Click
|
Private Sub ExitBtn_Click(sender As Object, e As RoutedEventArgs) Handles ExitBtn.Click
|
||||||
DialogResult = False
|
DialogResult = False
|
||||||
|
' Aggiorno i parametri dei tagli diretti
|
||||||
|
m_MainWindow.m_DirectCutPageUC.ReloadParam()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
@@ -167,7 +167,7 @@ Public Class RawPartPageUC
|
|||||||
Private Sub RawPartPage_Loaded(sender As Object, e As RoutedEventArgs)
|
Private Sub RawPartPage_Loaded(sender As Object, e As RoutedEventArgs)
|
||||||
' aggiorno la lista dei materiali
|
' aggiorno la lista dei materiali
|
||||||
Dim Index As Integer = 1
|
Dim Index As Integer = 1
|
||||||
If m_CurrentMachine.bWaterJet Then
|
If m_CurrentMachine.bWaterJet And m_CurrentMachine.bFromDBWaterJet Then
|
||||||
m_CurrentMachine.LoadWJMaterial()
|
m_CurrentMachine.LoadWJMaterial()
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|||||||
Binary file not shown.
|
After Width: | Height: | Size: 1.6 KiB |
Reference in New Issue
Block a user