Compare commits
29 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| d6a9cac6b4 | |||
| 4ce898c25c | |||
| 6f59cddd80 | |||
| c8b018f6df | |||
| e287e827c4 | |||
| 68e9a9201d | |||
| 8946bf3a00 | |||
| a15acb6528 | |||
| e7e9d26b75 | |||
| d9de23daca | |||
| ad5c9331ba | |||
| b67330b509 | |||
| ca66108145 | |||
| 379ccc7519 | |||
| b751c27773 | |||
| 14e1c254f0 | |||
| 6f08e5f520 | |||
| 7d8933cc39 | |||
| 2179996bff | |||
| 316bcc89ea | |||
| 17f41f1563 | |||
| 6a17b88283 | |||
| ce151e5db7 | |||
| b303fe2615 | |||
| 6f248ec645 | |||
| 3e0d43c1d8 | |||
| 70b1822446 | |||
| 17d6ced974 | |||
| 4432893794 |
@@ -27,6 +27,14 @@
|
||||
<EgtWPFLib:EgtTextBox Name="ValueTxBx" Grid.Column="1" Grid.Row="1"
|
||||
Style="{StaticResource OmagCut_CalculatorTextBox}"/>
|
||||
|
||||
<ComboBox Name="ValueCmBx" Grid.Column="1" Grid.Row="1">
|
||||
<ComboBox.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding}" FontSize="20" />
|
||||
</DataTemplate>
|
||||
</ComboBox.ItemTemplate>
|
||||
</ComboBox>
|
||||
|
||||
<Grid Name="ButtonsGrid" Grid.Column="1" Grid.Row="3" Grid.RowSpan="1">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="0.5*"/>
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
Imports System.IO
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib
|
||||
Imports System.Collections.ObjectModel
|
||||
|
||||
Public Class EditValueWD
|
||||
|
||||
@@ -8,10 +9,14 @@ Public Class EditValueWD
|
||||
Private m_MainWindow As MainWindow = DirectCast(Application.Current.MainWindow, MainWindow)
|
||||
Private m_sMsg As String = "Value"
|
||||
Private m_sValue As String = ""
|
||||
Private m_sList As ObservableCollection(Of String)
|
||||
Private m_IsText As Boolean = True
|
||||
|
||||
' avvia la visualizzazione della textbox
|
||||
Sub New(Owner As Window, Optional sMsg As String = "")
|
||||
Me.Owner = Owner
|
||||
m_sMsg = sMsg
|
||||
m_IsText = True
|
||||
InitializeComponent()
|
||||
End Sub
|
||||
|
||||
@@ -21,11 +26,20 @@ Public Class EditValueWD
|
||||
Else
|
||||
m_sValue = DoubleToString(dVal, 3)
|
||||
End If
|
||||
|
||||
ValueTxBx.Text = m_sValue
|
||||
Return True
|
||||
End Function
|
||||
|
||||
' avvia la visualizzazione della combobox
|
||||
Sub New(Owner As Window, sList As ObservableCollection(Of String), Optional sMsg As String = "")
|
||||
Me.Owner = Owner
|
||||
m_sMsg = sMsg
|
||||
m_IsText = False
|
||||
InitializeComponent()
|
||||
m_sList = sList
|
||||
SetComboBox(m_sList)
|
||||
End Sub
|
||||
|
||||
Friend Function GetVal(Optional ByVal bLen As Boolean = False) As Double
|
||||
Dim dVal As Double = 0
|
||||
If bLen Then
|
||||
@@ -36,10 +50,36 @@ Public Class EditValueWD
|
||||
Return dVal
|
||||
End Function
|
||||
|
||||
Friend Function SetComboBox(sList As ObservableCollection(Of String)) As Boolean
|
||||
ValueCmBx.ItemsSource = sList
|
||||
Return True
|
||||
End Function
|
||||
|
||||
Friend Function SetItemComboBox(sItem As String) As Boolean
|
||||
For Each MyItem As String In ValueCmBx.ItemsSource
|
||||
If MyItem = sItem Then
|
||||
ValueCmBx.SelectedItem = MyItem
|
||||
End If
|
||||
Next
|
||||
Return True
|
||||
End Function
|
||||
|
||||
Friend Function GetItemComboBox() As String
|
||||
Dim sVal As String = ValueCmBx.SelectedItem
|
||||
Return sVal
|
||||
End Function
|
||||
|
||||
Private Sub EditValueWD_Initialized(sender As Object, e As EventArgs) Handles Me.Initialized
|
||||
Me.Top = Owner.Top + Owner.Height / 2 - Me.Height / 2
|
||||
Me.Left = Owner.Left + Owner.Width / 2 - Me.Width / 2
|
||||
ValueTxbl.Text = m_sMsg
|
||||
If m_IsText Then
|
||||
ValueCmBx.Visibility = Visibility.Collapsed
|
||||
ValueTxBx.Visibility = Visibility.Visible
|
||||
Else
|
||||
ValueCmBx.Visibility = Visibility.Visible
|
||||
ValueTxBx.Visibility = Visibility.Collapsed
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub EditValueWD_Rendered(sender As Object, e As EventArgs) Handles Me.ContentRendered
|
||||
|
||||
@@ -837,6 +837,7 @@ Public Class MoveRawPartPage
|
||||
EgtGetRawPartCenter(nRawId, ptRawCen)
|
||||
' Sposto il grezzo in battuta sul corner
|
||||
Dim dAngRaw As Double = 0
|
||||
Dim dNewAngRot As Double = 0
|
||||
|
||||
Dim AngRotList As New List(Of Double)
|
||||
|
||||
@@ -877,12 +878,16 @@ Public Class MoveRawPartPage
|
||||
' sposto il pezzo in questa posizione
|
||||
EgtMoveToCornerRawPart(nRawId, ptCorner, MCH_CR.BL)
|
||||
' riprovo il movimento
|
||||
If EgtRotateRawPart(nRawId, Vector3d.Z_AX(), -dAngRaw) Then
|
||||
dNewAngRot = GetPrefRotAng(dAngRaw)
|
||||
'dNewAngRot = DeltaAngC
|
||||
If EgtRotateRawPart(nRawId, Vector3d.Z_AX(), dNewAngRot) Then
|
||||
If Not EgtMoveToCornerRawPart(nRawId, ptRef, nCorn) Then
|
||||
' riposiziono il pezzo come era prima
|
||||
EgtRotateRawPart(nRawId, Vector3d.Z_AX(), dAngRaw)
|
||||
EgtRotateRawPart(nRawId, Vector3d.Z_AX(), -dAngRaw)
|
||||
EgtDraw()
|
||||
Return
|
||||
End If
|
||||
dAngRaw = dNewAngRot
|
||||
Else
|
||||
Return
|
||||
End If
|
||||
@@ -908,17 +913,18 @@ Public Class MoveRawPartPage
|
||||
End If
|
||||
nOtherRaw = EgtGetNextRawPart(nOtherRaw)
|
||||
End While
|
||||
|
||||
' Determino il movimento effettuato
|
||||
Dim ptNewRawCen As Point3d
|
||||
EgtGetRawPartCenter(nRawId, ptNewRawCen)
|
||||
' Se tutto bene, aggiorno lista movimenti
|
||||
If bRawOk Then
|
||||
AddRawMoveData(nRawId, ptNewRawCen - ptRawCen, m_RawMoveDataList)
|
||||
If dAngRaw <> 0 Then AddRawMoveData(nRawId, -dAngRaw, m_RawMoveDataList)
|
||||
If dAngRaw <> 0 Then AddRawMoveData(nRawId, dAngRaw, m_RawMoveDataList)
|
||||
' altrimenti annullo il movimento
|
||||
Else
|
||||
EgtMoveRawPart(nRawId, ptRawCen - ptNewRawCen)
|
||||
EgtRotateRawPart(nRawId, Vector3d.Z_AX(), dAngRaw)
|
||||
EgtRotateRawPart(nRawId, Vector3d.Z_AX(), -dAngRaw)
|
||||
m_CurrProjPage.SetWarningMessage(EgtMsg(MSG_MOVERAWPAGEUC + 3)) ' Posizione scelta già occupata
|
||||
End If
|
||||
' Disabilito pezzo e nascondo le ventose
|
||||
@@ -991,6 +997,15 @@ Public Class MoveRawPartPage
|
||||
Return True
|
||||
End Function
|
||||
|
||||
' determino la migliore rotazione per portare il pezzo in orizzontale
|
||||
Private Function GetPrefRotAng(ByVal dAngDeg As Double) As Double
|
||||
Dim dNewAngDeg As Double = -dAngDeg
|
||||
If dAngDeg > 90 And dAngDeg < 270 Then
|
||||
dNewAngDeg = 180 - dAngDeg
|
||||
End If
|
||||
Return dNewAngDeg
|
||||
End Function
|
||||
|
||||
Private Sub PauseBtn_Click(sender As Object, e As RoutedEventArgs) Handles PauseBtn.Click
|
||||
' verifico che ci sia almeno un elemto selezionato (dati di aggancio pezzo)
|
||||
If m_RawMoveDataList.Count = 0 Then Return
|
||||
|
||||
@@ -1353,8 +1353,8 @@ Public Class NestPageUC
|
||||
VeinMatching.OnDeselectPart(m_nIdToDesel)
|
||||
End If
|
||||
|
||||
|
||||
' Reset
|
||||
GetFamilyGroupInPark()
|
||||
m_bDrag = False
|
||||
m_nIdToSel = GDB_ID.NULL
|
||||
m_nIdToDesel = GDB_ID.NULL
|
||||
|
||||
@@ -132,23 +132,31 @@
|
||||
<Button Name="CutBtn" Grid.Column="0" Style="{DynamicResource OmagCut_YellowIconButton}">
|
||||
<Image Source="{DynamicResource Allunga-AccorciaImg}" Style="{StaticResource OmagCut_ArrowButtonIcon}"/>
|
||||
</Button>
|
||||
|
||||
<Button Name="CutStartBtn" Grid.Column="1" Style="{DynamicResource OmagCut_YellowIconButton}">
|
||||
<Image Source="{DynamicResource Inizio-Allunga-AccorciaImg}" Style="{StaticResource OmagCut_ArrowButtonIcon}"/>
|
||||
</Button>
|
||||
|
||||
<Button Name="CutEndBtn" Grid.Column="2" Style="{DynamicResource OmagCut_YellowIconButton}">
|
||||
<Image Source="{DynamicResource Fine-Allunga-AccorciaImg}" Style="{StaticResource OmagCut_ArrowButtonIcon}"/>
|
||||
</Button>
|
||||
|
||||
<!-- solo per macchine con lavorazioni Waterjet -->
|
||||
<ToggleButton Name="BridgesWJBtn" Grid.Column="0" Style="{DynamicResource OmagCut_YellowIconToggleButton}">
|
||||
<Image Source="{DynamicResource PonticelliWJImg}" Style="{StaticResource OmagCut_ArrowButtonIcon}"/>
|
||||
</ToggleButton>
|
||||
|
||||
<!--solo per macchine con lavorazioni Waterjet-->
|
||||
<Button Name="QualityWJBtn" Grid.Column="1" Style="{DynamicResource OmagCut_YellowIconButton}">
|
||||
<Image Source="{DynamicResource QualityWJImg}" Style="{StaticResource OmagCut_ArrowButtonIcon}"/>
|
||||
</Button>
|
||||
|
||||
<!-- solo per macchine con lavorazioni Waterjet -->
|
||||
<ToggleButton Name="BridgesDeleteWJBtn" Grid.Column="3" Style="{DynamicResource OmagCut_YellowIconToggleButton}">
|
||||
<Image Source="{DynamicResource PonticelliDeleteWJImg}" Style="{StaticResource OmagCut_ArrowButtonIcon}"/>
|
||||
</ToggleButton>
|
||||
|
||||
<Button Name="CutEndBtn" Grid.Column="2" Style="{DynamicResource OmagCut_YellowIconButton}">
|
||||
<Image Source="{DynamicResource Fine-Allunga-AccorciaImg}" Style="{StaticResource OmagCut_ArrowButtonIcon}"/>
|
||||
</Button>
|
||||
|
||||
|
||||
</Grid>
|
||||
|
||||
|
||||
+126
-74
@@ -978,6 +978,54 @@ Public Class SplitPageUC
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub QualityWJBtn_Click(Sender As Object, e As RoutedEventArgs) Handles QualityWJBtn.Click
|
||||
Dim bFirstWJ As Boolean = True
|
||||
Dim sQuality As String = String.Empty
|
||||
' Recupero la lavorazione corrente
|
||||
If m_CurrFirstInd = -1 Then Return
|
||||
Dim bGenModif As Boolean = False
|
||||
For Index As Integer = m_CurrFirstInd To m_CurrLastInd
|
||||
If Not m_ItemList(Index).IsSelected Then
|
||||
Continue For
|
||||
End If
|
||||
Dim nI As Integer = m_ItemList(Index).Ind
|
||||
Dim nOperId As Integer = m_MachiningList(nI).m_nId
|
||||
Dim nMachiningType As Integer = EgtGetOperationType(nOperId)
|
||||
' se altrimenti getto d'acqua
|
||||
If nMachiningType = MCH_MY.WATERJETTING Then
|
||||
' ------------------ INIZIO PREPARAZIONE TASTIERINO VIRTUALE ------------------
|
||||
If bFirstWJ Then
|
||||
EgtSetCurrMachining(nOperId)
|
||||
' Dialogo richiesta valore
|
||||
Dim ValWnd As New EditValueWD(m_MainWindow, m_MainWindow.m_CurrentMachine.Qualities, "Quality")
|
||||
If EgtGetInfo(nOperId, "Quality", sQuality) Then
|
||||
ValWnd.SetItemComboBox(sQuality)
|
||||
Else
|
||||
ValWnd.SetItemComboBox(m_MainWindow.m_CurrentMachine.sCurrWaterJettingQuality)
|
||||
End If
|
||||
If Not ValWnd.ShowDialog() Then Return
|
||||
sQuality = ValWnd.GetItemComboBox
|
||||
' comunico che ho letto il primo dato
|
||||
bFirstWJ = False
|
||||
End If
|
||||
' ------------------ INIZIO PREPARAZIONE TASTIERINO VIRTUALE ------------------
|
||||
' Modifica della lavorazione
|
||||
EgtSetCurrMachining(nOperId)
|
||||
EgtSetInfo(nOperId, "Quality", sQuality)
|
||||
UpdateMachiningPreview(m_MachiningList(nI).m_nId, True)
|
||||
' verifico interferenza
|
||||
bGenModif = True
|
||||
End If
|
||||
Next
|
||||
' Se modificato qualcosa
|
||||
If bGenModif Then
|
||||
EgtDraw()
|
||||
m_bModified = True
|
||||
End If
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
Private Function AdjustBothCuts(nI As Integer,
|
||||
Optional bAllForced As Boolean = False,
|
||||
Optional bAccForced As Boolean = False) As Boolean
|
||||
@@ -1960,7 +2008,7 @@ Public Class SplitPageUC
|
||||
Dim MyCuts As New List(Of Integer)
|
||||
For nI As Integer = 0 To m_MachiningList.Count() - 1
|
||||
If m_MachiningList(nI).m_bEnabled And
|
||||
( m_MachiningList(nI).m_sLay = NAME_OUTLOOP Or m_MachiningList(nI).m_sLay = NAME_INLOOP) Then
|
||||
(m_MachiningList(nI).m_sLay = NAME_OUTLOOP Or m_MachiningList(nI).m_sLay = NAME_INLOOP) Then
|
||||
MyCuts.Add(m_MachiningList(nI).m_nId)
|
||||
End If
|
||||
Next
|
||||
@@ -1972,7 +2020,7 @@ Public Class SplitPageUC
|
||||
PrevBtn.IsEnabled = (m_nCurrPhase > 1)
|
||||
' Per bottone NEXT
|
||||
' Se abilitato manipolatore e non è con waterjet
|
||||
If ( m_MainWindow.GetKeyOption(MainWindow.KEY_OPT.MAN_MANIP) Or
|
||||
If (m_MainWindow.GetKeyOption(MainWindow.KEY_OPT.MAN_MANIP) Or
|
||||
m_MainWindow.GetKeyOption(MainWindow.KEY_OPT.AUTO_MANIP)) And
|
||||
Not m_MainWindow.m_CurrentMachine.bWaterJetting Then
|
||||
' Se in modifica
|
||||
@@ -2034,6 +2082,7 @@ Public Class SplitPageUC
|
||||
PauseBtn.IsEnabled = Not m_bShow And m_MainWindow.m_CurrentMachine.bEnablePause
|
||||
BridgesWJBtn.IsEnabled = Not m_bShow
|
||||
BridgesDeleteWJBtn.IsEnabled = Not m_bShow
|
||||
QualityWJBtn.IsEnabled = Not m_bShow
|
||||
|
||||
' nascondo i comandi che non devono essere visualizzati in funzione delle lavorazioni attive
|
||||
If m_nCountSawing = 0 And (m_nCountWaterjetting > 0 Or m_nCountOtherMachining) Then
|
||||
@@ -2153,13 +2202,16 @@ Public Class SplitPageUC
|
||||
If CutStartBtn.Visibility = Visibility.Hidden Then
|
||||
BridgesWJBtn.Visibility = Visibility.Visible
|
||||
BridgesDeleteWJBtn.Visibility = Visibility.Visible
|
||||
QualityWJBtn.Visibility = Visibility.Visible
|
||||
Else
|
||||
BridgesWJBtn.Visibility = Visibility.Hidden
|
||||
BridgesDeleteWJBtn.Visibility = Visibility.Hidden
|
||||
QualityWJBtn.Visibility = Visibility.Hidden
|
||||
End If
|
||||
Else
|
||||
BridgesWJBtn.Visibility = Visibility.Hidden
|
||||
BridgesDeleteWJBtn.Visibility = Visibility.Hidden
|
||||
QualityWJBtn.Visibility = Visibility.Hidden
|
||||
End If
|
||||
End Sub
|
||||
|
||||
@@ -2181,7 +2233,7 @@ Public Class SplitPageUC
|
||||
Return True
|
||||
End Function
|
||||
|
||||
Private Sub NumberDirectionMachining( nI As Integer, Optional bNumber As Boolean = True)
|
||||
Private Sub NumberDirectionMachining(nI As Integer, Optional bNumber As Boolean = True)
|
||||
EgtDisableModified()
|
||||
' Determino se seconda lavorazione
|
||||
Dim sName As String = String.Empty
|
||||
@@ -2215,28 +2267,28 @@ Public Class SplitPageUC
|
||||
End If
|
||||
|
||||
If bNumber Then
|
||||
Dim nNbrId As Integer = EgtCreateTextAdv( m_nNbrGrpId, ptCen, 0, (nI + 1).ToString(), "",
|
||||
Dim nNbrId As Integer = EgtCreateTextAdv(m_nNbrGrpId, ptCen, 0, (nI + 1).ToString(), "",
|
||||
300, False, dHtxt, dRat, 0, INS_POS.MC)
|
||||
m_MachiningList(nI).m_nNbrId = nNbrId
|
||||
' Aggiungo a numero info con identificativo della lavorazione e viceversa
|
||||
EgtSetInfo( nNbrId, "MId", m_MachiningList(nI).m_nId)
|
||||
EgtSetInfo( m_MachiningList(nI).m_nId, "NbrId", nNbrId)
|
||||
EgtSetInfo(nNbrId, "MId", m_MachiningList(nI).m_nId)
|
||||
EgtSetInfo(m_MachiningList(nI).m_nId, "NbrId", nNbrId)
|
||||
End If
|
||||
' Se taglio con lama, metto la direzione accanto al numero
|
||||
If m_MachiningList(nI).m_nType = MCH_OY.SAWING Then
|
||||
Dim ptStart As New Point3d( ptCen + m_MachiningList(nI).m_vtDir * dHtxt)
|
||||
Dim vtDir As New Vector3d( m_MachiningList(nI).m_vtDir)
|
||||
Dim bTwin As Boolean = ( Not m_MachiningList(nI).m_bEnableInvert OrElse Math.Abs( m_MachiningList(nI).m_dSideAng) > 0.1)
|
||||
Dim nArrId As Integer = AddMachiningDirection( ptStart, vtDir, dHtxt, bTwin)
|
||||
Dim ptStart As New Point3d(ptCen + m_MachiningList(nI).m_vtDir * dHtxt)
|
||||
Dim vtDir As New Vector3d(m_MachiningList(nI).m_vtDir)
|
||||
Dim bTwin As Boolean = (Not m_MachiningList(nI).m_bEnableInvert OrElse Math.Abs(m_MachiningList(nI).m_dSideAng) > 0.1)
|
||||
Dim nArrId As Integer = AddMachiningDirection(ptStart, vtDir, dHtxt, bTwin)
|
||||
m_MachiningList(nI).m_nArrId = nArrId
|
||||
' Aggiungo a freccia info con identificativo della lavorazione e viceversa
|
||||
EgtSetInfo( nArrId, "MId", m_MachiningList(nI).m_nId)
|
||||
EgtSetInfo( m_MachiningList(nI).m_nId, "ArrId", nArrId)
|
||||
EgtSetInfo(nArrId, "MId", m_MachiningList(nI).m_nId)
|
||||
EgtSetInfo(m_MachiningList(nI).m_nId, "ArrId", nArrId)
|
||||
Else
|
||||
m_MachiningList(nI).m_nArrId = GDB_ID.NULL
|
||||
End If
|
||||
' Assegno colore a numero e freccia
|
||||
ColorNumberArrow( nI)
|
||||
ColorNumberArrow(nI)
|
||||
EgtEnableModified()
|
||||
End Sub
|
||||
|
||||
@@ -2298,18 +2350,18 @@ Public Class SplitPageUC
|
||||
Return True
|
||||
End Function
|
||||
|
||||
Private Function AddMachiningDirection( ptStart As Point3d, vtDir As Vector3d, dLen As Double, bTwin As Boolean) As Integer
|
||||
Dim dArrX As Double = dLen * Math.Cos( 30 * Math.PI / 180)
|
||||
Dim dArrY As Double = dLen * Math.Sin( 30 * Math.PI / 180)
|
||||
Dim nTmpId As Integer = EgtCreateLine( m_nNbrGrpId, Point3d.ORIG() + dArrY * Vector3d.Y_AX(), Point3d.ORIG() + dArrX * Vector3d.X_AX())
|
||||
Dim nCrvId As Integer = EgtCreateCurveCompo( m_nNbrGrpId, nTmpId, True)
|
||||
EgtAddCurveCompoLine( nCrvId, Point3d.ORIG() - dArrY * Vector3d.Y_AX())
|
||||
Private Function AddMachiningDirection(ptStart As Point3d, vtDir As Vector3d, dLen As Double, bTwin As Boolean) As Integer
|
||||
Dim dArrX As Double = dLen * Math.Cos(30 * Math.PI / 180)
|
||||
Dim dArrY As Double = dLen * Math.Sin(30 * Math.PI / 180)
|
||||
Dim nTmpId As Integer = EgtCreateLine(m_nNbrGrpId, Point3d.ORIG() + dArrY * Vector3d.Y_AX(), Point3d.ORIG() + dArrX * Vector3d.X_AX())
|
||||
Dim nCrvId As Integer = EgtCreateCurveCompo(m_nNbrGrpId, nTmpId, True)
|
||||
EgtAddCurveCompoLine(nCrvId, Point3d.ORIG() - dArrY * Vector3d.Y_AX())
|
||||
If bTwin Then
|
||||
EgtAddCurveCompoLine( nCrvId, Point3d.ORIG() + 2 * dArrX * Vector3d.X_AX())
|
||||
EgtCloseCurveCompo( nCrvId)
|
||||
EgtAddCurveCompoLine(nCrvId, Point3d.ORIG() + 2 * dArrX * Vector3d.X_AX())
|
||||
EgtCloseCurveCompo(nCrvId)
|
||||
End If
|
||||
Dim frLoc As New Frame3d( ptStart, vtDir, Vector3d.Z_AX() ^ vtDir, Vector3d.Z_AX())
|
||||
EgtTransform( nCrvId, frLoc)
|
||||
Dim frLoc As New Frame3d(ptStart, vtDir, Vector3d.Z_AX() ^ vtDir, Vector3d.Z_AX())
|
||||
EgtTransform(nCrvId, frLoc)
|
||||
Return nCrvId
|
||||
End Function
|
||||
|
||||
@@ -2340,35 +2392,35 @@ Public Class SplitPageUC
|
||||
Private Sub MarkNumberArrow(nI As Integer, bMark As Boolean)
|
||||
If nI < 0 Then Return
|
||||
Dim nNbrId As Integer = m_MachiningList(nI).m_nNbrId
|
||||
Dim nArrId As Integer = m_MachiningList( nI).m_nArrId
|
||||
Dim nArrId As Integer = m_MachiningList(nI).m_nArrId
|
||||
If bMark Then
|
||||
EgtSetMark( nNbrId)
|
||||
EgtSetMark( nArrId)
|
||||
EgtSetMark(nNbrId)
|
||||
EgtSetMark(nArrId)
|
||||
Else
|
||||
EgtResetMark( nNbrId)
|
||||
EgtResetMark( nArrId)
|
||||
EgtResetMark(nNbrId)
|
||||
EgtResetMark(nArrId)
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub ColorNumberArrow( nI As Integer)
|
||||
Private Sub ColorNumberArrow(nI As Integer)
|
||||
If nI < 0 Then Return
|
||||
Dim nNbrId As Integer = m_MachiningList( nI).m_nNbrId
|
||||
Dim nArrId As Integer = m_MachiningList( nI).m_nArrId
|
||||
If m_MachiningList( nI).m_bEnabled Then
|
||||
If m_MachiningList( nI).m_nInterf = FMI_TYPE.NONE Then
|
||||
EgtSetColor( nNbrId, COL_MCH_FREE)
|
||||
EgtSetColor( nArrId, COL_MCH_FREE)
|
||||
Dim nNbrId As Integer = m_MachiningList(nI).m_nNbrId
|
||||
Dim nArrId As Integer = m_MachiningList(nI).m_nArrId
|
||||
If m_MachiningList(nI).m_bEnabled Then
|
||||
If m_MachiningList(nI).m_nInterf = FMI_TYPE.NONE Then
|
||||
EgtSetColor(nNbrId, COL_MCH_FREE)
|
||||
EgtSetColor(nArrId, COL_MCH_FREE)
|
||||
Else
|
||||
EgtSetColor( nNbrId, COL_MCH_INTERF)
|
||||
EgtSetColor( nArrId, COL_MCH_INTERF)
|
||||
EgtSetColor(nNbrId, COL_MCH_INTERF)
|
||||
EgtSetColor(nArrId, COL_MCH_INTERF)
|
||||
End If
|
||||
Else
|
||||
If m_MachiningList( nI).m_nInterf = FMI_TYPE.NONE Then
|
||||
EgtResetColor( nNbrId)
|
||||
EgtResetColor( nArrId)
|
||||
ElseIf Not m_MachiningList( nI).m_bEnabled Then
|
||||
EgtSetColor( nNbrId, COL_MCH_DIS_INTERF)
|
||||
EgtSetColor( nArrId, COL_MCH_DIS_INTERF)
|
||||
If m_MachiningList(nI).m_nInterf = FMI_TYPE.NONE Then
|
||||
EgtResetColor(nNbrId)
|
||||
EgtResetColor(nArrId)
|
||||
ElseIf Not m_MachiningList(nI).m_bEnabled Then
|
||||
EgtSetColor(nNbrId, COL_MCH_DIS_INTERF)
|
||||
EgtSetColor(nArrId, COL_MCH_DIS_INTERF)
|
||||
End If
|
||||
End If
|
||||
End Sub
|
||||
@@ -2394,38 +2446,38 @@ Public Class SplitPageUC
|
||||
EgtEnableModified()
|
||||
End Sub
|
||||
|
||||
Private Sub SwapStartEndData( nI As Integer)
|
||||
Private Sub SwapStartEndData(nI As Integer)
|
||||
' Swap angoli precedente e successivo
|
||||
Dim dAng As Double = m_MachiningList( nI).m_dPrevAng
|
||||
m_MachiningList( nI).m_dPrevAng = m_MachiningList( nI).m_dNextAng
|
||||
m_MachiningList( nI).m_dNextAng = dAng
|
||||
Dim dAng As Double = m_MachiningList(nI).m_dPrevAng
|
||||
m_MachiningList(nI).m_dPrevAng = m_MachiningList(nI).m_dNextAng
|
||||
m_MachiningList(nI).m_dNextAng = dAng
|
||||
' Swap lunghezze libere
|
||||
Dim dFreeLen As Double = m_MachiningList( nI).m_dStartFreeLen
|
||||
m_MachiningList( nI).m_dStartFreeLen = m_MachiningList( nI).m_dEndFreeLen
|
||||
m_MachiningList( nI).m_dEndFreeLen = dFreeLen
|
||||
Dim dFreeLen As Double = m_MachiningList(nI).m_dStartFreeLen
|
||||
m_MachiningList(nI).m_dStartFreeLen = m_MachiningList(nI).m_dEndFreeLen
|
||||
m_MachiningList(nI).m_dEndFreeLen = dFreeLen
|
||||
' Swap stato di allungamento
|
||||
Dim bAll As Boolean = m_MachiningList( nI).m_bStartAll
|
||||
m_MachiningList( nI).m_bStartAll = m_MachiningList( nI).m_bEndAll
|
||||
m_MachiningList( nI).m_bEndAll = bAll
|
||||
Dim bAll As Boolean = m_MachiningList(nI).m_bStartAll
|
||||
m_MachiningList(nI).m_bStartAll = m_MachiningList(nI).m_bEndAll
|
||||
m_MachiningList(nI).m_bEndAll = bAll
|
||||
' Swap possibilità di allungamento
|
||||
Dim bCanAll As Boolean = m_MachiningList( nI).m_bCanStartAll
|
||||
m_MachiningList( nI).m_bCanStartAll = m_MachiningList( nI).m_bCanEndAll
|
||||
m_MachiningList( nI).m_bCanEndAll = bCanAll
|
||||
Dim bCanAll As Boolean = m_MachiningList(nI).m_bCanStartAll
|
||||
m_MachiningList(nI).m_bCanStartAll = m_MachiningList(nI).m_bCanEndAll
|
||||
m_MachiningList(nI).m_bCanEndAll = bCanAll
|
||||
' Swap stato interferenza
|
||||
if ( m_MachiningList( nI).m_nInterf And FMI_TYPE.LI) <> 0 And ( m_MachiningList( nI).m_nInterf And FMI_TYPE.LO) = 0 Then
|
||||
m_MachiningList( nI).m_nInterf -= FMI_TYPE.LI
|
||||
m_MachiningList( nI).m_nInterf += FMI_TYPE.LO
|
||||
ElseIf ( m_MachiningList( nI).m_nInterf And FMI_TYPE.LI) = 0 And ( m_MachiningList( nI).m_nInterf And FMI_TYPE.LO) <> 0 Then
|
||||
m_MachiningList( nI).m_nInterf += FMI_TYPE.LI
|
||||
m_MachiningList( nI).m_nInterf -= FMI_TYPE.LO
|
||||
If (m_MachiningList(nI).m_nInterf And FMI_TYPE.LI) <> 0 And (m_MachiningList(nI).m_nInterf And FMI_TYPE.LO) = 0 Then
|
||||
m_MachiningList(nI).m_nInterf -= FMI_TYPE.LI
|
||||
m_MachiningList(nI).m_nInterf += FMI_TYPE.LO
|
||||
ElseIf (m_MachiningList(nI).m_nInterf And FMI_TYPE.LI) = 0 And (m_MachiningList(nI).m_nInterf And FMI_TYPE.LO) <> 0 Then
|
||||
m_MachiningList(nI).m_nInterf += FMI_TYPE.LI
|
||||
m_MachiningList(nI).m_nInterf -= FMI_TYPE.LO
|
||||
End If
|
||||
' Swap Allungamento Utente
|
||||
Dim dOrigUsal As Double = 0
|
||||
EgtGetInfo( m_MachiningList( nI).m_nId, INFO_MCH_USER_SAL, dOrigUsal)
|
||||
EgtGetInfo(m_MachiningList(nI).m_nId, INFO_MCH_USER_SAL, dOrigUsal)
|
||||
Dim dOrigUeal As Double = 0
|
||||
EgtGetInfo( m_MachiningList( nI).m_nId, INFO_MCH_USER_EAL, dOrigUeal)
|
||||
EgtSetInfo( m_MachiningList( nI).m_nId, INFO_MCH_USER_SAL, dOrigUeal)
|
||||
EgtSetInfo( m_MachiningList( nI).m_nId, INFO_MCH_USER_EAL, dOrigUsal)
|
||||
EgtGetInfo(m_MachiningList(nI).m_nId, INFO_MCH_USER_EAL, dOrigUeal)
|
||||
EgtSetInfo(m_MachiningList(nI).m_nId, INFO_MCH_USER_SAL, dOrigUeal)
|
||||
EgtSetInfo(m_MachiningList(nI).m_nId, INFO_MCH_USER_EAL, dOrigUsal)
|
||||
End Sub
|
||||
|
||||
'-----------------------------------------------------------------------------------------------
|
||||
@@ -2455,10 +2507,10 @@ Public Class SplitPageUC
|
||||
Return m_sName
|
||||
End Get
|
||||
Set(value As String)
|
||||
If value <> m_sName Then
|
||||
m_sName = value
|
||||
NotifyPropertyChanged("Name")
|
||||
End If
|
||||
If value <> m_sName Then
|
||||
m_sName = value
|
||||
NotifyPropertyChanged("Name")
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
|
||||
@@ -2467,10 +2519,10 @@ Public Class SplitPageUC
|
||||
Return m_bIsActive
|
||||
End Get
|
||||
Set(value As Boolean)
|
||||
If value <> m_bIsActive Then
|
||||
m_bIsActive = value
|
||||
NotifyPropertyChanged("bIsActive")
|
||||
End If
|
||||
If value <> m_bIsActive Then
|
||||
m_bIsActive = value
|
||||
NotifyPropertyChanged("bIsActive")
|
||||
End If
|
||||
End Set
|
||||
End Property
|
||||
|
||||
|
||||
+17
-6
@@ -546,16 +546,27 @@ Module VacuumCups
|
||||
Return True
|
||||
End Function
|
||||
|
||||
' assegante le posizioni del centro delle ventose e l'angolo di posizionamento orizzontale verifica che la posizione sia raggiungibile
|
||||
' assegnate le posizioni del centro delle ventose e l'angolo di posizionamento orizzontale verifica che la posizione sia raggiungibile
|
||||
Public Function VerifyOutOfStrokes(ptRef As Point3d, dRotAngDeg As Double) As Integer
|
||||
Dim dX, dY, dZ As Double
|
||||
Dim nStat As Integer
|
||||
' Posizione Home dell'asse rotante
|
||||
Dim dCHome As Double
|
||||
EgtGetAxisHomePos("C", dCHome)
|
||||
' imposto la l'uscita della ventosa come fosse l'uscita di un utensile
|
||||
' Corse dell'asse
|
||||
Dim dCMin As Double
|
||||
EgtGetAxisMin("C", dCMin)
|
||||
Dim dCMax As Double
|
||||
EgtGetAxisMax("C", dCMax)
|
||||
' Porto l'angolo nel range
|
||||
Dim dRotAngMachDeg As Double = dRotAngDeg + dCHome
|
||||
AdjustAngleInRange(dRotAngMachDeg, dCMin, dCMax)
|
||||
' Imposto la ventosa come fosse un utensile
|
||||
EgtSetCalcTool("", "H4", 1)
|
||||
EgtGetCalcPositions(ptRef, dRotAngDeg + dCHome, 0, nStat, dX, dY, dZ)
|
||||
EgtVerifyOutstroke(dX, dY, dZ, dRotAngDeg + dCHome, 0, nStat)
|
||||
' Calcolo gli assi macchina
|
||||
Dim dX, dY, dZ As Double
|
||||
Dim nStat As Integer
|
||||
EgtGetCalcPositions(ptRef, dRotAngMachDeg, 0, nStat, dX, dY, dZ)
|
||||
' Verifico le corse
|
||||
EgtVerifyOutstroke(dX, dY, dZ, dRotAngMachDeg, 0, nStat)
|
||||
Return nStat
|
||||
End Function
|
||||
|
||||
|
||||
@@ -583,7 +583,7 @@ Public Class SingleCutUC
|
||||
Dim sSawing As String = m_MainWindow.m_CurrentMachine.sCurrSawing
|
||||
EgtTdbSetCurrTool(sSaw)
|
||||
Dim dThick As Double = 0
|
||||
' se è impostata una lavorazione di lama
|
||||
' Se è impostata una lavorazione di lama
|
||||
If Not String.IsNullOrEmpty(sSawing) Then
|
||||
EgtTdbGetCurrToolParam(MCH_TP.THICK, dThick)
|
||||
End If
|
||||
@@ -599,9 +599,12 @@ Public Class SingleCutUC
|
||||
Dim ptStart As Point3d = m_ptTipP1
|
||||
ptStart.z = 0
|
||||
Dim nCutId = EgtCreateLinePDL(nLayerId, ptStart, m_dAngO, m_dLen)
|
||||
If Math.Abs(m_dOffset) > 10 * EPS_SMALL Then
|
||||
Dim dTotOffset = m_dOffset
|
||||
If m_bSawTh Then dTotOffset += If( m_dOffset > 0, dThick, -dThick)
|
||||
' Applico la correzione di spessore lama -> anche se Offset=0! ver_2.5b1
|
||||
Dim dTotOffset = m_dOffset
|
||||
If m_bSawTh Then
|
||||
dTotOffset += If(m_dOffset > 0, dThick, -dThick)
|
||||
EgtOffsetCurve(nCutId, dTotOffset, OFF_TYPE.EXTEND)
|
||||
Else
|
||||
EgtOffsetCurve(nCutId, dTotOffset, OFF_TYPE.EXTEND)
|
||||
End If
|
||||
' Imposto affondamento e angolo di fianco sul taglio
|
||||
|
||||
+17
-2
@@ -38,6 +38,8 @@ Class MainWindow
|
||||
Friend m_MachinePageUC As MachinePageUC
|
||||
Friend m_OptionsPageUC As OptionsPageUC
|
||||
|
||||
Friend m_IsClosingApplication As Integer = 0
|
||||
|
||||
' Dichiarazione variabili direttori
|
||||
Private m_sExeRoot As String = String.Empty
|
||||
Private m_sDataRoot As String = String.Empty
|
||||
@@ -326,8 +328,8 @@ Class MainWindow
|
||||
' Verifico abilitazione nesting automatico
|
||||
m_bAutoNest = Not String.IsNullOrWhiteSpace(sNestKey)
|
||||
' Recupero opzioni della chiave
|
||||
Dim bKey As Boolean = EgtGetKeyLevel(9423, 2501, 1, m_nKeyLevel) And
|
||||
EgtGetKeyOptions(9423, 2501, 1, m_nKeyOptions)
|
||||
Dim bKey As Boolean = EgtGetKeyLevel(9423, 2502, 1, m_nKeyLevel) And
|
||||
EgtGetKeyOptions(9423, 2502, 1, m_nKeyOptions)
|
||||
' Verifico abilitazione prodotto
|
||||
Dim bProd As Boolean = GetKeyOption(KEY_OPT.CUT_BASE)
|
||||
' Inizializzazione generale di EgtInterface
|
||||
@@ -1085,6 +1087,19 @@ Class MainWindow
|
||||
m_CurrentProjectPageUC.SaveNamedProject()
|
||||
m_CurrentProjectPageUC.SaveProject()
|
||||
End If
|
||||
' Inizio la chiusura del programma (verifico di aver terminato il processo DripFeed)
|
||||
EgtOutLog("Iniziato processo di chiusura programma")
|
||||
m_IsClosingApplication = 1
|
||||
Dim nCount As Integer = 0
|
||||
While m_IsClosingApplication <> 2
|
||||
If nCount > 5 Then
|
||||
Exit While
|
||||
End If
|
||||
' verifico che il processo DripFeed sia terminato
|
||||
EgtOutLog("Stato chiusura programma: " & m_IsClosingApplication.ToString)
|
||||
Thread.Sleep(100)
|
||||
nCount += 1
|
||||
End While
|
||||
' Uscita
|
||||
MainWindowExit()
|
||||
End Sub
|
||||
|
||||
@@ -62,5 +62,5 @@ Imports System.Windows
|
||||
' by using the '*' as shown below:
|
||||
' <Assembly: AssemblyVersion("1.0.*")>
|
||||
|
||||
<Assembly: AssemblyVersion("2.5.1.2")>
|
||||
<Assembly: AssemblyFileVersion("2.5.1.2")>
|
||||
<Assembly: AssemblyVersion("2.5.3.2")>
|
||||
<Assembly: AssemblyFileVersion("2.5.3.2")>
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
Imports System.Globalization
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports EgtUILib
|
||||
Imports OmagCUT.Num
|
||||
|
||||
Public Class CNCommunication
|
||||
|
||||
@@ -354,8 +355,8 @@ Public Class CNCommunication
|
||||
If Not String.IsNullOrEmpty(sVal) Then m_CN.SetCnDataVar(CN_generico.CnData.Remote, sVal)
|
||||
End If
|
||||
|
||||
' Inizializzo la comunicazione
|
||||
m_CN.Init()
|
||||
' Inizializzo la comunicazione
|
||||
m_CN.Init()
|
||||
|
||||
Catch ex As Exception
|
||||
' set status to statusbar
|
||||
@@ -496,6 +497,7 @@ Public Class CNCommunication
|
||||
If m_CN.read_active_mode() <> m_nCurrMode Then
|
||||
m_nCurrMode = m_CN.read_active_mode()
|
||||
m_MachineStatus.DisplayActiveMode(m_nCurrMode)
|
||||
m_CN.nMachineMode = m_nCurrMode
|
||||
End If
|
||||
Case 2
|
||||
If m_CN.nMachineMode <> m_nCurrMode Then
|
||||
@@ -619,12 +621,17 @@ Public Class CNCommunication
|
||||
End If
|
||||
|
||||
' Nuove bottoni (Power Macchina)
|
||||
If m_IsNewConsole AndAlso m_MainWindow.m_ActivePage = MainWindow.Pages.Machine Then
|
||||
m_MainWindow.m_MachinePageUC.m_MachineCNPageUC.PowerONChanged(m_CN.bPowerON)
|
||||
m_MainWindow.m_MachinePageUC.m_MachineCNPageUC.PowerOFFChanged(Not m_CN.bPowerON)
|
||||
If m_MainWindow.m_ActivePage = MainWindow.Pages.Machine Then
|
||||
If m_IsNewConsole Then
|
||||
m_MainWindow.m_MachinePageUC.m_MachineCNPageUC.PowerONChanged(m_CN.bPowerON)
|
||||
m_MainWindow.m_MachinePageUC.m_MachineCNPageUC.PowerOFFChanged(Not m_CN.bPowerON)
|
||||
m_MainWindow.m_MachinePageUC.m_MachineCNPageUC.CncModeChange(m_CN.nMachineMode)
|
||||
End If
|
||||
m_MainWindow.m_MachinePageUC.m_MachineCNPageUC.CncModeChange(m_CN.nMachineMode)
|
||||
End If
|
||||
|
||||
|
||||
|
||||
If m_MainWindow.m_ActivePage = MainWindow.Pages.WorkInProgress Then
|
||||
m_MainWindow.m_WorkInProgressPageUC.m_MachineButtons.SpindleStateChanged(m_CN.bSpindleState)
|
||||
m_MainWindow.m_WorkInProgressPageUC.m_MachineButtons.CoolantStateChanged(m_CN.bCoolantState OrElse m_CN.bInternalCoolantState OrElse m_CN.bExternCoolantState)
|
||||
@@ -907,28 +914,51 @@ Public Class CNCommunication
|
||||
End If
|
||||
' Se richiesta successiva attivazione, faccio reset
|
||||
If bActivate Then
|
||||
EgtOutLog("Call function: DGeneralFunctions_Reset")
|
||||
TimeSpanInit()
|
||||
m_CN.DGeneralFunctions_Reset()
|
||||
EgtOutLog(TimeSpanEnd())
|
||||
End If
|
||||
' Attesa opportuna
|
||||
System.Threading.Thread.Sleep(m_MainWindow.m_CurrentMachine.nResetSendDelay)
|
||||
If m_nNCType = 1 Then
|
||||
' Cancellazione eventuale file già presente con lo stesso nome (ignoro eventuale errore)
|
||||
EgtOutLog("Delete_NC_prog(sNumProg)")
|
||||
TimeSpanInit()
|
||||
m_CN.Delete_NC_prog(sNumProg)
|
||||
EgtOutLog(TimeSpanEnd())
|
||||
' Attesa opportuna
|
||||
System.Threading.Thread.Sleep(100)
|
||||
End If
|
||||
EgtOutLog("Download_NC_prog(sCncPath, sNumProg)")
|
||||
TimeSpanInit()
|
||||
bOk = bOk AndAlso (m_CN.Download_NC_prog(sCncPath, sNumProg) = 0)
|
||||
EgtOutLog("Nc Type : " & m_nNCType.ToString)
|
||||
EgtOutLog("IsDripFeed : " & DirectCast(m_CN, NumNCOld).bIsDripFeed)
|
||||
If m_nNCType = 1 AndAlso TypeOf m_CN Is NumNCOld AndAlso DirectCast(m_CN, NumNCOld).bIsDripFeed Then
|
||||
' eventauli cambi di stato sono trattati all'interno della funzione
|
||||
Return True
|
||||
End If
|
||||
EgtOutLog(TimeSpanEnd())
|
||||
|
||||
' Attesa opportuna
|
||||
System.Threading.Thread.Sleep(100)
|
||||
' Se richiesta attivazione
|
||||
If bActivate Then
|
||||
' Attivazione programma
|
||||
EgtOutLog("ActivateProgram(nNumProg)")
|
||||
TimeSpanInit()
|
||||
bOk = bOk AndAlso (m_CN.ActivateProgram(nNumProg) = 0)
|
||||
EgtOutLog(TimeSpanEnd())
|
||||
' Attesa opportuna
|
||||
System.Threading.Thread.Sleep(100)
|
||||
' Modalità automatica
|
||||
EgtOutLog("DGeneralFunctions_WriteCncMode(0)")
|
||||
TimeSpanInit()
|
||||
bOk = bOk AndAlso (m_CN.DGeneralFunctions_WriteCncMode(0) = 0)
|
||||
EgtOutLog(TimeSpanEnd())
|
||||
End If
|
||||
|
||||
' Messaggio con risultato
|
||||
If bOk Then
|
||||
m_CurrProjPage.SetInfoMessage(EgtMsg(90317)) 'Programma CN trasmesso con successo
|
||||
|
||||
+946
-786
File diff suppressed because it is too large
Load Diff
@@ -1319,6 +1319,9 @@
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\NewIcons\Parking.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Resource Include="Resources\NewIcons\Quality.png" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
|
||||
<PropertyGroup>
|
||||
<PostBuildEvent>IF "$(PlatformName)"=="x86" IF "$(ConfigurationName)" == "Release" copy $(TargetPath) c:\EgtProg\OmagCUT\OmagCUTR32.exe
|
||||
|
||||
@@ -221,6 +221,7 @@
|
||||
<BitmapImage x:Key="Inizio-Allunga-AccorciaImg" UriSource="Resources/NewIcons/Inizio-allunga-o-accorcia.png"></BitmapImage>
|
||||
<BitmapImage x:Key="PonticelliWJImg" UriSource="Resources/NewIcons/Ponticelli.png"></BitmapImage>
|
||||
<BitmapImage x:Key="PonticelliDeleteWJImg" UriSource="Resources/NewIcons/Ponticelli_delete.png"></BitmapImage>
|
||||
<BitmapImage x:Key="QualityWJImg" UriSource="Resources/NewIcons/Quality.png"></BitmapImage>
|
||||
<BitmapImage x:Key="Fine-Allunga-AccorciaImg" UriSource="Resources/NewIcons/Fine-allunga-o-accorcia.png"></BitmapImage>
|
||||
<BitmapImage x:Key="ON_OFF-singolo-taglioImg" UriSource="Resources/NewIcons/ON_OFF-singolo-taglio.png"></BitmapImage>
|
||||
<BitmapImage x:Key="Tutti-ONImg" UriSource="Resources/NewIcons/Tutti-ON.png"></BitmapImage>
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
Imports System.IO
|
||||
Imports System.ComponentModel
|
||||
Imports System.Drawing
|
||||
Imports System.IO
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib
|
||||
|
||||
@@ -478,7 +480,6 @@ Public Class ProjectMgrUC
|
||||
If Not (m_CurrMachine.bProdLine Or m_CurrMachine.bDemo) Then
|
||||
' Download programma (eventuali errori sono segnalati dalla funzione)
|
||||
If m_CurrNcComm.SendProgram(sCncPath, 900) Then
|
||||
' copio il progetto corrente come progetto in lavorazione
|
||||
Dim sWrkPath As String = m_MainWindow.GetTempDir() & "\" & "WorkProj.nge"
|
||||
My.Computer.FileSystem.CopyFile(sMchPath, sWrkPath, True)
|
||||
' se abilitato e non è restart, lancio eventuale lua post-trasmissione
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 1.9 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 6.4 KiB After Width: | Height: | Size: 6.5 KiB |
+20
-2
@@ -1,4 +1,5 @@
|
||||
Imports System.Globalization
|
||||
Imports System.Diagnostics
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.Text.RegularExpressions
|
||||
Imports EgtWPFLib
|
||||
@@ -17,8 +18,25 @@ Module Utility
|
||||
End Function
|
||||
|
||||
|
||||
'--------------------------------------------------------------------------------------------------
|
||||
Friend Sub UpdateUI()
|
||||
Friend StopWatch As Stopwatch
|
||||
|
||||
Friend Sub TimeSpanInit()
|
||||
StopWatch = New Stopwatch
|
||||
StopWatch.Start()
|
||||
End Sub
|
||||
|
||||
Friend Function TimeSpanEnd()
|
||||
Dim sTime As String = ""
|
||||
If Not IsNothing(StopWatch) Then
|
||||
StopWatch.Stop()
|
||||
Dim ts As TimeSpan = StopWatch.Elapsed
|
||||
sTime = String.Format("{0:00}:{1:00}:{2:00}.{3:000}", ts.Hours, ts.Minutes, ts.Seconds, ts.Milliseconds)
|
||||
End If
|
||||
Return sTime
|
||||
End Function
|
||||
|
||||
'--------------------------------------------------------------------------------------------------
|
||||
Friend Sub UpdateUI()
|
||||
' Costringo ad aggiornare UI
|
||||
Dim nDummy As Integer
|
||||
Application.Current.Dispatcher.Invoke(Windows.Threading.DispatcherPriority.Background, _
|
||||
|
||||
Reference in New Issue
Block a user