Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 9a6f6ad37e | |||
| 8174c6137a | |||
| b84699e3c1 | |||
| 5101c1cca9 |
@@ -0,0 +1,61 @@
|
|||||||
|
<Window x:Class="ChooseTestToolWD"
|
||||||
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||||
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||||
|
xmlns:EgtWPFLib="clr-namespace:EgtWPFLib;assembly=EgtWPFLib"
|
||||||
|
FontFamily="{DynamicResource OmagCut_Font}"
|
||||||
|
Title="OpenFile" Height="382.6" Width="426.6" WindowStyle="None"
|
||||||
|
ResizeMode="NoResize" ShowInTaskbar="False" AllowsTransparency="True"
|
||||||
|
Background="Transparent">
|
||||||
|
|
||||||
|
<Border Style="{DynamicResource OmagCut_Border}">
|
||||||
|
<Grid>
|
||||||
|
<Grid.ColumnDefinitions>
|
||||||
|
<ColumnDefinition Width="0.5*"/>
|
||||||
|
<ColumnDefinition Width="4*"/>
|
||||||
|
<ColumnDefinition Width="0.5*"/>
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
<Grid.RowDefinitions>
|
||||||
|
<RowDefinition Height="0.5*"/>
|
||||||
|
<RowDefinition Height="0.5*"/>
|
||||||
|
<RowDefinition Height="1.5*"/>
|
||||||
|
<RowDefinition Height="0.5*"/>
|
||||||
|
<RowDefinition Height="1*"/>
|
||||||
|
<RowDefinition Height="0.5*"/>
|
||||||
|
</Grid.RowDefinitions>
|
||||||
|
|
||||||
|
<TextBlock Name="FilePathTxBl" Grid.Column="1" Grid.Row="1" Style="{DynamicResource OmagCut_CenteredLowerCaseCharacterTextBlock}" />
|
||||||
|
<!--TextAlignment="Center"
|
||||||
|
FontSize="20"
|
||||||
|
VerticalAlignment="Center"-->
|
||||||
|
<ListBox Name="SetUpToolListBox" Grid.Column="1" Grid.Row="2"
|
||||||
|
ItemsSource="{Binding ItemList}">
|
||||||
|
<ListBox.ItemTemplate>
|
||||||
|
<DataTemplate>
|
||||||
|
<TextBlock Text="{Binding ToolAlias}" Style="{StaticResource OmagCut_ListBoxTextBlock}" />
|
||||||
|
</DataTemplate>
|
||||||
|
</ListBox.ItemTemplate>
|
||||||
|
</ListBox>
|
||||||
|
|
||||||
|
<Grid Grid.Column="1" Grid.Row="4">
|
||||||
|
<Grid.ColumnDefinitions>
|
||||||
|
<ColumnDefinition Width="0.5*"/>
|
||||||
|
<ColumnDefinition Width="1*"/>
|
||||||
|
<ColumnDefinition Width="1*"/>
|
||||||
|
<ColumnDefinition Width="1*"/>
|
||||||
|
<ColumnDefinition Width="0.5*"/>
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
|
||||||
|
<Button Name="OkBtn" Grid.Column="1" Style="{DynamicResource OmagCut_GradientBlueIconButton}" >
|
||||||
|
<Image Source="{DynamicResource VImg}" Style="{StaticResource OmagCut_ButtonIcon}"/>
|
||||||
|
</Button>
|
||||||
|
<Button Name="ExitBtn" Grid.Column="3" Style="{DynamicResource OmagCut_GradientBlueIconButton}" IsCancel="True">
|
||||||
|
<Image Source="{DynamicResource XImg}" Style="{StaticResource OmagCut_ButtonIcon}"/>
|
||||||
|
</Button>
|
||||||
|
|
||||||
|
</Grid>
|
||||||
|
|
||||||
|
</Grid>
|
||||||
|
|
||||||
|
</Border>
|
||||||
|
|
||||||
|
</Window>
|
||||||
@@ -0,0 +1,281 @@
|
|||||||
|
Imports System.Collections.ObjectModel
|
||||||
|
Imports System.IO
|
||||||
|
Imports EgtUILib
|
||||||
|
|
||||||
|
Public Class ChooseTestToolWD
|
||||||
|
|
||||||
|
Private m_MainWindow As MainWindow = DirectCast(Application.Current.MainWindow, MainWindow)
|
||||||
|
|
||||||
|
Private m_SetUpToolList As New ObservableCollection(Of TestTool)
|
||||||
|
|
||||||
|
Sub New(Owner As Window)
|
||||||
|
Me.Owner = Owner
|
||||||
|
InitializeComponent()
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub OpenFile_Initialized(sender As Object, e As EventArgs) Handles Me.Initialized
|
||||||
|
' Posizione finestra
|
||||||
|
Me.Top = Owner.Top + Owner.Height / 2 - Me.Height / 2
|
||||||
|
Me.Left = Owner.Left + Owner.Width / 2 - Me.Width / 2
|
||||||
|
' Definizione del collegamento tra ItemList e ListBox1
|
||||||
|
SetUpToolListBox.ItemsSource = m_SetUpToolList
|
||||||
|
FilePathTxBl.Text = EgtMsg(MSG_ALARMSPAGEUC + 45) ' Selezionare l'utensile da tastare
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub OpenFile_Loaded(sender As Object, e As EventArgs) Handles Me.Loaded
|
||||||
|
' carico elenco degli utensili impostati attualmente in macchina (anche il laser!)
|
||||||
|
LoadSetUpTool()
|
||||||
|
' ricerco l'utensile della lavorazione indicata
|
||||||
|
Dim Item As TestTool = m_SetUpToolList.FirstOrDefault(Function(x) x.ToolName = m_MainWindow.m_CadCutPageUC.m_NestPage.m_CurrToolFromSelectedSawCurv)
|
||||||
|
Dim Index As Integer = m_SetUpToolList.IndexOf(Item)
|
||||||
|
If Index < 0 Then
|
||||||
|
Index = 0
|
||||||
|
End If
|
||||||
|
' se presente seleziono il primo elemento
|
||||||
|
If m_SetUpToolList.Count > 0 Then
|
||||||
|
SetUpToolListBox.SelectedItem = m_SetUpToolList(Index)
|
||||||
|
OkBtn.IsEnabled = True
|
||||||
|
Else
|
||||||
|
OkBtn.IsEnabled = False
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Function LoadSetUpTool() As Boolean
|
||||||
|
Dim sNameTool As String = String.Empty
|
||||||
|
Dim sHeadTool As String = String.Empty
|
||||||
|
Dim nExitTool As Integer = 0
|
||||||
|
|
||||||
|
'sNameTool = m_MainWindow.m_CurrentMachine.sCurrSaw
|
||||||
|
'If Not String.IsNullOrEmpty(sNameTool) Then
|
||||||
|
' ' Imposto la lama
|
||||||
|
' m_SetUpToolList.Add(New TestTool(sNameTool, sNameTool, True))
|
||||||
|
'End If
|
||||||
|
'sNameTool = m_MainWindow.m_CurrentMachine.sCurrMill
|
||||||
|
'If Not String.IsNullOrEmpty(sNameTool) Then
|
||||||
|
' ' Imposto la fresa
|
||||||
|
' m_SetUpToolList.Add(New TestTool(sNameTool, sNameTool, False))
|
||||||
|
'End If
|
||||||
|
'sNameTool = m_MainWindow.m_CurrentMachine.sCurrDrill
|
||||||
|
'If Not String.IsNullOrEmpty(sNameTool) Then
|
||||||
|
' ' Imposto il foretto
|
||||||
|
' m_SetUpToolList.Add(New TestTool(sNameTool, sNameTool, False))
|
||||||
|
'End If
|
||||||
|
|
||||||
|
sNameTool = "Laser point"
|
||||||
|
If Not String.IsNullOrEmpty(sNameTool) Then
|
||||||
|
' Imposto laser di puntamento
|
||||||
|
m_SetUpToolList.Add(New TestTool(sNameTool, ""))
|
||||||
|
End If
|
||||||
|
|
||||||
|
sNameTool = m_MainWindow.m_CurrentMachine.sCurrWaterJet
|
||||||
|
If Not String.IsNullOrEmpty(sNameTool) Then
|
||||||
|
' Imposto WJ
|
||||||
|
m_SetUpToolList.Add(New TestTool(sNameTool, sNameTool))
|
||||||
|
End If
|
||||||
|
|
||||||
|
Select Case m_MainWindow.m_CurrentMachine.MountedToolConfig
|
||||||
|
Case CurrentMachine.MountedToolConfigs.SAWANDAUXTOOL
|
||||||
|
sNameTool = m_MainWindow.m_CurrentMachine.sCurrSaw
|
||||||
|
If Not String.IsNullOrEmpty(sNameTool) Then
|
||||||
|
' Imposto la lama
|
||||||
|
m_SetUpToolList.Add(New TestTool(sNameTool, sNameTool))
|
||||||
|
End If
|
||||||
|
sNameTool = m_MainWindow.m_CurrentMachine.sCurrMill
|
||||||
|
If Not String.IsNullOrEmpty(sNameTool) Then
|
||||||
|
' Imposto la fresa
|
||||||
|
m_SetUpToolList.Add(New TestTool(sNameTool, sNameTool))
|
||||||
|
End If
|
||||||
|
sNameTool = m_MainWindow.m_CurrentMachine.sCurrDrill
|
||||||
|
If Not String.IsNullOrEmpty(sNameTool) Then
|
||||||
|
' Imposto il foretto
|
||||||
|
m_SetUpToolList.Add(New TestTool(sNameTool, sNameTool))
|
||||||
|
End If
|
||||||
|
|
||||||
|
Case CurrentMachine.MountedToolConfigs.MANUALTOOLCHANGER
|
||||||
|
sNameTool = m_MainWindow.m_CurrentMachine.sCurrSaw
|
||||||
|
If Not String.IsNullOrEmpty(sNameTool) Then
|
||||||
|
' Imposto la lama
|
||||||
|
m_SetUpToolList.Add(New TestTool(sNameTool, sNameTool))
|
||||||
|
End If
|
||||||
|
' Recupero tutti gli utensili attrezzati (nel ToolChanger e nel ManualToolChanger)
|
||||||
|
For Each ToolChangerPos As ToolChangerPos In m_MainWindow.m_CurrentMachine.ManualToolChanger
|
||||||
|
'm_SetUpToolList.Add(New ToolPos(ToolChangerPos.sTool, ToolChangerPos.sName, False))
|
||||||
|
sNameTool = ToolChangerPos.sTool
|
||||||
|
If Not String.IsNullOrEmpty(sNameTool) Then
|
||||||
|
' Imposto la lama
|
||||||
|
m_SetUpToolList.Add(New TestTool(sNameTool, sNameTool))
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
Return True
|
||||||
|
|
||||||
|
Case CurrentMachine.MountedToolConfigs.TOOLCHANGER
|
||||||
|
' Recupero tutti gli utensili attrezzati (nel ToolChanger e nel ManualToolChanger)
|
||||||
|
sNameTool = m_MainWindow.m_CurrentMachine.sCurrSaw
|
||||||
|
If Not String.IsNullOrEmpty(sNameTool) Then
|
||||||
|
' Imposto la lama
|
||||||
|
m_SetUpToolList.Add(New TestTool(sNameTool, sNameTool))
|
||||||
|
End If
|
||||||
|
For Each ToolChangerPos As ToolChangerPos In m_MainWindow.m_CurrentMachine.ToolChanger
|
||||||
|
If Not String.IsNullOrWhiteSpace(ToolChangerPos.sTool) Then
|
||||||
|
'm_SetUpToolList.Add(New ToolPos(ToolChangerPos.sTool, ToolChangerPos.sName, False))
|
||||||
|
sNameTool = ToolChangerPos.sTool
|
||||||
|
If Not String.IsNullOrEmpty(sNameTool) Then
|
||||||
|
' Imposto la lama
|
||||||
|
m_SetUpToolList.Add(New TestTool(sNameTool, sNameTool))
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
For Each ToolChangerPos As ToolChangerPos In m_MainWindow.m_CurrentMachine.ManualToolChanger
|
||||||
|
If Not String.IsNullOrWhiteSpace(ToolChangerPos.sTool) Then
|
||||||
|
'm_SetUpToolList.Add(New ToolPos(ToolChangerPos.sTool, ToolChangerPos.sName, False))
|
||||||
|
sNameTool = ToolChangerPos.sTool
|
||||||
|
If Not String.IsNullOrEmpty(sNameTool) Then
|
||||||
|
' Imposto la lama
|
||||||
|
m_SetUpToolList.Add(New TestTool(sNameTool, sNameTool))
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
Return True
|
||||||
|
Case Else
|
||||||
|
Return False
|
||||||
|
End Select
|
||||||
|
|
||||||
|
|
||||||
|
Return True
|
||||||
|
End Function
|
||||||
|
|
||||||
|
Private Sub SetUpToolListBox_PreviewMouseUp(sender As Object, e As MouseButtonEventArgs) Handles SetUpToolListBox.PreviewMouseUp
|
||||||
|
' Disabilito Ok
|
||||||
|
OkBtn.IsEnabled = False
|
||||||
|
' Recupero item selezionato
|
||||||
|
If SetUpToolListBox.SelectedItems.Count() = 0 Then
|
||||||
|
Return
|
||||||
|
End If
|
||||||
|
' A seconda del tipo
|
||||||
|
OkBtn.IsEnabled = True
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub SetUpToolListBox_SelectionChanged(sender As Object, e As SelectionChangedEventArgs) Handles SetUpToolListBox.SelectionChanged
|
||||||
|
' Disabilito Ok
|
||||||
|
OkBtn.IsEnabled = False
|
||||||
|
' Recupero item selezionato
|
||||||
|
If SetUpToolListBox.SelectedItems.Count() = 0 Then
|
||||||
|
Return
|
||||||
|
Else
|
||||||
|
OkBtn.IsEnabled = True
|
||||||
|
End If
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Sub OkBtn_Click(sender As Object, e As RoutedEventArgs) Handles OkBtn.Click
|
||||||
|
DialogResult = True
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
' restituisce l'oggetto selezionato in elenco e lo imposta come attivo
|
||||||
|
Friend Function GetSelectedTool() As TestTool
|
||||||
|
Dim SelTestTool As TestTool = DirectCast(SetUpToolListBox.SelectedItem, TestTool)
|
||||||
|
If SelTestTool.ToolAlias = "Laser point" Then
|
||||||
|
SelTestTool.ToolHead = "H3"
|
||||||
|
SelTestTool.ToolExit = 1
|
||||||
|
SelTestTool.ToolIsSaw = False
|
||||||
|
SelTestTool.ToolIsLaser = True
|
||||||
|
Else
|
||||||
|
EgtTdbSetCurrTool(SelTestTool.ToolName)
|
||||||
|
Dim sHeadTool As String = String.Empty
|
||||||
|
Dim nExitTool As Integer = 0
|
||||||
|
Dim sTypeTool As String = String.Empty
|
||||||
|
Dim nTypeTool As Integer
|
||||||
|
EgtTdbGetCurrToolParam(MCH_TP.TYPE, nTypeTool)
|
||||||
|
EgtTdbGetCurrToolParam(MCH_TP.HEAD, sHeadTool)
|
||||||
|
EgtTdbGetCurrToolParam(MCH_TP.EXIT_, nExitTool)
|
||||||
|
EgtTdbGetCurrToolParam(MCH_TP.TYPE, sTypeTool)
|
||||||
|
SelTestTool.ToolHead = sHeadTool
|
||||||
|
SelTestTool.ToolExit = nExitTool
|
||||||
|
SelTestTool.ToolType = nTypeTool
|
||||||
|
SelTestTool.ToolIsSaw = (nTypeTool = MCH_TY.SAW_STD)
|
||||||
|
SelTestTool.ToolIsLaser = False
|
||||||
|
End If
|
||||||
|
|
||||||
|
Return SelTestTool
|
||||||
|
End Function
|
||||||
|
|
||||||
|
End Class
|
||||||
|
|
||||||
|
Public Class TestTool
|
||||||
|
|
||||||
|
Private m_ToolAlias As String = String.Empty
|
||||||
|
Private m_ToolName As String = String.Empty
|
||||||
|
Private m_ToolHead As String = "H1"
|
||||||
|
Private m_ToolExit As Integer = 1
|
||||||
|
Private m_ToolIsSaw As Boolean = False
|
||||||
|
Private m_ToolIsLaser As Boolean = False
|
||||||
|
Private m_ToolType As Integer = -1
|
||||||
|
|
||||||
|
Public Property ToolAlias As String
|
||||||
|
Get
|
||||||
|
Return m_ToolAlias
|
||||||
|
End Get
|
||||||
|
Set(value As String)
|
||||||
|
m_ToolAlias = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Public Property ToolName As String
|
||||||
|
Get
|
||||||
|
Return m_ToolName
|
||||||
|
End Get
|
||||||
|
Set(value As String)
|
||||||
|
m_ToolName = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Public Property ToolHead As String
|
||||||
|
Get
|
||||||
|
Return m_ToolHead
|
||||||
|
End Get
|
||||||
|
Set(value As String)
|
||||||
|
m_ToolHead = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Public Property ToolExit As Integer
|
||||||
|
Get
|
||||||
|
Return m_ToolExit
|
||||||
|
End Get
|
||||||
|
Set(value As Integer)
|
||||||
|
m_ToolExit = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Public Property ToolType As Integer
|
||||||
|
Get
|
||||||
|
Return m_ToolType
|
||||||
|
End Get
|
||||||
|
Set(value As Integer)
|
||||||
|
m_ToolType = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Public Property ToolIsSaw As Boolean
|
||||||
|
Get
|
||||||
|
Return m_ToolIsSaw
|
||||||
|
End Get
|
||||||
|
Set(value As Boolean)
|
||||||
|
m_ToolIsSaw = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Public Property ToolIsLaser As Boolean
|
||||||
|
Get
|
||||||
|
Return m_ToolIsLaser
|
||||||
|
End Get
|
||||||
|
Set(value As Boolean)
|
||||||
|
m_ToolIsLaser = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
|
Sub New(sToolAlias As String, sToolName As String)
|
||||||
|
m_ToolAlias = sToolAlias
|
||||||
|
m_ToolName = sToolName
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
End Class
|
||||||
+45
-10
@@ -30,6 +30,7 @@ Public Class NestPageUC
|
|||||||
' Id della curva e del taglio selezionati per eseguire il test
|
' 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
|
||||||
|
Friend m_CurrToolFromSelectedSawCurv As String = String.Empty
|
||||||
|
|
||||||
' Id del rettangolo, del taglio e della curva da modificare tramite Drag
|
' Id del rettangolo, del taglio e della curva da modificare tramite Drag
|
||||||
Private m_nIdSelectedOutLoopRettangle As Integer = GDB_ID.NULL
|
Private m_nIdSelectedOutLoopRettangle As Integer = GDB_ID.NULL
|
||||||
@@ -258,7 +259,9 @@ Public Class NestPageUC
|
|||||||
End If
|
End If
|
||||||
' Se esiste un elemento selezionato
|
' Se esiste un elemento selezionato
|
||||||
EgtResetMark(m_CurrSelectedSawCurv)
|
EgtResetMark(m_CurrSelectedSawCurv)
|
||||||
' provo a riconoscere il valore medio del segmento
|
m_CurrToolFromSelectedSawCurv = String.Empty
|
||||||
|
' ripulisco da eventuali messaggi
|
||||||
|
m_MainWindow.m_CurrentProjectPageUC.ClearMessage()
|
||||||
' Verifico se selezionato indicativo di pezzo
|
' Verifico se selezionato indicativo di pezzo
|
||||||
EgtSetObjFilterForSelWin(False, True, False, False, False)
|
EgtSetObjFilterForSelWin(False, True, False, False, False)
|
||||||
Dim nSelMy As Integer
|
Dim nSelMy As Integer
|
||||||
@@ -283,20 +286,52 @@ Public Class NestPageUC
|
|||||||
' recupero il gruppo della lavorazione associata
|
' recupero il gruppo della lavorazione associata
|
||||||
Dim nIdParentPart As Integer = EgtGetParent(nIdParent)
|
Dim nIdParentPart As Integer = EgtGetParent(nIdParent)
|
||||||
Dim nIdPV As Integer = EgtGetFirstNameInGroup(nIdParentPart, NAME_PREVIEW)
|
Dim nIdPV As Integer = EgtGetFirstNameInGroup(nIdParentPart, NAME_PREVIEW)
|
||||||
Dim nIdSaw As Integer = EgtGetFirstNameInGroup(nIdPV, "Saw" & nIdMy.ToString)
|
|
||||||
If Not EgtGetGroupObjs(nIdSaw) Then
|
Dim nIdMachining As Integer = EgtGetFirstInGroup(nIdPV)
|
||||||
m_CurrSelectedSawCurv = nIdSaw
|
While nIdMachining <> GDB_ID.NULL
|
||||||
m_CurrSelectedCurv = nIdMy
|
Dim sNameMachining As String = String.Empty
|
||||||
EgtSetMark(nIdSaw)
|
EgtGetName(nIdMachining, sNameMachining)
|
||||||
EgtSelectObj(nIdMy)
|
If sNameMachining.Contains(nIdMy.ToString) Then
|
||||||
EgtDraw()
|
Exit While
|
||||||
Exit While
|
End If
|
||||||
End If
|
nIdMachining = EgtGetNext(nIdMachining)
|
||||||
|
End While
|
||||||
|
|
||||||
|
' recupero la lavorazione associata nel gruppo Opers
|
||||||
|
Dim sIdRefMachining As Integer = -1
|
||||||
|
EgtGetInfo(nIdMachining, "MId", sIdRefMachining)
|
||||||
|
EgtSetCurrMachining(sIdRefMachining)
|
||||||
|
' recupero il nome dell'utensile associato alla lavorazione
|
||||||
|
Dim sToolCurrMachining As String = String.Empty
|
||||||
|
EgtGetMachiningParam(MCH_MP.TOOL, sToolCurrMachining)
|
||||||
|
' seleziono le entità nel disegno
|
||||||
|
m_CurrToolFromSelectedSawCurv = sToolCurrMachining
|
||||||
|
m_CurrSelectedSawCurv = nIdMachining
|
||||||
|
m_CurrSelectedCurv = nIdMy
|
||||||
|
EgtSetMark(nIdMachining)
|
||||||
|
EgtSelectObj(nIdMy)
|
||||||
|
EgtDraw()
|
||||||
|
|
||||||
|
'Dim nIdSaw As Integer = EgtGetFirstNameInGroup(nIdPV, "Saw" & nIdMy.ToString)
|
||||||
|
'If Not EgtGetGroupObjs(nIdSaw) Then
|
||||||
|
' m_CurrSelectedSawCurv = nIdSaw
|
||||||
|
' m_CurrSelectedCurv = nIdMy
|
||||||
|
' EgtSetMark(nIdSaw)
|
||||||
|
' EgtSelectObj(nIdMy)
|
||||||
|
' EgtDraw()
|
||||||
|
' Exit While
|
||||||
|
'End If
|
||||||
|
|
||||||
|
Exit While
|
||||||
|
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
nIdMy = EgtGetNextObjInSelWin()
|
nIdMy = EgtGetNextObjInSelWin()
|
||||||
End While
|
End While
|
||||||
|
If nIdMy = GDB_ID.NULL Then
|
||||||
|
m_MainWindow.m_CurrentProjectPageUC.ClearMessage()
|
||||||
|
m_MainWindow.m_CurrentProjectPageUC.SetErrorMessage("Select OUTLOOP")
|
||||||
|
End If
|
||||||
Return
|
Return
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|||||||
@@ -247,7 +247,7 @@
|
|||||||
Public Const K_MIN_RADIUSWJ As String = "MinRadiusWJ"
|
Public Const K_MIN_RADIUSWJ As String = "MinRadiusWJ"
|
||||||
Public Const K_MACH_DRILLINGWJ_ON_CORNERS As String = "DrillingWJOnCorners"
|
Public Const K_MACH_DRILLINGWJ_ON_CORNERS As String = "DrillingWJOnCorners"
|
||||||
Public Const K_MACH_RECTIFICATION_ON_SUBSQUARE As String = "RectificationSubSqWJ"
|
Public Const K_MACH_RECTIFICATION_ON_SUBSQUARE As String = "RectificationSubSqWJ"
|
||||||
' DrillMillC90
|
Public Const K_MACH_DRILL_MILL_C90 As String = "DrillMillC90"
|
||||||
' CutLongDxSx
|
' CutLongDxSx
|
||||||
' AngRotMultiCut
|
' AngRotMultiCut
|
||||||
' MinDistHeadsMultiCut
|
' MinDistHeadsMultiCut
|
||||||
|
|||||||
@@ -766,6 +766,10 @@ Public Class CurrentMachine
|
|||||||
Set(value As String)
|
Set(value As String)
|
||||||
If WritePrivateProfileString(S_MACH_MACH, K_CURRWATERJETTING, value, sMachIniFile) Then
|
If WritePrivateProfileString(S_MACH_MACH, K_CURRWATERJETTING, value, sMachIniFile) Then
|
||||||
m_sCurrWaterJetting = value
|
m_sCurrWaterJetting = value
|
||||||
|
If m_MainWindow.m_CurrentMachine.bWaterJet And EgtGetHeadId("H1") = GDB_ID.NULL Then
|
||||||
|
m_MainWindow.m_CurrentProjectPageUC.MachiningTxBx.Text = value
|
||||||
|
End If
|
||||||
|
|
||||||
End If
|
End If
|
||||||
End Set
|
End Set
|
||||||
End Property
|
End Property
|
||||||
|
|||||||
@@ -2103,6 +2103,7 @@ Class MainWindow
|
|||||||
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)
|
EgtResetMark(m_CadCutPageUC.m_NestPage.m_CurrSelectedSawCurv)
|
||||||
|
m_CadCutPageUC.m_NestPage.m_CurrToolFromSelectedSawCurv = String.Empty
|
||||||
m_CadCutPageUC.m_ProjectMgr.TestBtn.IsChecked = False
|
m_CadCutPageUC.m_ProjectMgr.TestBtn.IsChecked = False
|
||||||
Me.m_CadCutPageUC.m_NestPage.m_bSelectCurv = False
|
Me.m_CadCutPageUC.m_NestPage.m_bSelectCurv = False
|
||||||
End Sub
|
End Sub
|
||||||
|
|||||||
@@ -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.6.5.1")>
|
<Assembly: AssemblyVersion("2.6.5.2")>
|
||||||
<Assembly: AssemblyFileVersion("2.6.5.1")>
|
<Assembly: AssemblyFileVersion("2.6.5.2")>
|
||||||
|
|||||||
+10
-1
@@ -1683,7 +1683,16 @@ Module M_Fanuc
|
|||||||
sz_Err_Msg = ""
|
sz_Err_Msg = ""
|
||||||
If Not bSimulation Then
|
If Not bSimulation Then
|
||||||
|
|
||||||
sz_MDI_program = sz_MDI_command
|
' Nicola: 10/05/2024
|
||||||
|
|
||||||
|
Dim sItems As String() = sz_MDI_command.Split(";")
|
||||||
|
Dim sNew_MDI_program As String = ""
|
||||||
|
For Each sItem As String In sItems
|
||||||
|
sNew_MDI_program &= sItem & vbLf
|
||||||
|
Next
|
||||||
|
sNew_MDI_program &= "%"
|
||||||
|
|
||||||
|
sz_MDI_program = sNew_MDI_program
|
||||||
|
|
||||||
' Nicola: 29/03/2023
|
' Nicola: 29/03/2023
|
||||||
|
|
||||||
|
|||||||
@@ -174,6 +174,9 @@
|
|||||||
<Compile Include="AboutBox\AboutBoxWD.xaml.vb">
|
<Compile Include="AboutBox\AboutBoxWD.xaml.vb">
|
||||||
<DependentUpon>AboutBoxWD.xaml</DependentUpon>
|
<DependentUpon>AboutBoxWD.xaml</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
|
<Compile Include="CadCuts\ChooseTestToolWD.xaml.vb">
|
||||||
|
<DependentUpon>ChooseTestToolWD.xaml</DependentUpon>
|
||||||
|
</Compile>
|
||||||
<Compile Include="CadCuts\SelectPartFromFamilyWD.xaml.vb">
|
<Compile Include="CadCuts\SelectPartFromFamilyWD.xaml.vb">
|
||||||
<DependentUpon>SelectPartFromFamilyWD.xaml</DependentUpon>
|
<DependentUpon>SelectPartFromFamilyWD.xaml</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
@@ -444,6 +447,10 @@
|
|||||||
<Generator>MSBuild:Compile</Generator>
|
<Generator>MSBuild:Compile</Generator>
|
||||||
<SubType>Designer</SubType>
|
<SubType>Designer</SubType>
|
||||||
</Page>
|
</Page>
|
||||||
|
<Page Include="CadCuts\ChooseTestToolWD.xaml">
|
||||||
|
<SubType>Designer</SubType>
|
||||||
|
<Generator>MSBuild:Compile</Generator>
|
||||||
|
</Page>
|
||||||
<Page Include="CadCuts\SelectPartFromFamilyWD.xaml">
|
<Page Include="CadCuts\SelectPartFromFamilyWD.xaml">
|
||||||
<SubType>Designer</SubType>
|
<SubType>Designer</SubType>
|
||||||
<Generator>MSBuild:Compile</Generator>
|
<Generator>MSBuild:Compile</Generator>
|
||||||
@@ -1368,6 +1375,9 @@
|
|||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Resource Include="Resources\NewIcons\Move-Spot-Reg.png" />
|
<Resource Include="Resources\NewIcons\Move-Spot-Reg.png" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Resource Include="Resources\NewIcons\RawHeight.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
|
||||||
|
|||||||
@@ -63,6 +63,7 @@
|
|||||||
<BitmapImage x:Key="PhotoImg" UriSource="Resources/NewIcons/icone-tagli-1.png"></BitmapImage>
|
<BitmapImage x:Key="PhotoImg" UriSource="Resources/NewIcons/icone-tagli-1.png"></BitmapImage>
|
||||||
<BitmapImage x:Key="RawPartImg" UriSource="Resources/NewIcons/icone-tagli-5.png"></BitmapImage>
|
<BitmapImage x:Key="RawPartImg" UriSource="Resources/NewIcons/icone-tagli-5.png"></BitmapImage>
|
||||||
<BitmapImage x:Key="RawProbeImg" UriSource="Resources/NewIcons/RawProbe.png"></BitmapImage>
|
<BitmapImage x:Key="RawProbeImg" UriSource="Resources/NewIcons/RawProbe.png"></BitmapImage>
|
||||||
|
<BitmapImage x:Key="RawHeightImg" UriSource="Resources/NewIcons/RawHeight.png"></BitmapImage>
|
||||||
<BitmapImage x:Key="RightArrowImg" UriSource="Resources/NewIcons/RightArrow.png"></BitmapImage>
|
<BitmapImage x:Key="RightArrowImg" UriSource="Resources/NewIcons/RightArrow.png"></BitmapImage>
|
||||||
<BitmapImage x:Key="SawProbeImg" UriSource="Resources/NewIcons/SawProbe.png"></BitmapImage>
|
<BitmapImage x:Key="SawProbeImg" UriSource="Resources/NewIcons/SawProbe.png"></BitmapImage>
|
||||||
<BitmapImage x:Key="SendImg" UriSource="Resources/NewIcons/Send.png"></BitmapImage>
|
<BitmapImage x:Key="SendImg" UriSource="Resources/NewIcons/Send.png"></BitmapImage>
|
||||||
@@ -237,7 +238,10 @@
|
|||||||
<Setter Property="Foreground" Value="White"/>
|
<Setter Property="Foreground" Value="White"/>
|
||||||
<Setter Property="IsReadOnly" Value="True"/>
|
<Setter Property="IsReadOnly" Value="True"/>
|
||||||
<Setter Property="IsEnabled" Value="False"/>
|
<Setter Property="IsEnabled" Value="False"/>
|
||||||
|
<Setter Property="TextAlignment" Value="Center"/>
|
||||||
<Setter Property="Template" Value="{StaticResource FixedTextBoxTemplate}" />
|
<Setter Property="Template" Value="{StaticResource FixedTextBoxTemplate}" />
|
||||||
|
<Setter Property="ToolTipService.ShowOnDisabled" Value="True"/>
|
||||||
|
<Setter Property="ToolTip" Value="{Binding RelativeSource={RelativeSource Self}, Path=Text}"/>
|
||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
<Style x:Key="OmagCut_Button" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
|
<Style x:Key="OmagCut_Button" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
|
||||||
|
|||||||
+14
-4
@@ -133,6 +133,7 @@
|
|||||||
<BitmapImage x:Key="PhotoImg" UriSource="Resources/Photo.png"></BitmapImage>
|
<BitmapImage x:Key="PhotoImg" UriSource="Resources/Photo.png"></BitmapImage>
|
||||||
<BitmapImage x:Key="RawPartImg" UriSource="Resources/RawPart.png"></BitmapImage>
|
<BitmapImage x:Key="RawPartImg" UriSource="Resources/RawPart.png"></BitmapImage>
|
||||||
<BitmapImage x:Key="RawProbeImg" UriSource="Resources/RawProbe.png"></BitmapImage>
|
<BitmapImage x:Key="RawProbeImg" UriSource="Resources/RawProbe.png"></BitmapImage>
|
||||||
|
<BitmapImage x:Key="RawHeightImg" UriSource="Resources/NewIcons/RawHeight.png"></BitmapImage>
|
||||||
<BitmapImage x:Key="RightArrowImg" UriSource="Resources/RightArrow.png"></BitmapImage>
|
<BitmapImage x:Key="RightArrowImg" UriSource="Resources/RightArrow.png"></BitmapImage>
|
||||||
<BitmapImage x:Key="SawProbeImg" UriSource="Resources/SawProbe.png"></BitmapImage>
|
<BitmapImage x:Key="SawProbeImg" UriSource="Resources/SawProbe.png"></BitmapImage>
|
||||||
<BitmapImage x:Key="SendImg" UriSource="Resources/Send.png"></BitmapImage>
|
<BitmapImage x:Key="SendImg" UriSource="Resources/Send.png"></BitmapImage>
|
||||||
@@ -794,7 +795,13 @@
|
|||||||
<Setter Property="Margin" Value="0,8,6,4"/>
|
<Setter Property="Margin" Value="0,8,6,4"/>
|
||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
<!-- ______________________________________________________________________________________________________________________ -->
|
<!--Style di un immagine in al posto di una text-->
|
||||||
|
<Style x:Key="OmagCut_TextIcon" TargetType="{x:Type Image}" >
|
||||||
|
<Setter Property="Width" Value="30"/>
|
||||||
|
<Setter Property="Height" Value="30"/>
|
||||||
|
</Style>
|
||||||
|
|
||||||
|
<!-- ______________________________________________________________________________________________________________________ -->
|
||||||
|
|
||||||
<!-- ScrollBar & it's component (RepeatButton, Thumb) -->
|
<!-- ScrollBar & it's component (RepeatButton, Thumb) -->
|
||||||
|
|
||||||
@@ -1191,7 +1198,7 @@
|
|||||||
<Setter Property="HorizontalAlignment" Value="Center"/>
|
<Setter Property="HorizontalAlignment" Value="Center"/>
|
||||||
</Style>
|
</Style>
|
||||||
|
|
||||||
<!-- ______________________________________________________________________________________________________________________ -->
|
<!-- ______________________________________________________________________________________________________________________ -->
|
||||||
|
|
||||||
<!--TextBox-->
|
<!--TextBox-->
|
||||||
|
|
||||||
@@ -1266,11 +1273,14 @@
|
|||||||
|
|
||||||
<Style x:Key="OmagCut_FixedTextBox" TargetType="{x:Type EgtWPFLib:EgtTextBox}" BasedOn="{StaticResource OmagCut_TextBox}">
|
<Style x:Key="OmagCut_FixedTextBox" TargetType="{x:Type EgtWPFLib:EgtTextBox}" BasedOn="{StaticResource OmagCut_TextBox}">
|
||||||
<Setter Property="BorderBrush" Value="{StaticResource OmagCut_Gray}"/>
|
<Setter Property="BorderBrush" Value="{StaticResource OmagCut_Gray}"/>
|
||||||
<Setter Property="Background" Value="White"/>
|
<Setter Property="Background" Value="White"/>
|
||||||
<Setter Property="IsReadOnly" Value="True"/>
|
<Setter Property="IsReadOnly" Value="True"/>
|
||||||
<Setter Property="IsEnabled" Value="False"/>
|
<Setter Property="IsEnabled" Value="False"/>
|
||||||
|
<Setter Property="TextAlignment" Value="Center"/>
|
||||||
<Setter Property="Template" Value="{StaticResource FixedTextBoxTemplate}" />
|
<Setter Property="Template" Value="{StaticResource FixedTextBoxTemplate}" />
|
||||||
</Style>
|
<Setter Property="ToolTipService.ShowOnDisabled" Value="True"/>
|
||||||
|
<Setter Property="ToolTip" Value="{Binding RelativeSource={RelativeSource Self}, Path=Text}"/>
|
||||||
|
</Style>
|
||||||
|
|
||||||
<!-- ______________________________________________________________________________________________________________________ -->
|
<!-- ______________________________________________________________________________________________________________________ -->
|
||||||
|
|
||||||
|
|||||||
@@ -8,78 +8,79 @@
|
|||||||
d:DesignHeight="853.3" d:DesignWidth="1280"
|
d:DesignHeight="853.3" d:DesignWidth="1280"
|
||||||
Initialized="CurrentProjectPage_Initialized" Loaded="CurrentProjectPage_Loaded">
|
Initialized="CurrentProjectPage_Initialized" Loaded="CurrentProjectPage_Loaded">
|
||||||
|
|
||||||
<!-- Definizione della CurrentProjectPage -->
|
<!-- Definizione della CurrentProjectPage -->
|
||||||
<Grid Name="CurrentProjectPageGrid" >
|
<Grid Name="CurrentProjectPageGrid" >
|
||||||
<Grid.ColumnDefinitions>
|
<Grid.ColumnDefinitions>
|
||||||
<ColumnDefinition Width="3*"/>
|
<ColumnDefinition Width="3*"/>
|
||||||
<ColumnDefinition Width="12*"/>
|
<ColumnDefinition Width="12*"/>
|
||||||
</Grid.ColumnDefinitions>
|
</Grid.ColumnDefinitions>
|
||||||
<Grid.RowDefinitions>
|
<Grid.RowDefinitions>
|
||||||
<RowDefinition Height="1*"/>
|
|
||||||
<RowDefinition Height="8*"/>
|
|
||||||
<RowDefinition Height="1*"/>
|
|
||||||
</Grid.RowDefinitions>
|
|
||||||
|
|
||||||
<!-- Definizione della Grid superiore -->
|
|
||||||
<Grid Name="UpperButtonGrid" Grid.Column="1" Grid.Row="0" >
|
|
||||||
<Grid.ColumnDefinitions>
|
|
||||||
<ColumnDefinition Width="5*"/>
|
|
||||||
<ColumnDefinition Width="7*"/>
|
|
||||||
</Grid.ColumnDefinitions>
|
|
||||||
|
|
||||||
</Grid>
|
|
||||||
|
|
||||||
<!-- Definizione della Grid laterale -->
|
|
||||||
<Grid Grid.RowSpan="3">
|
|
||||||
<Grid.RowDefinitions>
|
|
||||||
<RowDefinition Height="2*"/>
|
|
||||||
<RowDefinition Height="7*"/>
|
|
||||||
<RowDefinition Height="1*"/>
|
<RowDefinition Height="1*"/>
|
||||||
</Grid.RowDefinitions>
|
<RowDefinition Height="8*"/>
|
||||||
|
<RowDefinition Height="1*"/>
|
||||||
|
</Grid.RowDefinitions>
|
||||||
|
|
||||||
<!-- Definizione della Grid con le caratteristiche del progetto -->
|
<!-- Definizione della Grid superiore -->
|
||||||
|
<Grid Name="UpperButtonGrid" Grid.Column="1" Grid.Row="0" >
|
||||||
|
<Grid.ColumnDefinitions>
|
||||||
|
<ColumnDefinition Width="5*"/>
|
||||||
|
<ColumnDefinition Width="7*"/>
|
||||||
|
</Grid.ColumnDefinitions>
|
||||||
|
|
||||||
|
</Grid>
|
||||||
|
|
||||||
|
<!-- Definizione della Grid laterale -->
|
||||||
|
<Grid Grid.RowSpan="3">
|
||||||
|
<Grid.RowDefinitions>
|
||||||
|
<RowDefinition Height="2*"/>
|
||||||
|
<RowDefinition Height="7*"/>
|
||||||
|
<RowDefinition Height="1*"/>
|
||||||
|
</Grid.RowDefinitions>
|
||||||
|
|
||||||
|
<!-- Definizione della Grid con le caratteristiche del progetto -->
|
||||||
<Border Name="CurrProjGrid" Style="{DynamicResource OmagCut_MachiningBorder}" Grid.Row="0" >
|
<Border Name="CurrProjGrid" Style="{DynamicResource OmagCut_MachiningBorder}" Grid.Row="0" >
|
||||||
<Grid >
|
<Grid >
|
||||||
<Grid.ColumnDefinitions>
|
<Grid.ColumnDefinitions>
|
||||||
<ColumnDefinition Width="1*"/>
|
<ColumnDefinition Width="0.2*"/>
|
||||||
<ColumnDefinition Width="1*"/>
|
<ColumnDefinition Width="1*"/>
|
||||||
</Grid.ColumnDefinitions>
|
</Grid.ColumnDefinitions>
|
||||||
<Grid.RowDefinitions>
|
<Grid.RowDefinitions>
|
||||||
<RowDefinition Height="0.5*"/>
|
<RowDefinition Height="0.5*"/>
|
||||||
<RowDefinition Height="0.5*"/>
|
<RowDefinition Height="0.5*"/>
|
||||||
<RowDefinition Height="0.5*"/>
|
<RowDefinition Height="0.5*"/>
|
||||||
<RowDefinition Height="0.5*"/>
|
<RowDefinition Height="0.5*"/>
|
||||||
</Grid.RowDefinitions>
|
</Grid.RowDefinitions>
|
||||||
|
|
||||||
<TextBlock Name="MaterialTxBl" Grid.Row="0"
|
<Image Name="MaterialTxBl"
|
||||||
Style="{DynamicResource OmagCut_CurrProjSummeryTextBlock}"/>
|
Source="{DynamicResource RawPartImg}" Style="{StaticResource OmagCut_TextIcon}"/>
|
||||||
<EgtWPFLib:EgtTextBox Name="MaterialTxBx" Grid.Column="1" Grid.Row="0" Width="100"
|
<EgtWPFLib:EgtTextBox Name="MaterialTxBx" Grid.Column="1" Grid.Row="0" Margin="0,0,10,0"
|
||||||
Style="{DynamicResource OmagCut_FixedTextBox}"/>
|
TextAlignment="Right" Style="{DynamicResource OmagCut_FixedTextBox}"/>
|
||||||
<TextBlock Name="HeightTxBl" Grid.Row="1"
|
<Image Name="HeightTxBl" Grid.Row="1"
|
||||||
Style="{DynamicResource OmagCut_CurrProjSummeryTextBlock}"/>
|
Source="{DynamicResource RawHeightImg}" Style="{StaticResource OmagCut_TextIcon}"/>
|
||||||
<EgtWPFLib:EgtTextBox Name="HeightTxBx" Grid.Column="1" Grid.Row="1" Width="100"
|
<EgtWPFLib:EgtTextBox Name="HeightTxBx" Grid.Column="1" Grid.Row="1" Margin="0,0,10,0"
|
||||||
|
Style="{DynamicResource OmagCut_FixedTextBox}" TextAlignment="Right"/>
|
||||||
|
<Image Name="ToolTxBl" Grid.Row="2"
|
||||||
|
Source="{DynamicResource DB-utensiliImg}" Style="{StaticResource OmagCut_TextIcon}"/>
|
||||||
|
<EgtWPFLib:EgtTextBox Name="ToolTxBx" Grid.Column="1" Grid.Row="2" Margin="0,0,10,0"
|
||||||
|
Style="{DynamicResource OmagCut_FixedTextBox}" TextAlignment="Right"/>
|
||||||
|
<Image Name="MachiningTxBl" Grid.Row="3"
|
||||||
|
Source="{DynamicResource DB-lavorazioniImg}" Style="{StaticResource OmagCut_TextIcon}"/>
|
||||||
|
<EgtWPFLib:EgtTextBox Name="MachiningTxBx" Grid.Column="1" Grid.Row="3" Margin="0,0,10,0"
|
||||||
Style="{DynamicResource OmagCut_FixedTextBox}" TextAlignment="Right"/>
|
Style="{DynamicResource OmagCut_FixedTextBox}" TextAlignment="Right"/>
|
||||||
<TextBlock Name="ToolTxBl" Grid.Row="2" Style="{DynamicResource OmagCut_CurrProjSummeryTextBlock}"/>
|
|
||||||
<EgtWPFLib:EgtTextBox Name="ToolTxBx" Grid.Column="1" Grid.Row="2" Width="100"
|
|
||||||
Style="{DynamicResource OmagCut_FixedTextBox}"/>
|
|
||||||
<TextBlock Name="MachiningTxBl" Grid.Row="3"
|
|
||||||
Style="{DynamicResource OmagCut_CurrProjSummeryTextBlock}"/>
|
|
||||||
<EgtWPFLib:EgtTextBox Name="MachiningTxBx" Grid.Column="1" Grid.Row="3" Width="100"
|
|
||||||
Style="{DynamicResource OmagCut_FixedTextBox}"/>
|
|
||||||
|
|
||||||
</Grid>
|
</Grid>
|
||||||
|
|
||||||
</Border>
|
</Border>
|
||||||
|
|
||||||
<ProgressBar Name="PhotoProgress" Grid.Row="2" Height="50" Margin="10,0,10,0" Minimum="0" Maximum="100"/>
|
<ProgressBar Name="PhotoProgress" Grid.Row="2" Height="50" Margin="10,0,10,0" Minimum="0" Maximum="100"/>
|
||||||
|
|
||||||
<Border Name="OutMessageBrd" Grid.Row="2" >
|
<Border Name="OutMessageBrd" Grid.Row="2" >
|
||||||
<TextBlock Name="OutMessageTxBl" TextAlignment="Center"
|
<TextBlock Name="OutMessageTxBl" TextAlignment="Center"
|
||||||
Style="{StaticResource OmagCut_LowerCaseCharacterTextBlock}"/>
|
Style="{StaticResource OmagCut_LowerCaseCharacterTextBlock}"/>
|
||||||
</Border>
|
</Border>
|
||||||
|
|
||||||
</Grid>
|
</Grid>
|
||||||
|
|
||||||
</Grid>
|
</Grid>
|
||||||
|
|
||||||
</UserControl>
|
</UserControl>
|
||||||
|
|||||||
@@ -58,10 +58,10 @@ Public Class CurrentProjectPageUC
|
|||||||
Me.CurrentProjectPageGrid.Children.Add(CurrentProjectSceneHost)
|
Me.CurrentProjectPageGrid.Children.Add(CurrentProjectSceneHost)
|
||||||
|
|
||||||
'Imposto i messaggi letti dal file dei messaggi
|
'Imposto i messaggi letti dal file dei messaggi
|
||||||
MaterialTxBl.Text = EgtMsg(MSG_RAWPARTPAGEUC + 9) 'Material - Materiale
|
MaterialTxBl.ToolTip = EgtMsg(MSG_RAWPARTPAGEUC + 9) 'Material - Materiale
|
||||||
HeightTxBl.Text = EgtMsg(MSG_RAWPARTPAGEUC + 5) 'Height - Spessore
|
HeightTxBl.ToolTip = EgtMsg(MSG_RAWPARTPAGEUC + 5) 'Height - Spessore
|
||||||
ToolTxBl.Text = EgtMsg(MSG_CADCUTPAGEUC + 11) 'Tool - Utensile
|
ToolTxBl.ToolTip = EgtMsg(MSG_CADCUTPAGEUC + 11) 'Tool - Utensile
|
||||||
MachiningTxBl.Text = EgtMsg(MSG_CADCUTPAGEUC + 12) 'Machining - Lavorazione
|
MachiningTxBl.ToolTip = EgtMsg(MSG_CADCUTPAGEUC + 12) 'Machining - Lavorazione
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
@@ -118,11 +118,25 @@ Public Class CurrentProjectPageUC
|
|||||||
#Else
|
#Else
|
||||||
' Se manca la chiave
|
' Se manca la chiave
|
||||||
If m_MainWindow.GetKeyLevel() = -1 Or m_MainWindow.GetKeyLevel() = -2 Then
|
If m_MainWindow.GetKeyLevel() = -1 Or m_MainWindow.GetKeyLevel() = -2 Then
|
||||||
EgtOutLog("Missing Dongle")
|
If Not EgtGetNetHwKey() Then
|
||||||
' Box di avviso chiave mancante : "Chiave non presente. \n Inserirla e riavviare il programma." "Errore"
|
EgtOutLog("Missing Dongle")
|
||||||
Dim sText As String = EgtMsg(MSG_MISSINGKEYWD + 2) & vbCrLf & EgtMsg(MSG_MISSINGKEYWD + 3)
|
' Box di avviso chiave mancante : "Chiave non presente. \n Inserirla e riavviare il programma." "Errore"
|
||||||
Dim sTitle As String = EgtMsg(MSG_MISSINGKEYWD + 1)
|
Dim sText As String = EgtMsg(MSG_MISSINGKEYWD + 2) & vbCrLf & EgtMsg(MSG_MISSINGKEYWD + 3)
|
||||||
Dim MissingKeyWnd As New EgtMsgBox(m_MainWindow, EgtMsg(MSG_MISSINGKEYWD + 1), EgtMsg(MSG_MISSINGKEYWD + 2) & " " & EgtMsg(MSG_MISSINGKEYWD + 3), EgtMsgBox.Buttons.OK, EgtMsgBox.Icons.NULL)
|
Dim sTitle As String = EgtMsg(MSG_MISSINGKEYWD + 1)
|
||||||
|
Dim MissingKeyWnd As New EgtMsgBox(m_MainWindow, EgtMsg(MSG_MISSINGKEYWD + 1), EgtMsg(MSG_MISSINGKEYWD + 2) & " " & EgtMsg(MSG_MISSINGKEYWD + 3), EgtMsgBox.Buttons.OK, EgtMsgBox.Icons.NULL)
|
||||||
|
Else
|
||||||
|
EgtOutLog("NetDongle is full")
|
||||||
|
' Box di avviso slot chiave di rete occupato : "Chiave di Rete completamente occupata. \n Uscire dal programma su un altro PC." "Errore"
|
||||||
|
Dim sText As String = EgtMsg(10110) & vbCrLf & EgtMsg(10111)
|
||||||
|
Dim sTitle As String = EgtMsg(10101)
|
||||||
|
Dim MissingKeyWnd As New EgtMsgBox(m_MainWindow, sTitle, sText, EgtMsgBox.Buttons.OK, EgtMsgBox.Icons.NULL)
|
||||||
|
End If
|
||||||
|
ElseIf m_MainWindow.GetKeyLevel() = -9 Then
|
||||||
|
EgtOutLog("Missing Link with Net Dongle")
|
||||||
|
' Box di avviso chiave mancante : "Collegamento con la Chiave di rete non riuscito. \n Verificare la connessione." "Errore"
|
||||||
|
Dim sText As String = EgtMsg(10108) & vbCrLf & EgtMsg(10109)
|
||||||
|
Dim sTitle As String = EgtMsg(10101)
|
||||||
|
Dim MissingKeyWnd As New EgtMsgBox(m_MainWindow, sTitle, sText, EgtMsgBox.Buttons.OK, EgtMsgBox.Icons.NULL)
|
||||||
' Altrimenti manca la licenza
|
' Altrimenti manca la licenza
|
||||||
Else
|
Else
|
||||||
EgtOutLog("Problems with Licence")
|
EgtOutLog("Problems with Licence")
|
||||||
@@ -196,9 +210,17 @@ Public Class CurrentProjectPageUC
|
|||||||
Else
|
Else
|
||||||
MaterialTxBx.Text = "-----"
|
MaterialTxBx.Text = "-----"
|
||||||
End If
|
End If
|
||||||
' Visualizzo lama e lavorazione correnti
|
|
||||||
ToolTxBx.Text = m_MainWindow.m_CurrentMachine.sCurrSaw
|
' se macchina waterjet e senza una lama corrente impostata allora visualizzo info WJ
|
||||||
MachiningTxBx.Text = m_MainWindow.m_CurrentMachine.sCurrSawing
|
If m_MainWindow.m_CurrentMachine.bWaterJet And String.IsNullOrEmpty(m_MainWindow.m_CurrentMachine.sCurrSaw) Then
|
||||||
|
ToolTxBx.Text = m_MainWindow.m_CurrentMachine.sCurrWaterJet
|
||||||
|
MachiningTxBx.Text = m_MainWindow.m_CurrentMachine.sCurrWaterJetting
|
||||||
|
'& "-" & m_MainWindow.m_CurrentMachine.sCurrWaterJettingQuality
|
||||||
|
Else
|
||||||
|
ToolTxBx.Text = m_MainWindow.m_CurrentMachine.sCurrSaw
|
||||||
|
MachiningTxBx.Text = m_MainWindow.m_CurrentMachine.sCurrSawing
|
||||||
|
End If
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Public Sub StartProgram()
|
Public Sub StartProgram()
|
||||||
@@ -1000,10 +1022,16 @@ Public Class CurrentProjectPageUC
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Friend Sub UpdateMachiningTxBx()
|
Friend Sub UpdateMachiningTxBx()
|
||||||
MachiningTxBx.Text = m_MainWindow.m_CurrentMachine.sCurrSawing
|
' se macchina waterjet e senza uscita lama allora visualizzo info WJ
|
||||||
|
If m_MainWindow.m_CurrentMachine.bWaterJet And EgtGetHeadId("H1") = GDB_ID.NULL Then
|
||||||
|
MachiningTxBx.Text = m_MainWindow.m_CurrentMachine.sCurrWaterJetting
|
||||||
|
'& "-" & m_MainWindow.m_CurrentMachine.sCurrWaterJettingQuality
|
||||||
|
Else
|
||||||
|
MachiningTxBx.Text = m_MainWindow.m_CurrentMachine.sCurrSawing
|
||||||
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
' Gestione fotografia della lastra (compreso riconoscimento contorno)
|
' Gestione fotografia della lastra (compreso riconoscimento contorno)
|
||||||
|
|
||||||
Friend Function LoadPhoto(sPath As String) As Boolean
|
Friend Function LoadPhoto(sPath As String) As Boolean
|
||||||
' Verifico esistenza file immagine
|
' Verifico esistenza file immagine
|
||||||
|
|||||||
+126
-27
@@ -314,47 +314,109 @@ Public Class ProjectMgrUC
|
|||||||
Dim m_ptRawMax, m_ptRawMin As Point3d
|
Dim m_ptRawMax, m_ptRawMin As Point3d
|
||||||
If Not GetRawBox(m_ptRawMin, m_ptRawMax) Then Return
|
If Not GetRawBox(m_ptRawMin, m_ptRawMax) Then Return
|
||||||
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 TestToolWD As New ChooseTestToolWD(m_MainWindow)
|
||||||
EgtTdbSetCurrTool(sSaw)
|
TestToolWD.ShowDialog()
|
||||||
|
If Not TestToolWD.DialogResult Then Return
|
||||||
|
Dim CurrTestTool As TestTool = TestToolWD.GetSelectedTool
|
||||||
|
|
||||||
|
'Dim sSaw As String = m_MainWindow.m_CurrentMachine.sCurrSaw
|
||||||
|
'EgtTdbSetCurrTool(sSaw)
|
||||||
|
|
||||||
Dim dThick As Double = 0
|
Dim dThick As Double = 0
|
||||||
EgtTdbGetCurrToolParam(MCH_TP.THICK, dThick)
|
Dim dHeight As Double = 0
|
||||||
Dim dDiam As Double = 0
|
If CurrTestTool.ToolIsSaw Then
|
||||||
EgtTdbGetCurrToolParam(MCH_TP.DIAM, dDiam)
|
' Spessore LAMA
|
||||||
|
EgtTdbGetCurrToolParam(MCH_TP.THICK, dThick)
|
||||||
|
' Diametro
|
||||||
|
EgtTdbGetCurrToolParam(MCH_TP.DIAM, dHeight)
|
||||||
|
' Raggio lama
|
||||||
|
dHeight = dHeight / 2
|
||||||
|
Else
|
||||||
|
' Diametro FRESA/FORETTO (l'altezza non serve: posizione calcolata tiene conto del Tip Tool)
|
||||||
|
EgtTdbGetCurrToolParam(MCH_TP.DIAM, dThick)
|
||||||
|
' Raggio
|
||||||
|
dThick = dThick / 2
|
||||||
|
End If
|
||||||
|
|
||||||
|
|
||||||
'recupero il lato selezionato
|
'recupero il lato selezionato
|
||||||
Dim nIdSelected As Integer = m_MainWindow.m_CadCutPageUC.m_NestPage.m_CurrSelectedCurv
|
Dim nIdSelected As Integer = m_MainWindow.m_CadCutPageUC.m_NestPage.m_CurrSelectedCurv
|
||||||
If nIdSelected = -1 Then Return
|
If nIdSelected = -1 Then Return
|
||||||
' recupero gli estremi del latovda tagliare
|
' recupero il vettore nel punto medio dell'entità
|
||||||
Dim ptStart As Point3d
|
Dim vtDirLine As Vector3d
|
||||||
EgtStartPoint(nIdSelected, GDB_ID.ROOT, ptStart)
|
EgtMidVector(nIdSelected, GDB_ID.ROOT, vtDirLine)
|
||||||
Dim ptEnd As Point3d
|
|
||||||
EgtEndPoint(nIdSelected, GDB_ID.ROOT, ptEnd)
|
' calcolo il versore della linea di taglio
|
||||||
Dim vtDirLine As Vector3d = ptEnd - ptStart
|
|
||||||
' calcolo il versore perpendicolare alla linea di taglio (diretto verso l'interno del pezzo)
|
|
||||||
Dim vtDirT As Vector3d = vtDirLine
|
Dim vtDirT As Vector3d = vtDirLine
|
||||||
vtDirT.Normalize()
|
vtDirT.Normalize()
|
||||||
vtDirT.Rotate(Vector3d.Z_AX, 90)
|
' calcolo la direzione di offset da applicare all'utensile
|
||||||
|
Dim vtOffset As New Vector3d(vtDirT.x, vtDirT.y, vtDirT.z)
|
||||||
|
vtOffset.Rotate(Vector3d.Z_AX, 90)
|
||||||
|
|
||||||
|
If CurrTestTool.ToolIsSaw Then
|
||||||
|
' calcolo il versore perpendicolare alla linea di taglio (diretto verso l'interno del pezzo)
|
||||||
|
vtDirT.Rotate(Vector3d.Z_AX, 90)
|
||||||
|
Else
|
||||||
|
' calcolo il versore perpendicolare alla linea di taglio (diretto verso l'interno del pezzo)
|
||||||
|
vtDirT.Rotate(Vector3d.Z_AX, 90)
|
||||||
|
' calcolo il versore perpendicolare al piano di taglio (diretto verso l'interno dell'utensile)
|
||||||
|
vtDirT.Rotate(vtDirLine, 90)
|
||||||
|
End If
|
||||||
|
|
||||||
' Calcolo punto di posizionamemto (punto medio)
|
' Calcolo punto di posizionamemto (punto medio)
|
||||||
Dim ptMid, m_ptTabOri As Point3d
|
Dim ptMid, m_ptTabOri As Point3d
|
||||||
|
|
||||||
If Not EgtGetTableRef(1, m_ptTabOri) Then Return
|
If Not EgtGetTableRef(1, m_ptTabOri) Then Return
|
||||||
ptMid.x = (ptEnd.x + ptStart.x) / 2
|
' recupero il punto medio della curva
|
||||||
ptMid.y = (ptEnd.y + ptStart.y) / 2
|
EgtMidPoint(nIdSelected, GDB_ID.ROOT, ptMid)
|
||||||
ptMid.z = (ptEnd.z + ptStart.z) / 2 + dDiam / 2
|
ptMid.z = m_ptTabOri.z + CamAuto.GetRawHeight() + dHeight
|
||||||
ptMid -= vtDirT * dThick
|
' Offset dovuto allo spessore Utensile
|
||||||
|
ptMid -= vtOffset * dThick
|
||||||
|
|
||||||
'--------------------------- Imposto la posizione della macchina ----------------------------
|
'--------------------------- Imposto la posizione della macchina ----------------------------
|
||||||
' Recupero la posizione macchina
|
' Recupero la posizione macchina
|
||||||
Dim dL1, dL2, dL3, dR1, dR2 As Double
|
Dim dL1, dL2, dL3, dR1, dR2 As Double
|
||||||
If Not m_MainWindow.m_CNCommunication.GetAxesPositions(dL1, dL2, dL3, dR1, dR2) Then Return
|
If Not m_MainWindow.m_CNCommunication.GetAxesPositions(dL1, dL2, dL3, dR1, dR2) Then Return
|
||||||
' Imposto la lama corrente
|
|
||||||
If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
' Imposto la lama corrente, preso dalla scelta precedente
|
||||||
|
'If Not EgtSetCalcTool(sSaw, "H1", 1) Then Return
|
||||||
|
If Not EgtSetCalcTool(CurrTestTool.ToolName, CurrTestTool.ToolHead, CurrTestTool.ToolExit) Then Return
|
||||||
|
|
||||||
' calcolo la posizione degli assi rotanti C, B
|
' calcolo la posizione degli assi rotanti C, B
|
||||||
Dim nStat As Integer
|
Dim nStat As Integer
|
||||||
Dim dC1, dB1, dC2, dB2 As Double
|
Dim dC1, dB1, dC2, dB2 As Double
|
||||||
EgtGetCalcAngles(vtDirT, Vector3d.Z_AX(), nStat, dC1, dB1, dC2, dB2)
|
If CurrTestTool.ToolIsSaw Then
|
||||||
|
' Se LAMA
|
||||||
|
EgtGetCalcAngles(vtDirT, Vector3d.Z_AX(), nStat, dC1, dB1, dC2, dB2)
|
||||||
|
ElseIf CurrTestTool.ToolIsLaser Then
|
||||||
|
' Se LASER
|
||||||
|
Dim dHomeC As Double = 90
|
||||||
|
EgtGetAxisHomePos("C", dHomeC)
|
||||||
|
Dim vtPrefAuxDir As Vector3d = -Vector3d.X_AX()
|
||||||
|
vtPrefAuxDir.Rotate(Vector3d.Z_AX, dHomeC)
|
||||||
|
EgtGetCalcAngles(vtDirT, vtPrefAuxDir, nStat, dC1, dB1, dC2, dB2)
|
||||||
|
' Forzo B90
|
||||||
|
dB1 = 90
|
||||||
|
Else
|
||||||
|
' Se utensile speciale
|
||||||
|
If CurrTestTool.ToolType = MCH_TY.MILL_STD Or CurrTestTool.ToolType = MCH_TY.DRILL_STD Then
|
||||||
|
' Se FRESA/FORETTO
|
||||||
|
Dim nStepRotC As Integer = GetPrivateProfileInt(S_NEST, K_MACH_DRILL_MILL_C90, 1, m_MainWindow.GetMachIniFile())
|
||||||
|
Dim vtPrefAuxDir As Vector3d = -Vector3d.X_AX()
|
||||||
|
vtPrefAuxDir.Rotate(Vector3d.Z_AX, 90 * nStepRotC)
|
||||||
|
EgtGetCalcAngles(vtDirT, vtPrefAuxDir, nStat, dC1, dB1, dC2, dB2)
|
||||||
|
ElseIf CurrTestTool.ToolType = MCH_TY.WATERJET Then
|
||||||
|
' Se WJ
|
||||||
|
Dim dHomeC As Double = 90
|
||||||
|
EgtGetAxisHomePos("C", dHomeC)
|
||||||
|
Dim vtPrefAuxDir As Vector3d = Vector3d.X_AX()
|
||||||
|
vtPrefAuxDir.Rotate(Vector3d.Z_AX, dHomeC)
|
||||||
|
EgtGetCalcAngles(vtDirT, vtPrefAuxDir, nStat, dC1, dB1, dC2, dB2)
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
' calcolo la posizione degli assi lineari X, Y, Z
|
' calcolo la posizione degli assi lineari X, Y, Z
|
||||||
Dim dX, dY, dZ As Double
|
Dim dX, dY, dZ As Double
|
||||||
EgtGetCalcPositions(ptMid, dC1, dB1, nStat, dX, dY, dZ)
|
EgtGetCalcPositions(ptMid, dC1, dB1, nStat, dX, dY, dZ)
|
||||||
@@ -364,14 +426,40 @@ Public Class ProjectMgrUC
|
|||||||
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)
|
If CurrTestTool.ToolIsSaw Then
|
||||||
|
EgtGetCalcAngles(vtDirT, Vector3d.Z_AX(), nStat, dC1, dB1, dC2, dB2)
|
||||||
|
ElseIf CurrTestTool.ToolIsLaser Then
|
||||||
|
' Se LASER
|
||||||
|
Dim dHomeC As Double = 90
|
||||||
|
EgtGetAxisHomePos("C", dHomeC)
|
||||||
|
Dim vtPrefAuxDir As Vector3d = -Vector3d.X_AX()
|
||||||
|
vtPrefAuxDir.Rotate(Vector3d.Z_AX, dHomeC)
|
||||||
|
EgtGetCalcAngles(vtDirT, vtPrefAuxDir, nStat, dC1, dB1, dC2, dB2)
|
||||||
|
' Forzo B90
|
||||||
|
dB1 = 90
|
||||||
|
Else
|
||||||
|
If CurrTestTool.ToolType = MCH_TY.MILL_STD Or CurrTestTool.ToolType = MCH_TY.DRILL_STD Then
|
||||||
|
' Se FRESA/FORETTO
|
||||||
|
Dim nStepRotC As Integer = GetPrivateProfileInt(S_NEST, K_MACH_DRILL_MILL_C90, 1, m_MainWindow.GetMachIniFile())
|
||||||
|
Dim vtPrefAuxDir As Vector3d = -Vector3d.X_AX()
|
||||||
|
vtPrefAuxDir.Rotate(Vector3d.Z_AX, 90 * nStepRotC)
|
||||||
|
EgtGetCalcAngles(vtDirT, vtPrefAuxDir, nStat, dC1, dB1, dC2, dB2)
|
||||||
|
ElseIf CurrTestTool.ToolType = MCH_TY.WATERJET Then
|
||||||
|
' Se WJ
|
||||||
|
Dim dHomeC As Double = 90
|
||||||
|
EgtGetAxisHomePos("C", dHomeC)
|
||||||
|
Dim vtPrefAuxDir As Vector3d = Vector3d.X_AX()
|
||||||
|
vtPrefAuxDir.Rotate(Vector3d.Z_AX, dHomeC)
|
||||||
|
EgtGetCalcAngles(vtDirT, vtPrefAuxDir, nStat, dC1, dB1, dC2, dB2)
|
||||||
|
End If
|
||||||
|
End If
|
||||||
' 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)
|
||||||
EgtGetCalcPositions(ptMid, dC1, dB1, nStat, dX, dY, dZ)
|
EgtGetCalcPositions(ptMid, dC1, dB1, nStat, dX, dY, dZ)
|
||||||
End If
|
End If
|
||||||
|
|
||||||
'--------------------------- Comunico i movimenti in origine macchina al CN ----------------------------------------
|
'--------------------------- Comunico i movimenti in origine macchina al CN ----------------------------------------
|
||||||
Dim ptMachine As Point3d = New Point3d(dX, dY, dZ)
|
Dim ptMachine As Point3d = New Point3d(dX, dY, If(CurrTestTool.ToolIsLaser, 0, dZ))
|
||||||
ExecuteCommandCNC(ptMachine, dC1, dB1)
|
ExecuteCommandCNC(ptMachine, dC1, dB1, CurrTestTool)
|
||||||
Return
|
Return
|
||||||
End If
|
End If
|
||||||
' ---------------------------- Fine modalità test --------------------------------------------
|
' ---------------------------- Fine modalità test --------------------------------------------
|
||||||
@@ -845,7 +933,7 @@ Public Class ProjectMgrUC
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
' ------------------------------------------------ GENERA COMANDI CNC MOVIMENTO ------------------------------------------------
|
' ------------------------------------------------ GENERA COMANDI CNC MOVIMENTO ------------------------------------------------
|
||||||
Private Sub ExecuteCommandCNC(ptMid As Point3d, dAngC As Double, dAngB As Double)
|
Private Sub ExecuteCommandCNC(ptMid As Point3d, dAngC As Double, dAngB As Double, SelTestTool As TestTool)
|
||||||
|
|
||||||
Dim CmdString As String = String.Empty
|
Dim CmdString As String = String.Empty
|
||||||
If Not EgtLuaExecFile(m_MainWindow.m_CurrentMachine.sMachDir() & "\DirectCmd\TestWork.lua") Then
|
If Not EgtLuaExecFile(m_MainWindow.m_CurrentMachine.sMachDir() & "\DirectCmd\TestWork.lua") Then
|
||||||
@@ -871,12 +959,22 @@ Public Class ProjectMgrUC
|
|||||||
EgtLuaSetGlobNumVar("CMD.R1", dR1)
|
EgtLuaSetGlobNumVar("CMD.R1", dR1)
|
||||||
EgtLuaSetGlobNumVar("CMD.R2", dR2)
|
EgtLuaSetGlobNumVar("CMD.R2", dR2)
|
||||||
|
|
||||||
' 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
|
||||||
EgtTdbSetCurrTool(sSaw)
|
'EgtTdbSetCurrTool(sSaw)
|
||||||
|
'Dim dThick As Double = 0
|
||||||
|
'EgtTdbGetCurrToolParam(MCH_TP.THICK, dThick)
|
||||||
|
'EgtLuaSetGlobNumVar("CMD.SAWTH", dThick)
|
||||||
|
|
||||||
|
EgtTdbSetCurrTool(SelTestTool.ToolName)
|
||||||
|
EgtLuaSetGlobStringVar("CMD.TLNAME", SelTestTool.ToolAlias)
|
||||||
Dim dThick As Double = 0
|
Dim dThick As Double = 0
|
||||||
EgtTdbGetCurrToolParam(MCH_TP.THICK, dThick)
|
EgtTdbGetCurrToolParam(MCH_TP.THICK, dThick)
|
||||||
EgtLuaSetGlobNumVar("CMD.SAWTH", dThick)
|
EgtLuaSetGlobNumVar("CMD.SAWTH", dThick)
|
||||||
|
Dim sTCPos As String = String.Empty
|
||||||
|
EgtTdbGetCurrToolParam(MCH_TP.TCPOS, sTCPos)
|
||||||
|
EgtLuaSetGlobStringVar("CMD.TCPOS", sTCPos)
|
||||||
|
|
||||||
|
|
||||||
'----------- ASSEGNO POSIZIONE DI ARRIVO MACCHINA -----------
|
'----------- ASSEGNO POSIZIONE DI ARRIVO MACCHINA -----------
|
||||||
' Assegno valore ad ogni asse da muovere (in zero macchina)
|
' Assegno valore ad ogni asse da muovere (in zero macchina)
|
||||||
@@ -935,6 +1033,7 @@ Public Class ProjectMgrUC
|
|||||||
m_MainWindow.m_CadCutPageUC.m_NestPage.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)
|
||||||
EgtResetMark(m_MainWindow.m_CadCutPageUC.m_NestPage.m_CurrSelectedSawCurv)
|
EgtResetMark(m_MainWindow.m_CadCutPageUC.m_NestPage.m_CurrSelectedSawCurv)
|
||||||
|
m_MainWindow.m_CadCutPageUC.m_NestPage.m_CurrToolFromSelectedSawCurv = String.Empty
|
||||||
End If
|
End If
|
||||||
' aggiorno il disegno
|
' aggiorno il disegno
|
||||||
EgtDraw()
|
EgtDraw()
|
||||||
|
|||||||
@@ -175,20 +175,24 @@ Public Class ChooseMachining
|
|||||||
|
|
||||||
End Select
|
End Select
|
||||||
|
|
||||||
' verifico che lista delle lavorazioni di lama non sia vuoto
|
If m_CurrentMachine.bWaterJet And EgtGetHeadId("H1") = GDB_ID.NULL Then
|
||||||
If m_SawingList.Count > 0 Then
|
|
||||||
' provo ad assegnare la lama corrente (se l'associazione fallisce corrispoende ad impostare un campo vuoto)
|
|
||||||
CurrSawingCmBx.SelectedItem = m_MainWindow.m_CurrentMachine.sCurrSawing
|
|
||||||
Else
|
Else
|
||||||
m_MainWindow.m_CurrentMachine.sCurrSawing = String.Empty
|
' verifico che lista delle lavorazioni di lama non sia vuoto
|
||||||
End If
|
If m_SawingList.Count > 0 Then
|
||||||
' se non riesco a fare l'assegnazione della lama allora elimino il nome della lama salvata
|
' provo ad assegnare la lama corrente (se l'associazione fallisce corrispoende ad impostare un campo vuoto)
|
||||||
If String.IsNullOrEmpty(CurrSawingCmBx.SelectedItem) Then
|
CurrSawingCmBx.SelectedItem = m_MainWindow.m_CurrentMachine.sCurrSawing
|
||||||
' verifico che il nome della lama esista
|
Else
|
||||||
If CurrSawingCmBx.SelectedItem <> m_MainWindow.m_CurrentMachine.sCurrSawing Then
|
m_MainWindow.m_CurrentMachine.sCurrSawing = String.Empty
|
||||||
m_MachIsModified = True
|
End If
|
||||||
|
' se non riesco a fare l'assegnazione della lama allora elimino il nome della lama salvata
|
||||||
|
If String.IsNullOrEmpty(CurrSawingCmBx.SelectedItem) Then
|
||||||
|
' verifico che il nome della lama esista
|
||||||
|
If CurrSawingCmBx.SelectedItem <> m_MainWindow.m_CurrentMachine.sCurrSawing Then
|
||||||
|
m_MachIsModified = True
|
||||||
|
End If
|
||||||
|
m_MainWindow.m_CurrentMachine.sCurrSawing = String.Empty
|
||||||
End If
|
End If
|
||||||
m_MainWindow.m_CurrentMachine.sCurrSawing = String.Empty
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
' definizione della lista delle lavorazioni secondarie -- DA RIMUOVERE COMPLETAMENTE --
|
' definizione della lista delle lavorazioni secondarie -- DA RIMUOVERE COMPLETAMENTE --
|
||||||
|
|||||||
Binary file not shown.
|
After Width: | Height: | Size: 7.7 KiB |
Reference in New Issue
Block a user