OmagCUT :
- aggiunta gestione svuotature (manca scelta lavorazione da interfaccia) - ora compilazione richiede dichiarazione delle variabili, modificati di conseguenza i diversi sorgenti.
This commit is contained in:
@@ -460,6 +460,7 @@
|
||||
<RowDefinition Height="0.5*"/>
|
||||
<RowDefinition Height="0.5*"/>
|
||||
<RowDefinition Height="0.5*"/>
|
||||
<RowDefinition Height="0.5*"/>
|
||||
</Grid.RowDefinitions>
|
||||
|
||||
<TextBlock Name="CurrSawingTxBl" Grid.Column="0" Grid.Row="0"
|
||||
@@ -477,19 +478,24 @@
|
||||
<EgtWPFLib:EgtTextBox Name="CurrMillingTxBx" Grid.Column="1" Grid.Row="2" Margin="10,0,10,0"
|
||||
Style="{DynamicResource OmagCut_FixedTextBox}" />
|
||||
|
||||
<TextBlock Name="CurrWaterJettingTxBl" Grid.Column="0" Grid.Row="3"
|
||||
<TextBlock Name="CurrPocketingTxBl" Grid.Column="0" Grid.Row="3"
|
||||
Style="{DynamicResource OmagCut_ToolsDBTextBlock}"/>
|
||||
<EgtWPFLib:EgtTextBox Name="CurrWaterJettingTxBx" Grid.Column="1" Grid.Row="3" Margin="10,0,10,0"
|
||||
<EgtWPFLib:EgtTextBox Name="CurrPocketingTxBx" Grid.Column="1" Grid.Row="3" Margin="10,0,10,0"
|
||||
Style="{DynamicResource OmagCut_FixedTextBox}" />
|
||||
|
||||
<TextBlock Name="CurrDripSawingTxBl" Grid.Column="0" Grid.Row="4"
|
||||
<TextBlock Name="CurrWaterJettingTxBl" Grid.Column="0" Grid.Row="4"
|
||||
Style="{DynamicResource OmagCut_ToolsDBTextBlock}"/>
|
||||
<EgtWPFLib:EgtTextBox Name="CurrDripSawingTxBx" Grid.Column="1" Grid.Row="4" Margin="10,0,10,0"
|
||||
<EgtWPFLib:EgtTextBox Name="CurrWaterJettingTxBx" Grid.Column="1" Grid.Row="4" Margin="10,0,10,0"
|
||||
Style="{DynamicResource OmagCut_FixedTextBox}" />
|
||||
|
||||
<TextBlock Name="CurrDripDrillingTxBl" Grid.Column="0" Grid.Row="5"
|
||||
<TextBlock Name="CurrDripSawingTxBl" Grid.Column="0" Grid.Row="5"
|
||||
Style="{DynamicResource OmagCut_ToolsDBTextBlock}"/>
|
||||
<EgtWPFLib:EgtTextBox Name="CurrDripDrillingTxBx" Grid.Column="1" Grid.Row="5" Margin="10,0,10,0"
|
||||
<EgtWPFLib:EgtTextBox Name="CurrDripSawingTxBx" Grid.Column="1" Grid.Row="5" Margin="10,0,10,0"
|
||||
Style="{DynamicResource OmagCut_FixedTextBox}" />
|
||||
|
||||
<TextBlock Name="CurrDripDrillingTxBl" Grid.Column="0" Grid.Row="6"
|
||||
Style="{DynamicResource OmagCut_ToolsDBTextBlock}"/>
|
||||
<EgtWPFLib:EgtTextBox Name="CurrDripDrillingTxBx" Grid.Column="1" Grid.Row="6" Margin="10,0,10,0"
|
||||
Style="{DynamicResource OmagCut_FixedTextBox}" />
|
||||
|
||||
</Grid>
|
||||
|
||||
@@ -81,7 +81,7 @@ Public Class AlarmsPageUC
|
||||
WjIntCutsTxBl.Text = EgtMsg( 90930) ' Sempre sugli interni
|
||||
NestingParamGpBx.Header = EgtMsg(MSG_ALARMSPAGEUC + 31) ' Nesting
|
||||
AlignTxBl.Text = EgtMsg(90932) ' Allineato
|
||||
GhigliottinaTxBl.Text = EgtMsg(90966) ' Ghigliottina
|
||||
GhigliottinaTxBl.Text = EgtMsg(91066) ' Ghigliottina
|
||||
AutomaticTxBl.Text = EgtMsg(91059) ' Automatico
|
||||
SetUpBtn.Content = EgtMsg(MSG_ALARMSPAGEUC + 33) ' Attrezzaggio
|
||||
NewMatBtn.Content = EgtMsg(MSG_ALARMSPAGEUC + 34) ' Nuovo
|
||||
@@ -100,6 +100,7 @@ Public Class AlarmsPageUC
|
||||
CurrSawingTxBl.Text = EgtMsg(MSG_ALARMS2PAGEUC + 2) ' Taglio lama
|
||||
CurrDrillingTxBl.Text = EgtMsg(MSG_ALARMS2PAGEUC + 3) ' Foratura
|
||||
CurrMillingTxBl.Text = EgtMsg(MSG_ALARMS2PAGEUC + 4) ' Fresatura
|
||||
CurrPocketingTxBl.Text = EgtMsg(91069) ' Svuotatura
|
||||
CurrWaterJettingTxBl.Text = EgtMsg(MSG_ALARMS2PAGEUC + 7) ' WaterJet
|
||||
CurrDripSawingTxBl.Text = EgtMsg(MSG_ALARMS2PAGEUC + 5) ' DripSawing
|
||||
CurrDripDrillingTxBl.Text = EgtMsg(MSG_ALARMS2PAGEUC + 6) ' DripDrilling
|
||||
@@ -118,7 +119,7 @@ Public Class AlarmsPageUC
|
||||
Select Case m_CurrentMachine.MountedToolConfig
|
||||
Case CurrentMachine.MountedToolConfigs.SAW
|
||||
' Elimino le righe inutili e riduco il groupbox utensili correnti
|
||||
For Index = 7 - 1 To 2 Step -1
|
||||
For Index As Integer = 7 - 1 To 2 Step -1
|
||||
CurrToolsGrid.RowDefinitions.RemoveAt(Index)
|
||||
Next
|
||||
Dim EndRow As New RowDefinition
|
||||
@@ -244,6 +245,8 @@ Public Class AlarmsPageUC
|
||||
CurrDrillingTxBx.Visibility = Windows.Visibility.Hidden
|
||||
CurrMillingTxBl.Visibility = Windows.Visibility.Hidden
|
||||
CurrMillingTxBx.Visibility = Windows.Visibility.Hidden
|
||||
CurrPocketingTxBl.Visibility = Windows.Visibility.Hidden
|
||||
CurrpocketingTxBx.Visibility = Windows.Visibility.Hidden
|
||||
CurrWaterJettingTxBl.Visibility = Windows.Visibility.Hidden
|
||||
CurrWaterJettingTxBx.Visibility = Windows.Visibility.Hidden
|
||||
CurrDripSawingTxBl.Visibility = Windows.Visibility.Hidden
|
||||
@@ -266,6 +269,11 @@ Public Class AlarmsPageUC
|
||||
CurrMillingTxBl.Visibility = Windows.Visibility.Visible
|
||||
CurrMillingTxBx.Visibility = Windows.Visibility.Visible
|
||||
End If
|
||||
If m_CurrentMachine.sCurrPocketing <> String.Empty Then
|
||||
CurrPocketingTxBx.Text = m_CurrentMachine.sCurrPocketing
|
||||
CurrPocketingTxBl.Visibility = Windows.Visibility.Visible
|
||||
CurrPocketingTxBx.Visibility = Windows.Visibility.Visible
|
||||
End If
|
||||
If m_CurrentMachine.sCurrwaterJetting <> String.Empty Then
|
||||
CurrWaterJettingTxBx.Text = m_CurrentMachine.sCurrwaterJetting
|
||||
CurrWaterJettingTxBl.Visibility = Windows.Visibility.Visible
|
||||
@@ -353,11 +361,11 @@ Public Class AlarmsPageUC
|
||||
(GetPrivateProfileInt(S_MACH_NEST, K_MACH_NEST_GHIGLIOTTINA, 0, m_MainWindow.GetMachIniFile()) <> 0)
|
||||
' Flag per nesting automatico
|
||||
AutomaticChBx.IsChecked =
|
||||
(GetPrivateProfileInt(S_MACH_NEST, K_MACH_NEST_AUTOMATIC, 0, m_MainWindow.GetMachIniFile()) <> 0)
|
||||
AdjustAlignTextOnAutomaticOrCompleteCuts()
|
||||
(GetPrivateProfileInt(S_NEST, K_AUTOMATICOPTIMIZE, 0, m_MainWindow.GetIniFile()) <> 0)
|
||||
AdjustGhigliottinaTextOnAutomaticOrCompleteCuts()
|
||||
' Flag per inserire la puasa dopo la sgrossatura delle cornici
|
||||
FramePauseChBx.IsChecked =
|
||||
(GetPrivateProfileInt(S_MACH_FRAME, K_MACH_PAUSE, 0, m_MainWindow.GetMachIniFile()) <> 0)
|
||||
(GetPrivateProfileInt(S_MACH_FRAME, K_MACH_PAUSE, 1, m_MainWindow.GetMachIniFile()) <> 0)
|
||||
' Aggiorno messaggio sovratavola con numero tavola
|
||||
If GetTableCount() > 1 Then
|
||||
AdditionalTableTxBl.Text = EgtMsg(MSG_ALARMSPAGEUC + 36) & " " & GetCurrentTable().ToString()
|
||||
@@ -664,7 +672,7 @@ Public Class AlarmsPageUC
|
||||
Else
|
||||
WritePrivateProfileString(S_MACH_NEST, K_MACH_REDUCEDCUT, "1", m_MainWindow.GetMachIniFile())
|
||||
End If
|
||||
AdjustAlignTextOnAutomaticOrCompleteCuts()
|
||||
AdjustGhigliottinaTextOnAutomaticOrCompleteCuts()
|
||||
End Sub
|
||||
|
||||
Private Sub CornerCutsChBx_Click(sender As Object, e As RoutedEventArgs) Handles CornerCutsChBx.Click
|
||||
@@ -743,20 +751,18 @@ Public Class AlarmsPageUC
|
||||
|
||||
Private Sub AutomaticChBx_Click(sender As Object, e As RoutedEventArgs) Handles AutomaticChBx.Click
|
||||
If AutomaticChBx.IsChecked() Then
|
||||
WritePrivateProfileString(S_MACH_NEST, K_MACH_NEST_AUTOMATIC, "1", m_MainWindow.GetMachIniFile())
|
||||
WritePrivateProfileString(S_NEST, K_AUTOMATICOPTIMIZE, "1", m_MainWindow.GetIniFile())
|
||||
Else
|
||||
WritePrivateProfileString(S_MACH_NEST, K_MACH_NEST_AUTOMATIC, "0", m_MainWindow.GetMachIniFile())
|
||||
WritePrivateProfileString(S_NEST, K_AUTOMATICOPTIMIZE, "0", m_MainWindow.GetIniFile())
|
||||
End If
|
||||
AdjustAlignTextOnAutomaticOrCompleteCuts()
|
||||
AdjustGhigliottinaTextOnAutomaticOrCompleteCuts()
|
||||
End Sub
|
||||
|
||||
Private Sub AdjustAlignTextOnAutomaticOrCompleteCuts()
|
||||
Private Sub AdjustGhigliottinaTextOnAutomaticOrCompleteCuts()
|
||||
If AutomaticChBx.IsChecked() And Not CompleteCutsChBx.IsChecked() Then
|
||||
AlignTxBl.Text = EgtMsg(90932) ' Allineato e Ghigliottina - 91060
|
||||
GhigliottinaTxBl.Visibility = Visibility.Visible
|
||||
GhigliottinaChBx.Visibility = Visibility.Visible
|
||||
Else
|
||||
AlignTxBl.Text = EgtMsg(90932) ' Allineato
|
||||
GhigliottinaTxBl.Visibility = Visibility.Collapsed
|
||||
GhigliottinaChBx.Visibility = Visibility.Collapsed
|
||||
End If
|
||||
@@ -780,7 +786,7 @@ Public Class AlarmsPageUC
|
||||
If Not String.IsNullOrWhiteSpace(MatNameTxBx.Text) Then
|
||||
' Verifico che il nome non sia già utilizzato
|
||||
Dim bNameExist As Boolean = False
|
||||
For Each Material In m_CurrentMachine.Materials
|
||||
For Each Material As Material In m_CurrentMachine.Materials
|
||||
If Material.sName = MatNameTxBx.Text Then
|
||||
bNameExist = True
|
||||
Exit For
|
||||
@@ -946,7 +952,7 @@ Public Class AlarmsPageUC
|
||||
m_MainWindow.m_CNCommunication.m_CN.n_DReadELS_handle = 0
|
||||
' Definisco flag tastatura
|
||||
Dim bProbingOk As Boolean = False
|
||||
For I = 0 To 120
|
||||
For I As Integer = 0 To 120
|
||||
' Devo rileggere la variabile ad ogni ciclo
|
||||
m_MainWindow.m_CNCommunication.m_CN.ReadEls_Add_Parameter(ProbingStateNameVar, 3)
|
||||
System.Threading.Thread.Sleep(100)
|
||||
@@ -988,7 +994,7 @@ Public Class AlarmsPageUC
|
||||
Dim SawDiameterNameVar As String = String.Empty
|
||||
GetPrivateProfileString(S_MACH_PROBING, K_SAWDIAMETER, "", SawDiameterNameVar, m_MainWindow.GetMachIniFile())
|
||||
m_MainWindow.m_CNCommunication.m_CN.n_DReadELS_handle = 0
|
||||
For I = 0 To 20
|
||||
For I As Integer = 0 To 20
|
||||
' Devo rileggere la variabile ad ogni ciclo
|
||||
m_MainWindow.m_CNCommunication.m_CN.ReadEls_Add_Parameter(SawDiameterNameVar, 3)
|
||||
System.Threading.Thread.Sleep(100)
|
||||
|
||||
@@ -53,7 +53,7 @@ Public Class ChooseToolWD
|
||||
m_SetUpToolList.Add(New ToolPos(m_MainWindow.m_CurrentMachine.sCurrSaw, sToolPos, True))
|
||||
End If
|
||||
' Recupero tutti gli utensili attrezzati (nel ToolChanger e nel ManualToolChanger)
|
||||
For Each ToolChangerPos In m_MainWindow.m_CurrentMachine.ManualToolChanger
|
||||
For Each ToolChangerPos As ToolChangerPos In m_MainWindow.m_CurrentMachine.ManualToolChanger
|
||||
m_SetUpToolList.Add(New ToolPos(ToolChangerPos.sTool, ToolChangerPos.sName, False))
|
||||
Next
|
||||
Return True
|
||||
@@ -65,12 +65,12 @@ Public Class ChooseToolWD
|
||||
EgtTdbGetCurrToolParam(MCH_TP.TCPOS, sToolPos)
|
||||
m_SetUpToolList.Add(New ToolPos(m_MainWindow.m_CurrentMachine.sCurrSaw, sToolPos, True))
|
||||
End If
|
||||
For Each ToolChangerPos In m_MainWindow.m_CurrentMachine.ToolChanger
|
||||
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))
|
||||
End If
|
||||
Next
|
||||
For Each ToolChangerPos In m_MainWindow.m_CurrentMachine.ManualToolChanger
|
||||
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))
|
||||
End If
|
||||
|
||||
@@ -886,7 +886,7 @@ Public Class CurrentMachine
|
||||
End Property
|
||||
|
||||
Friend Sub AddMaterial(value As Material)
|
||||
For Each Material In Materials
|
||||
For Each Material As Material In Materials
|
||||
If Material.nId = value.nId Then
|
||||
Exit Sub
|
||||
End If
|
||||
@@ -910,7 +910,7 @@ Public Class CurrentMachine
|
||||
End If
|
||||
Next
|
||||
Dim TempMat As Material = Nothing
|
||||
For I = Index To m_MaxIdMat - 1
|
||||
For I As Integer = Index To m_MaxIdMat - 1
|
||||
GetPrivateProfileMaterial(S_MATERIALS, K_MATERIAL & I + 2, TempMat, sMachIniFile)
|
||||
WritePrivateProfileMaterial(S_MATERIALS, K_MATERIAL & I + 1, TempMat, sMachIniFile)
|
||||
Next
|
||||
@@ -946,7 +946,7 @@ Public Class CurrentMachine
|
||||
If SysNotes <> String.Empty Then
|
||||
Dim MachiningMaterials() = SysNotes.Split(";".ToCharArray)
|
||||
SysNotes = String.Empty
|
||||
For Each Material In MachiningMaterials
|
||||
For Each Material As Object In MachiningMaterials
|
||||
Dim Param() As String = Material.Split(",".ToCharArray)
|
||||
If Param(0) <> valueId.ToString Then
|
||||
SysNotes &= Material & ";"
|
||||
@@ -975,7 +975,7 @@ Public Class CurrentMachine
|
||||
' Se stringa vuota
|
||||
If String.IsNullOrWhiteSpace(sMatName) Then Return False
|
||||
' Cerco il nome nella lista dei materiali
|
||||
For Index = 0 To Materials.Count - 1
|
||||
For Index As Integer = 0 To Materials.Count - 1
|
||||
If String.Compare(Materials(Index).sName, sMatName, True) = 0 Then
|
||||
CurrMat = Materials(Index)
|
||||
End If
|
||||
@@ -1155,7 +1155,7 @@ Public Class CurrentMachine
|
||||
m_ManualToolChangerNbr = Math.Min(m_ManualToolChangerNbr, MAX_TCMAN_TOOLS)
|
||||
|
||||
' Leggo da file ini nomi e utensili manuali presenti
|
||||
For Index = 1 To m_ManualToolChangerNbr
|
||||
For Index As Integer = 1 To m_ManualToolChangerNbr
|
||||
Dim sName As String = String.Empty
|
||||
Dim sTool As String = String.Empty
|
||||
GetPrivateProfileString(S_TOOLCHANGER, K_MANUALNAME & Index, Nothing, sName, sMachIniFile)
|
||||
@@ -1330,7 +1330,7 @@ Friend Class Material
|
||||
|
||||
Sub New(sName As String, MaterialList As ObservableCollection(Of Material))
|
||||
Dim nMaxId As Integer = 0
|
||||
For Each Material In MaterialList
|
||||
For Each Material As Material In MaterialList
|
||||
If Material.nId > nMaxId Then
|
||||
nMaxId = Material.nId
|
||||
End If
|
||||
|
||||
@@ -245,7 +245,7 @@ Public Class MachineCNPageUC
|
||||
Friend Sub PowerONChanged(bPowerON As Boolean)
|
||||
' devo decodificare il tipo di pulsante, quindi eseguire la conversione...
|
||||
Dim PowerONButton As TwoStateButton = Nothing
|
||||
For Each MachineButton In m_ButtonPower
|
||||
For Each MachineButton As MachineButton In m_ButtonPower
|
||||
If MachineButton.StateFlag.Trim = K_POWERON Then
|
||||
PowerONButton = MachineButton
|
||||
Exit For
|
||||
@@ -260,7 +260,7 @@ Public Class MachineCNPageUC
|
||||
Friend Sub PowerOFFChanged(bPowerOFF As Boolean)
|
||||
' leggo solo una varibile -> quindi quando modifico lo stato di PowerON devo modificare lo stato di PowerOFF
|
||||
Dim PowerOFFButton As TwoStateButton = Nothing
|
||||
For Each MachineButton In m_ButtonPower
|
||||
For Each MachineButton As MachineButton In m_ButtonPower
|
||||
If MachineButton.StateFlag.Trim = K_POWEROFF Then
|
||||
PowerOFFButton = MachineButton
|
||||
Exit For
|
||||
|
||||
@@ -111,7 +111,7 @@ Public Class MachineStatusUC
|
||||
' modifico uniformgrid
|
||||
AxisUniformGrid.Columns = 1
|
||||
AxisUniformGrid.Rows = m_AxesNumber + 2
|
||||
For Index = 0 To 12 - 1
|
||||
For Index As Integer = 0 To 12 - 1
|
||||
Dim HorizontalGrid As Grid = DirectCast(AxisUniformGrid.Children(Index), Grid)
|
||||
HorizontalGrid.ColumnDefinitions.Clear()
|
||||
HorizontalGrid.RowDefinitions.Clear()
|
||||
@@ -124,7 +124,7 @@ Public Class MachineStatusUC
|
||||
Dim AxisGrid As New RowDefinition
|
||||
AxisGrid.Height = New GridLength(1, GridUnitType.Star)
|
||||
HorizontalGrid.RowDefinitions.Add(AxisGrid)
|
||||
For Each Children In HorizontalGrid.Children
|
||||
For Each Children As UIElement In HorizontalGrid.Children
|
||||
If TypeOf Children Is System.Windows.Controls.Primitives.UniformGrid Then
|
||||
Dim AxisUniformGrid As System.Windows.Controls.Primitives.UniformGrid = DirectCast(Children, System.Windows.Controls.Primitives.UniformGrid)
|
||||
AxisUniformGrid.SetValue(Grid.RowProperty, 1)
|
||||
|
||||
@@ -227,7 +227,7 @@ Public Class MachiningDbPageUC
|
||||
'Funzione che permette l'inizializzazione di albero e parametri all'apertura della pagina ToolsDb
|
||||
Private Sub InitializeFirstSelectedItem()
|
||||
If MachiningsList.Count > 0 Then
|
||||
For Each MachiningFamily In MachiningsList
|
||||
For Each MachiningFamily As CathegoryItem In MachiningsList
|
||||
If MachiningFamily.Items.Count > 0 Then
|
||||
MachiningFamily.IsExpanded = True
|
||||
MachiningFamily.Items(0).IsSelected = True
|
||||
@@ -250,7 +250,7 @@ Public Class MachiningDbPageUC
|
||||
Dim NewName As String = SelectedCathegory.Name
|
||||
EgtMdbGetMachiningNewName(NewName)
|
||||
If EgtMdbAddMachining(NewName, SelectedCathegory.nTType) Then
|
||||
For Each MachiningFamily In MachiningsList
|
||||
For Each MachiningFamily As CathegoryItem In MachiningsList
|
||||
If MachiningFamily.nTType = SelectedCathegory.nTType Then
|
||||
Dim NewMachiningItem As New CustomItem(NewName, SelectedCathegory.nTType)
|
||||
MachiningFamily.Items.Add(NewMachiningItem)
|
||||
@@ -270,7 +270,7 @@ Public Class MachiningDbPageUC
|
||||
If EgtMdbCopyMachining(SelectedCathegory.Name, NewName) Then
|
||||
Dim CurrType As Integer
|
||||
EgtMdbGetCurrMachiningParam(MCH_MP.TYPE, CurrType)
|
||||
For Each MachiningFamily In MachiningsList
|
||||
For Each MachiningFamily As CathegoryItem In MachiningsList
|
||||
If MachiningFamily.nTType = CurrType Then
|
||||
Dim NewMachiningItem As New CustomItem(NewName, CurrType)
|
||||
MachiningFamily.Items.Add(NewMachiningItem)
|
||||
@@ -303,7 +303,7 @@ Public Class MachiningDbPageUC
|
||||
' Cancello la lavorazione
|
||||
EgtMdbRemoveMachining(SelectedItem.Name)
|
||||
' Rimuovo dall'albero
|
||||
For Each MachiningFamily In MachiningsList
|
||||
For Each MachiningFamily As CathegoryItem In MachiningsList
|
||||
If (MachiningFamily.nTType And SelectedItem.nType) <> 0 Then
|
||||
MachiningFamily.Items.Remove(SelectedItem)
|
||||
If MachiningFamily.Items.Count = 0 Then
|
||||
@@ -457,7 +457,7 @@ Public Class MachiningDbPageUC
|
||||
Case MCH_MY.MILLING 'Fresatura
|
||||
ToolCmBx.ItemsSource = MillTool
|
||||
Case MCH_MY.POCKETING 'Svuotatura
|
||||
ToolCmBx.ItemsSource = MillTool
|
||||
ToolCmBx.ItemsSource = PocketTool
|
||||
Case MCH_MY.DRILLING 'Foratura
|
||||
ToolCmBx.ItemsSource = DrillTool
|
||||
Case MCH_MY.SAWROUGHING 'Sgrossatura con lama
|
||||
@@ -472,7 +472,7 @@ Public Class MachiningDbPageUC
|
||||
EgtMdbGetCurrMachiningParam(MCH_MP.TUUID, sTuuid)
|
||||
EgtTdbGetToolFromUUID(sTuuid, ToolString)
|
||||
Dim bToolExist As Boolean = False
|
||||
For Each CurrTool In ToolCmBx.ItemsSource
|
||||
For Each CurrTool As IEnumerable In ToolCmBx.ItemsSource
|
||||
If CurrTool.ToString() = ToolString Then
|
||||
bToolExist = True
|
||||
Exit For
|
||||
@@ -514,14 +514,14 @@ Public Class MachiningDbPageUC
|
||||
RadOffsetTxBx.Text = LenToString(ToolDouble, 3)
|
||||
' Lista materiali
|
||||
m_MaterialsList.Clear()
|
||||
For Each Material In m_MainWindow.m_CurrentMachine.Materials
|
||||
For Each Material As Material In m_MainWindow.m_CurrentMachine.Materials
|
||||
m_MaterialsList.Add(New MachiningMaterial(Material.nId, Material.sName))
|
||||
Next
|
||||
EgtMdbGetCurrMachiningParam(MCH_MP.SYSNOTES, ToolString)
|
||||
If ToolString <> String.Empty Then
|
||||
Dim sItems() = ToolString.Split(";".ToCharArray)
|
||||
Dim Index As Integer = 0
|
||||
For Each Material In m_MaterialsList
|
||||
For Each Material As MachiningMaterial In m_MaterialsList
|
||||
Dim Param() As String = sItems(Index).Split(",".ToCharArray)
|
||||
Dim nParId As Integer = 0
|
||||
If StringToInt(Param(0), nParId) AndAlso nParId = Material.nId Then
|
||||
@@ -606,6 +606,18 @@ Public Class MachiningDbPageUC
|
||||
nTemp = If(AcrossChBx.IsChecked(), MCH_SAWFIN_SUB.ACROSS, MCH_SAWFIN_SUB.ALONG)
|
||||
EgtMdbSetCurrMachiningParam(MCH_MP.SUBTYPE, nTemp)
|
||||
End If
|
||||
' Parmetri nascosti di svuotatura
|
||||
If nMachiningType = MCH_MY.POCKETING Then
|
||||
EgtMdbSetCurrMachiningParam(MCH_MP.SUBTYPE, MCH_POCK_SUB.SPIRALOUT)
|
||||
EgtMdbSetCurrMachiningParam( MCH_MP.LEADINTYPE, MCH_POCK_LI.HELIX)
|
||||
Dim dToolDiam As Double = 100
|
||||
If Not IsNothing(ToolCmBx.SelectedItem) Then
|
||||
EgtTdbSetCurrTool( ToolCmBx.SelectedItem.ToString())
|
||||
EgtTdbGetCurrToolParam( MCH_TP.DIAM, dToolDiam)
|
||||
End If
|
||||
EgtMdbSetCurrMachiningParam( MCH_MP.LITANG, 0.495 * dToolDiam)
|
||||
EgtMdbSetCurrMachiningParam( MCH_MP.LIELEV, 2.0)
|
||||
End If
|
||||
' Parametri WaterJetting
|
||||
StringToDouble(ForwardAngleTxBx.Text, dTemp)
|
||||
EgtMdbSetCurrMachiningParam(MCH_MP.FORWARDANGLE, dTemp)
|
||||
@@ -671,7 +683,7 @@ Public Class MachiningDbPageUC
|
||||
EgtMdbSetCurrMachiningParam(MCH_MP.OFFSR, dTemp)
|
||||
' Scrivo stringa materiali da lista
|
||||
Dim sMaterialString As String = String.Empty
|
||||
For Each Material In m_MaterialsList
|
||||
For Each Material As MachiningMaterial In m_MaterialsList
|
||||
If Material.bIsActive Then
|
||||
sMaterialString += Material.nId.ToString & "," & DoubleToString(Material.dMinThickness, 0) & "," & DoubleToString(Material.dMaxThickness, 0) & ";"
|
||||
End If
|
||||
@@ -712,7 +724,7 @@ Public Class MachiningDbPageUC
|
||||
' Definizione della grid TypeGrd con la giusta altezza e numero di righe
|
||||
Dim RowNum As Integer = TypeGrd.RowDefinitions.Count
|
||||
If RowNum > 2 Then
|
||||
For Index = RowNum - 1 To 2 Step -1
|
||||
For Index As Integer = RowNum - 1 To 2 Step -1
|
||||
TypeGrd.RowDefinitions.RemoveAt(Index)
|
||||
Next
|
||||
LeadInTypeTxBl.SetValue(Grid.ColumnProperty, 2)
|
||||
@@ -800,7 +812,7 @@ Public Class MachiningDbPageUC
|
||||
' Definizione di una riga della tabella con la giusta altezza
|
||||
RowNum = FeedGrd.RowDefinitions.Count
|
||||
If RowNum > 4 Then
|
||||
For Index = RowNum - 1 To 4 Step -1
|
||||
For Index As Integer = RowNum - 1 To 4 Step -1
|
||||
FeedGrd.RowDefinitions.RemoveAt(Index)
|
||||
Next
|
||||
End If
|
||||
@@ -809,7 +821,7 @@ Public Class MachiningDbPageUC
|
||||
' Definizione di una riga della tabella Feed
|
||||
RowNum = FeedGrd.RowDefinitions.Count
|
||||
If RowNum < 6 Then
|
||||
For Index = RowNum To 5
|
||||
For Index As Integer = RowNum To 5
|
||||
Dim Row As New RowDefinition
|
||||
Row.Height = New GridLength(1, GridUnitType.Star)
|
||||
FeedGrd.RowDefinitions.Add(Row)
|
||||
@@ -891,7 +903,7 @@ Public Class MachiningDbPageUC
|
||||
' Definizione della grid TypeGrd con la giusta altezza e numero di righe
|
||||
Dim RowNum As Integer = TypeGrd.RowDefinitions.Count
|
||||
If RowNum > 2 Then
|
||||
For Index = RowNum - 1 To 2 Step -1
|
||||
For Index As Integer = RowNum - 1 To 2 Step -1
|
||||
TypeGrd.RowDefinitions.RemoveAt(Index)
|
||||
Next
|
||||
LeadInTypeTxBl.SetValue(Grid.ColumnProperty, 2)
|
||||
@@ -974,7 +986,7 @@ Public Class MachiningDbPageUC
|
||||
' Definizione di una riga della tabella con la giusta altezza
|
||||
RowNum = FeedGrd.RowDefinitions.Count
|
||||
If RowNum > 4 Then
|
||||
For Index = RowNum - 1 To 4 Step -1
|
||||
For Index As Integer = RowNum - 1 To 4 Step -1
|
||||
FeedGrd.RowDefinitions.RemoveAt(Index)
|
||||
Next
|
||||
End If
|
||||
@@ -983,7 +995,7 @@ Public Class MachiningDbPageUC
|
||||
' Definizione di una riga della tabella Feed
|
||||
RowNum = FeedGrd.RowDefinitions.Count
|
||||
If RowNum < 4 Then
|
||||
For Index = RowNum To 3
|
||||
For Index As Integer = RowNum To 3
|
||||
Dim Row As New RowDefinition
|
||||
Row.Height = New GridLength(1, GridUnitType.Star)
|
||||
FeedGrd.RowDefinitions.Add(Row)
|
||||
@@ -1096,7 +1108,7 @@ Public Class MachiningDbPageUC
|
||||
' Definizione di una riga della tabella con la giusta altezza
|
||||
Dim RowNum As Integer = FeedGrd.RowDefinitions.Count
|
||||
If RowNum > 4 Then
|
||||
For Index = RowNum - 1 To 4 Step -1
|
||||
For Index As Integer = RowNum - 1 To 4 Step -1
|
||||
FeedGrd.RowDefinitions.RemoveAt(Index)
|
||||
Next
|
||||
End If
|
||||
@@ -1105,7 +1117,7 @@ Public Class MachiningDbPageUC
|
||||
' Definizione di una riga della tabella Feed
|
||||
RowNum = FeedGrd.RowDefinitions.Count
|
||||
If RowNum < 4 Then
|
||||
For Index = RowNum To 3
|
||||
For Index As Integer = RowNum To 3
|
||||
Dim Row As New RowDefinition
|
||||
Row.Height = New GridLength(1, GridUnitType.Star)
|
||||
FeedGrd.RowDefinitions.Add(Row)
|
||||
@@ -1185,7 +1197,7 @@ Public Class MachiningDbPageUC
|
||||
' Definizione della grid TypeGrd con la giusta altezza e numero di righe
|
||||
Dim RowNum As Integer = TypeGrd.RowDefinitions.Count
|
||||
If RowNum > 2 Then
|
||||
For Index = RowNum - 1 To 2 Step -1
|
||||
For Index As Integer = RowNum - 1 To 2 Step -1
|
||||
TypeGrd.RowDefinitions.RemoveAt(Index)
|
||||
Next
|
||||
LeadInTypeTxBl.SetValue(Grid.ColumnProperty, 2)
|
||||
@@ -1253,7 +1265,7 @@ Public Class MachiningDbPageUC
|
||||
' Definizione di una riga della tabella con la giusta altezza
|
||||
RowNum = FeedGrd.RowDefinitions.Count
|
||||
If RowNum > 4 Then
|
||||
For Index = RowNum - 1 To 4 Step -1
|
||||
For Index As Integer = RowNum - 1 To 4 Step -1
|
||||
FeedGrd.RowDefinitions.RemoveAt(Index)
|
||||
Next
|
||||
End If
|
||||
@@ -1262,7 +1274,7 @@ Public Class MachiningDbPageUC
|
||||
' Definizione di una riga della tabella Feed
|
||||
RowNum = FeedGrd.RowDefinitions.Count
|
||||
If RowNum < 4 Then
|
||||
For Index = RowNum To 3
|
||||
For Index As Integer = RowNum To 3
|
||||
Dim Row As New RowDefinition
|
||||
Row.Height = New GridLength(1, GridUnitType.Star)
|
||||
FeedGrd.RowDefinitions.Add(Row)
|
||||
@@ -1355,7 +1367,7 @@ Public Class MachiningDbPageUC
|
||||
' Definizione della grid TypeGrd con la giusta altezza e numero di righe
|
||||
Dim RowNum As Integer = TypeGrd.RowDefinitions.Count
|
||||
If RowNum > 2 Then
|
||||
For Index = RowNum - 1 To 2 Step -1
|
||||
For Index As Integer = RowNum - 1 To 2 Step -1
|
||||
TypeGrd.RowDefinitions.RemoveAt(Index)
|
||||
Next
|
||||
LeadInTypeTxBl.SetValue(Grid.ColumnProperty, 2)
|
||||
@@ -1423,7 +1435,7 @@ Public Class MachiningDbPageUC
|
||||
' Definizione di una riga della tabella con la giusta altezza
|
||||
RowNum = FeedGrd.RowDefinitions.Count
|
||||
If RowNum > 4 Then
|
||||
For Index = RowNum - 1 To 4 Step -1
|
||||
For Index As Integer = RowNum - 1 To 4 Step -1
|
||||
FeedGrd.RowDefinitions.RemoveAt(Index)
|
||||
Next
|
||||
End If
|
||||
@@ -1432,7 +1444,7 @@ Public Class MachiningDbPageUC
|
||||
' Definizione di una riga della tabella Feed
|
||||
RowNum = FeedGrd.RowDefinitions.Count
|
||||
If RowNum < 5 Then
|
||||
For Index = RowNum To 4
|
||||
For Index As Integer = RowNum To 4
|
||||
Dim Row As New RowDefinition
|
||||
Row.Height = New GridLength(1, GridUnitType.Star)
|
||||
FeedGrd.RowDefinitions.Add(Row)
|
||||
@@ -1461,7 +1473,7 @@ Public Class MachiningDbPageUC
|
||||
' Eliminazione di una riga della tabella Offset
|
||||
RowNum = OffsetGrd.RowDefinitions.Count
|
||||
If RowNum > 1 Then
|
||||
For Index = RowNum - 1 To 1 Step -1
|
||||
For Index As Integer = RowNum - 1 To 1 Step -1
|
||||
OffsetGrd.RowDefinitions.RemoveAt(Index)
|
||||
OffsetGpBx.SetValue(Grid.RowSpanProperty, 4)
|
||||
Next
|
||||
@@ -1513,15 +1525,15 @@ Public Class MachiningDbPageUC
|
||||
StepTypeCmBx.Visibility = Windows.Visibility.Hidden
|
||||
SideBrd.SetValue(Grid.RowProperty, 9)
|
||||
SideBrd.Visibility = Windows.Visibility.Visible
|
||||
WorkSideTxBl.Visibility = Windows.Visibility.Visible
|
||||
WorkSideCmBx.Visibility = Windows.Visibility.Visible
|
||||
WorkSideTxBl.Visibility = Windows.Visibility.Hidden
|
||||
WorkSideCmBx.Visibility = Windows.Visibility.Hidden
|
||||
HeadSideTxBl.Visibility = Windows.Visibility.Hidden
|
||||
HeadSideCmBx.Visibility = Windows.Visibility.Hidden
|
||||
TypeBrd.Visibility = Windows.Visibility.Visible
|
||||
' Definizione della grid TypeGrd con la giusta altezza e numero di righe
|
||||
Dim RowNum As Integer = TypeGrd.RowDefinitions.Count
|
||||
If RowNum > 2 Then
|
||||
For Index = RowNum - 1 To 2 Step -1
|
||||
For Index As Integer = RowNum - 1 To 2 Step -1
|
||||
TypeGrd.RowDefinitions.RemoveAt(Index)
|
||||
Next
|
||||
LeadInTypeTxBl.SetValue(Grid.ColumnProperty, 2)
|
||||
@@ -1584,27 +1596,30 @@ Public Class MachiningDbPageUC
|
||||
BackwardStepSideAngTxBl.Visibility = Windows.Visibility.Hidden
|
||||
BackwardStepSideAngTxBx.Visibility = Windows.Visibility.Hidden
|
||||
ForwardSawStepTxBl.Text = EgtMsg(MSG_MACHININGSDBPAGEUC + 15)
|
||||
If SawStepGrd.Children.Contains(ArcIntTxBl) Then
|
||||
SawStepGrd.Children.Remove(ArcIntTxBl)
|
||||
SawStepGrd.Children.Remove(ArcIntTxBx)
|
||||
SawStepGrd.Children.Remove(ArcExtTxBl)
|
||||
SawStepGrd.Children.Remove(ArcExtTxBx)
|
||||
SawStepGrd.RowDefinitions.RemoveAt(2)
|
||||
End If
|
||||
If SawStepGrd.Children.Contains(LastSawStepTxBl) Then
|
||||
SawStepGrd.Children.Remove(LastSawStepTxBl)
|
||||
SawStepGrd.Children.Remove(LastSawStepTxBx)
|
||||
SawStepGrd.RowDefinitions.RemoveAt(2)
|
||||
If DrillStepGrd.Children.Contains(StepTxBx) Then
|
||||
DrillStepGrd.Children.Remove(StepTxBx)
|
||||
SawRouStepGrd.Children.Add(StepTxBx)
|
||||
StepTxBx.SetValue(Grid.ColumnProperty, 1)
|
||||
StepTxBx.SetValue(Grid.RowProperty, 0)
|
||||
StepTxBx.Style = Application.Current.FindResource("OmagCut_CalculatorTextBoxInGroupBox")
|
||||
ElseIf SawStepGrd.Children.Contains(StepTxBx) Then
|
||||
SawStepGrd.Children.Remove(StepTxBx)
|
||||
SawRouStepGrd.Children.Add(StepTxBx)
|
||||
StepTxBx.SetValue(Grid.ColumnProperty, 1)
|
||||
StepTxBx.SetValue(Grid.RowProperty, 0)
|
||||
StepTxBx.Style = Application.Current.FindResource("OmagCut_CalculatorTextBoxInGroupBox")
|
||||
End If
|
||||
DrillStepBrd.Visibility = Windows.Visibility.Hidden
|
||||
SawRouStepGpBx.Visibility = Windows.Visibility.Hidden
|
||||
SawStepGpBx.Visibility = Windows.Visibility.Hidden
|
||||
SawRouStepGpBx.Visibility = Windows.Visibility.Visible
|
||||
SawRouStepTxBl.Visibility = Windows.Visibility.Visible
|
||||
ReturnPosTxBl.Visibility = Windows.Visibility.Hidden
|
||||
ReturnPosTxBx.Visibility = Windows.Visibility.Hidden
|
||||
OffsetGpBx.Visibility = Windows.Visibility.Hidden
|
||||
' Definizione di una riga della tabella con la giusta altezza
|
||||
RowNum = FeedGrd.RowDefinitions.Count
|
||||
If RowNum > 4 Then
|
||||
For Index = RowNum - 1 To 4 Step -1
|
||||
For Index As Integer = RowNum - 1 To 4 Step -1
|
||||
FeedGrd.RowDefinitions.RemoveAt(Index)
|
||||
Next
|
||||
End If
|
||||
@@ -1613,7 +1628,7 @@ Public Class MachiningDbPageUC
|
||||
' Definizione di una riga della tabella Feed
|
||||
RowNum = FeedGrd.RowDefinitions.Count
|
||||
If RowNum < 4 Then
|
||||
For Index = RowNum To 3
|
||||
For Index As Integer = RowNum To 3
|
||||
Dim Row As New RowDefinition
|
||||
Row.Height = New GridLength(1, GridUnitType.Star)
|
||||
FeedGrd.RowDefinitions.Add(Row)
|
||||
@@ -1693,7 +1708,7 @@ Public Class MachiningDbPageUC
|
||||
' Definizione della grid TypeGrd con la giusta altezza e numero di righe
|
||||
Dim RowNum As Integer = TypeGrd.RowDefinitions.Count
|
||||
If RowNum < 3 Then
|
||||
For Index = RowNum To 2
|
||||
For Index As Integer = RowNum To 2
|
||||
Dim Row As New RowDefinition
|
||||
Row.Height = New GridLength(1, GridUnitType.Star)
|
||||
' Row.SetValue(Grid.RowSpanProperty, 3)
|
||||
@@ -1782,7 +1797,7 @@ Public Class MachiningDbPageUC
|
||||
' Definizione di una riga della tabella con la giusta altezza
|
||||
RowNum = FeedGrd.RowDefinitions.Count
|
||||
If RowNum > 3 Then
|
||||
For Index = RowNum - 1 To 3 Step -1
|
||||
For Index As Integer = RowNum - 1 To 3 Step -1
|
||||
FeedGrd.RowDefinitions.RemoveAt(Index)
|
||||
Next
|
||||
End If
|
||||
@@ -1794,7 +1809,7 @@ Public Class MachiningDbPageUC
|
||||
' Eliminazione di una riga della tabella Offset
|
||||
RowNum = OffsetGrd.RowDefinitions.Count
|
||||
If RowNum > 1 Then
|
||||
For Index = RowNum - 1 To 1 Step -1
|
||||
For Index As Integer = RowNum - 1 To 1 Step -1
|
||||
OffsetGrd.RowDefinitions.RemoveAt(Index)
|
||||
OffsetGpBx.SetValue(Grid.RowSpanProperty, 4)
|
||||
Next
|
||||
@@ -2145,7 +2160,7 @@ Public Structure IdNameStruct
|
||||
End Function
|
||||
|
||||
Friend Shared Function IndFromId(Id As Integer, List As ObservableCollection(Of IdNameStruct)) As Integer
|
||||
For i = 0 To List.Count - 1
|
||||
For i As Integer = 0 To List.Count - 1
|
||||
If List(i).Id = Id Then Return i
|
||||
Next
|
||||
Return 0
|
||||
|
||||
@@ -113,12 +113,12 @@ Public Class PolishingsPageUC
|
||||
|
||||
' Recupero nome utensile tramite UUID
|
||||
Dim ToolString As String = String.Empty
|
||||
For Each KitItem In m_KitList
|
||||
For Each KitMachItem In KitItem.KitMachList
|
||||
For Each KitItem As Kit In m_KitList
|
||||
For Each KitMachItem As KitMach In KitItem.KitMachList
|
||||
Dim selToolIndex As Integer = 0
|
||||
EgtTdbGetToolFromUUID(KitMachItem.sToolUUID, ToolString)
|
||||
Dim bToolExist As Boolean = False
|
||||
For Each CurrTool In ToolList
|
||||
For Each CurrTool As String In ToolList
|
||||
If CurrTool.ToString() = ToolString Then
|
||||
bToolExist = True
|
||||
Exit For
|
||||
@@ -177,7 +177,7 @@ Public Class PolishingsPageUC
|
||||
If Not String.IsNullOrWhiteSpace( KitNameTxBx.Text) Then
|
||||
' Verifico che il nome non sia già utilizzato
|
||||
Dim bNameExist As Boolean = False
|
||||
For Each Kit In m_KitList
|
||||
For Each Kit As Kit In m_KitList
|
||||
If Kit.sName = KitNameTxBx.Text Then
|
||||
bNameExist = True
|
||||
Exit For
|
||||
@@ -448,7 +448,7 @@ Public Class PolishingsPageUC
|
||||
If Not IsNothing(m_OldItem) Then
|
||||
Dim nKitIndex As Integer = m_OldItem.nId
|
||||
If nKitIndex <= m_KitList.Count Then
|
||||
For Each KitMachItem In m_KitList(nKitIndex - 1).KitMachList
|
||||
For Each KitMachItem As KitMach In m_KitList(nKitIndex - 1).KitMachList
|
||||
If KitMachItem.m_IsModifiedId OrElse KitMachItem.m_IsModifiedToolUUID OrElse KitMachItem.m_IsModifiedToolName OrElse KitMachItem.m_IsModifiedSelTool OrElse
|
||||
KitMachItem.m_IsModifiedActive OrElse KitMachItem.m_IsModifiedContour OrElse KitMachItem.m_IsModifiedOffCnt OrElse KitMachItem.m_IsModifiedZigZagX OrElse
|
||||
KitMachItem.m_IsModifiedOffZigZagX OrElse KitMachItem.m_IsModifiedZigZagY OrElse KitMachItem.m_IsModifiedStepX OrElse KitMachItem.m_IsModifiedStepY OrElse
|
||||
@@ -466,7 +466,7 @@ Public Class PolishingsPageUC
|
||||
If IsNothing( m_OldItem) Then Return
|
||||
Dim nKitIndex As Integer = m_OldItem.nId
|
||||
If nKitIndex <= m_KitList.Count Then
|
||||
For Each KitMachItem In m_KitList(nKitIndex - 1).KitMachList
|
||||
For Each KitMachItem As KitMach In m_KitList(nKitIndex - 1).KitMachList
|
||||
KitMachItem.m_IsModifiedId = False
|
||||
KitMachItem.m_IsModifiedToolUUID = False
|
||||
KitMachItem.m_IsModifiedToolName = False
|
||||
@@ -911,7 +911,7 @@ Class KitMach
|
||||
m_sToolName = sToolNameDummy
|
||||
End If
|
||||
|
||||
For Each sToolUuidItem In m_MainWindow.m_MachinePageUC.m_PolishingsPageUC.ToolUuidList
|
||||
For Each sToolUuidItem As String In m_MainWindow.m_MachinePageUC.m_PolishingsPageUC.ToolUuidList
|
||||
EgtTdbGetToolFromUUID(sToolUuidItem, sToolNameDummy)
|
||||
If sToolNameDummy.Equals(m_sToolName) Then
|
||||
m_sToolUUID = sToolUuidItem
|
||||
|
||||
+21
-21
@@ -34,8 +34,8 @@ Public Class SetUpPage
|
||||
EgtOutLog("TC warning : too many tools (max 12 * 5)")
|
||||
ColNum = 12
|
||||
End If
|
||||
For Index = 12 To ColNum + 1 Step -1
|
||||
For Index2 = Index * 5 To (Index - 1) * 5 + 1 Step -1
|
||||
For Index As Integer = 12 To ColNum + 1 Step -1
|
||||
For Index2 As Integer = Index * 5 To (Index - 1) * 5 + 1 Step -1
|
||||
TlChGrid.Children.Remove(GetTlChPosFromIndex(Index2))
|
||||
TlChGrid.Children.Remove(GetTxBxFromIndex(Index2))
|
||||
Next
|
||||
@@ -43,14 +43,14 @@ Public Class SetUpPage
|
||||
TlChGrid.ColumnDefinitions.RemoveAt(Index * 2 - 2)
|
||||
Next
|
||||
' Modifico il numero di elementi presenti sull'ultima colonna
|
||||
For Index = ColNum * 5 To m_CurrMachine.ToolChangerNbr + 1 Step -1
|
||||
For Index As Integer = ColNum * 5 To m_CurrMachine.ToolChangerNbr + 1 Step -1
|
||||
TlChGrid.Children.Remove(GetTlChPosFromIndex(Index))
|
||||
TlChGrid.Children.Remove(GetTxBxFromIndex(Index))
|
||||
Next
|
||||
' Assegno lunghezza alla scrollviewer
|
||||
TlChGrid.Width = m_MainWindow.ActualWidth / 15 * 1.6 * ColNum * 2
|
||||
' Carico i nomi dei portautensili
|
||||
For Index = 1 To m_CurrMachine.ToolChangerNbr
|
||||
For Index As Integer = 1 To m_CurrMachine.ToolChangerNbr
|
||||
GetTlChPosFromIndex(Index).PositionNameTxBl.Text = m_CurrMachine.ToolChangerName(Index - 1)
|
||||
Next
|
||||
Else
|
||||
@@ -64,8 +64,8 @@ Public Class SetUpPage
|
||||
EgtOutLog("ManTC warning : too many tools (max 12 * 5)")
|
||||
ManColNum = 12
|
||||
End If
|
||||
For Index = 12 To ManColNum + 1 Step -1
|
||||
For Index2 = Index * 5 To (Index - 1) * 5 + 1 Step -1
|
||||
For Index As Integer = 12 To ManColNum + 1 Step -1
|
||||
For Index2 As Integer = Index * 5 To (Index - 1) * 5 + 1 Step -1
|
||||
ManTlChGrid.Children.Remove(GetManTlChPosFromIndex(Index2))
|
||||
ManTlChGrid.Children.Remove(GetManTxBxFromIndex(Index2))
|
||||
Next
|
||||
@@ -73,14 +73,14 @@ Public Class SetUpPage
|
||||
ManTlChGrid.ColumnDefinitions.RemoveAt(Index * 2 - 2)
|
||||
Next
|
||||
' Modifico il numero di elementi presenti sull'ultima colonna
|
||||
For Index = ManColNum * 5 To m_CurrMachine.ManualToolChangerNbr + 1 Step -1
|
||||
For Index As Integer = ManColNum * 5 To m_CurrMachine.ManualToolChangerNbr + 1 Step -1
|
||||
ManTlChGrid.Children.Remove(GetManTlChPosFromIndex(Index))
|
||||
ManTlChGrid.Children.Remove(GetManTxBxFromIndex(Index))
|
||||
Next
|
||||
' Assegno lunghezza alla scrollviewer
|
||||
ManTlChGrid.Width = m_MainWindow.ActualWidth / 15 * 1.6 * ManColNum * 2
|
||||
' Carico i nomi dei portautensili
|
||||
For Index = 1 To m_CurrMachine.ManualToolChangerNbr
|
||||
For Index As Integer = 1 To m_CurrMachine.ManualToolChangerNbr
|
||||
GetManTlChPosFromIndex(Index).PositionNameTxBl.Text = m_CurrMachine.ManualToolChangerName(Index - 1)
|
||||
Next
|
||||
|
||||
@@ -112,10 +112,10 @@ Public Class SetUpPage
|
||||
InitializeToolGroup( m_CurrMachine.bPolishingWheel, MCH_TY.MILL_POLISHING, EgtMsg( 90756), m_PolishingsList)
|
||||
|
||||
' Posiziono utensili già posizionati sul portautensili
|
||||
For Each ToolPosition In m_CurrMachine.ToolChanger
|
||||
For Each ToolPosition As ToolChangerPos In m_CurrMachine.ToolChanger
|
||||
If ToolPosition.sTool <> String.Empty Then
|
||||
If Not IsNothing( m_DrillbitsList) Then
|
||||
For Each Item In m_DrillbitsList.Items
|
||||
For Each Item As CustomItem In m_DrillbitsList.Items
|
||||
If Item.Name = ToolPosition.sTool Then
|
||||
m_SetUpToolsList.Items.Add(Item)
|
||||
m_DrillbitsList.Items.Remove(Item)
|
||||
@@ -124,7 +124,7 @@ Public Class SetUpPage
|
||||
Next
|
||||
End If
|
||||
If Not IsNothing( m_MillsList) Then
|
||||
For Each Item In m_MillsList.Items
|
||||
For Each Item As CustomItem In m_MillsList.Items
|
||||
If Item.Name = ToolPosition.sTool Then
|
||||
m_SetUpToolsList.Items.Add(Item)
|
||||
m_MillsList.Items.Remove(Item)
|
||||
@@ -133,7 +133,7 @@ Public Class SetUpPage
|
||||
Next
|
||||
End If
|
||||
If Not IsNothing( m_CupsList) Then
|
||||
For Each Item In m_CupsList.Items
|
||||
For Each Item As CustomItem In m_CupsList.Items
|
||||
If Item.Name = ToolPosition.sTool Then
|
||||
m_SetUpToolsList.Items.Add(Item)
|
||||
m_CupsList.Items.Remove(Item)
|
||||
@@ -142,7 +142,7 @@ Public Class SetUpPage
|
||||
Next
|
||||
End If
|
||||
If Not IsNothing( m_PolishingsList) Then
|
||||
For Each Item In m_PolishingsList.Items
|
||||
For Each Item As CustomItem In m_PolishingsList.Items
|
||||
If Item.Name = ToolPosition.sTool Then
|
||||
m_SetUpToolsList.Items.Add(Item)
|
||||
m_PolishingsList.Items.Remove(Item)
|
||||
@@ -156,10 +156,10 @@ Public Class SetUpPage
|
||||
Next
|
||||
|
||||
' Posiziono utensili già posizionati sul portautensili manuale
|
||||
For Each ToolPosition In m_CurrMachine.ManualToolChanger
|
||||
For Each ToolPosition As ToolChangerPos In m_CurrMachine.ManualToolChanger
|
||||
If ToolPosition.sTool <> String.Empty Then
|
||||
If Not IsNothing( m_DrillbitsList) Then
|
||||
For Each Item In m_DrillbitsList.Items
|
||||
For Each Item As CustomItem In m_DrillbitsList.Items
|
||||
If Item.Name = ToolPosition.sTool Then
|
||||
m_SetUpToolsList.Items.Add(Item)
|
||||
m_DrillbitsList.Items.Remove(Item)
|
||||
@@ -168,7 +168,7 @@ Public Class SetUpPage
|
||||
Next
|
||||
End If
|
||||
If Not IsNothing( m_MillsList) Then
|
||||
For Each Item In m_MillsList.Items
|
||||
For Each Item As CustomItem In m_MillsList.Items
|
||||
If Item.Name = ToolPosition.sTool Then
|
||||
m_SetUpToolsList.Items.Add(Item)
|
||||
m_MillsList.Items.Remove(Item)
|
||||
@@ -177,7 +177,7 @@ Public Class SetUpPage
|
||||
Next
|
||||
End If
|
||||
If Not IsNothing( m_CupsList) Then
|
||||
For Each Item In m_CupsList.Items
|
||||
For Each Item As CustomItem In m_CupsList.Items
|
||||
If Item.Name = ToolPosition.sTool Then
|
||||
m_SetUpToolsList.Items.Add(Item)
|
||||
m_CupsList.Items.Remove(Item)
|
||||
@@ -186,7 +186,7 @@ Public Class SetUpPage
|
||||
Next
|
||||
End If
|
||||
If Not IsNothing( m_PolishingsList) Then
|
||||
For Each Item In m_PolishingsList.Items
|
||||
For Each Item As CustomItem In m_PolishingsList.Items
|
||||
If Item.Name = ToolPosition.sTool Then
|
||||
m_SetUpToolsList.Items.Add(Item)
|
||||
m_PolishingsList.Items.Remove(Item)
|
||||
@@ -784,7 +784,7 @@ Public Class SetUpPage
|
||||
|
||||
' Funzione che rimette un utensile nell'albero
|
||||
Private Sub RestoreToolInList(sToolName As String)
|
||||
For Each Tool In m_SetUpToolsList.Items
|
||||
For Each Tool As CustomItem In m_SetUpToolsList.Items
|
||||
If Tool.Name = sToolName Then
|
||||
If Tool.nType = MCH_TY.DRILL_STD Then
|
||||
m_DrillbitsList.Items.Add(Tool)
|
||||
@@ -1119,7 +1119,7 @@ Public Class SetUpPage
|
||||
EgtTdbGetCurrToolParam(MCH_TP.TCPOS, ToolPositionName)
|
||||
If String.IsNullOrEmpty(ToolPositionName) Then Return
|
||||
' Cerco il portautensile nella lista degli automatici per vederne lo stato
|
||||
For Each TlChPos In m_CurrMachine.ToolChanger
|
||||
For Each TlChPos As ToolChangerPos In m_CurrMachine.ToolChanger
|
||||
If TlChPos.sName = ToolPositionName Then
|
||||
' Se la posizione è libera
|
||||
If GetTxBxFromIndex(TlChPos.nPosition).Text = String.Empty Then
|
||||
@@ -1137,7 +1137,7 @@ Public Class SetUpPage
|
||||
End If
|
||||
Next
|
||||
' Cerco il portautensile nella lista dei manuali per vederne lo stato
|
||||
For Each ManTlChPos In m_CurrMachine.ManualToolChanger
|
||||
For Each ManTlChPos As ToolChangerPos In m_CurrMachine.ManualToolChanger
|
||||
If ManTlChPos.sName = ToolPositionName Then
|
||||
' Se la posizione è libera
|
||||
If GetManTxBxFromIndex(ManTlChPos.nPosition).Text = String.Empty Then
|
||||
|
||||
@@ -182,7 +182,7 @@ Public Class ToolsDbPageUC
|
||||
'Funzione che permette l'inizializzazione di albero e parametri all'apertura della pagina ToolsDb
|
||||
Private Sub InitializeFirstSelectedItem()
|
||||
If ToolsList.Count > 0 Then
|
||||
For Each ToolFamily In ToolsList
|
||||
For Each ToolFamily As CathegoryItem In ToolsList
|
||||
If ToolFamily.Items.Count > 0 Then
|
||||
ToolFamily.IsExpanded = True
|
||||
ToolFamily.Items(0).IsSelected = True
|
||||
@@ -227,7 +227,7 @@ Public Class ToolsDbPageUC
|
||||
Dim NewName As String = SelectedCathegory.Name
|
||||
EgtTdbGetToolNewName(NewName)
|
||||
If EgtTdbAddTool(NewName, SelectedCathegory.nTType) Then
|
||||
For Each ToolFamily In ToolsList
|
||||
For Each ToolFamily As CathegoryItem In ToolsList
|
||||
If ToolFamily.nTType = SelectedCathegory.nTType Then
|
||||
Dim NewToolItem As New CustomItem(NewName, SelectedCathegory.nTType)
|
||||
ToolFamily.Items.Add(NewToolItem)
|
||||
@@ -315,7 +315,7 @@ Public Class ToolsDbPageUC
|
||||
' Aggiorno lista utensili
|
||||
Dim CurrType As Integer
|
||||
EgtTdbGetCurrToolParam(MCH_TP.TYPE, CurrType)
|
||||
For Each ToolFamily In ToolsList
|
||||
For Each ToolFamily As CathegoryItem In ToolsList
|
||||
If ToolFamily.nTType = CurrType Then
|
||||
Dim NewToolItem As New CustomItem( NewName, CurrType)
|
||||
ToolFamily.Items.Add( NewToolItem)
|
||||
@@ -459,7 +459,7 @@ Public Class ToolsDbPageUC
|
||||
' Cancello l'utensile
|
||||
EgtTdbRemoveTool(SelectedItem.Name)
|
||||
' Rimuovo il nome dell'albero
|
||||
For Each ToolFamily In ToolsList
|
||||
For Each ToolFamily As CathegoryItem In ToolsList
|
||||
If (ToolFamily.nTType And SelectedItem.nType) <> 0 Then
|
||||
ToolFamily.Items.Remove(SelectedItem)
|
||||
If ToolFamily.Items.Count = 0 Then
|
||||
|
||||
Reference in New Issue
Block a user