|
|
|
@@ -526,6 +526,12 @@ Friend Module DdfFile
|
|
|
|
|
If Not Directory.Exists(Path.GetDirectoryName(sPath)) Then
|
|
|
|
|
Directory.CreateDirectory(Path.GetDirectoryName(sPath))
|
|
|
|
|
End If
|
|
|
|
|
|
|
|
|
|
If OptionModule.m_sVersionDDF = "2" Then
|
|
|
|
|
DdfFileContent.Add(ConstCompo.K_OPTIONS & ": ")
|
|
|
|
|
DdfFileContent.Add(Part.sOptions)
|
|
|
|
|
End If
|
|
|
|
|
|
|
|
|
|
DdfFileContent.Add(" ")
|
|
|
|
|
DdfFileContent.Add("# End Part")
|
|
|
|
|
' se sono arrivato fin qui significa che tutto è andato a buon fine (posso quindisalvare il file corrente)
|
|
|
|
@@ -564,6 +570,7 @@ Friend Module DdfFile
|
|
|
|
|
End If
|
|
|
|
|
' dal 20/04/2023 inserita gestione della versione (da configurare nel programma)
|
|
|
|
|
If OptionModule.m_sVersionDDF <> "1" Then
|
|
|
|
|
DdfFileContent.Add("")
|
|
|
|
|
DdfFileContent.Add("version: " & OptionModule.m_sVersionDDF)
|
|
|
|
|
End If
|
|
|
|
|
DdfFileContent.Add("")
|
|
|
|
@@ -698,7 +705,12 @@ Friend Module DdfFile
|
|
|
|
|
End If
|
|
|
|
|
'----------------------------------------------------------------------------------------------------------------------------------------------------
|
|
|
|
|
DdfFileContent.Add("" & ConstCompo.S_PROFILES & ":")
|
|
|
|
|
DdfFileContent.Add(m_sSpace1Tab & ConstCompo.K_LOCKEDGE & ": " & SetBevel(Part.TypePart, Part.LockEdgeType.Name, Part.DispositionItem.Name, Part.SwingAlias.Name, Part.InvertBevel))
|
|
|
|
|
If OptionModule.m_sVersionDDF = "2" Then ' K_TYPE
|
|
|
|
|
DdfFileContent.Add(m_sSpace1Tab & ConstCompo.K_LOCKEDGE & ": ")
|
|
|
|
|
DdfFileContent.Add(m_sSpace2Tab & ConstCompo.K_TYPEEDGE & ": " & SetBevel(Part.TypePart, Part.LockEdgeType.Name, Part.DispositionItem.Name, Part.SwingAlias.Name, Part.InvertBevel))
|
|
|
|
|
Else
|
|
|
|
|
DdfFileContent.Add(m_sSpace1Tab & ConstCompo.K_LOCKEDGE & ": " & SetBevel(Part.TypePart, Part.LockEdgeType.Name, Part.DispositionItem.Name, Part.SwingAlias.Name, Part.InvertBevel))
|
|
|
|
|
End If
|
|
|
|
|
DdfFileContent.Add(m_sSpace2Tab & ConstCompo.K_MACHINING & ": " & ConvertBooleanToOnOff(Part.LockEdgeMachining))
|
|
|
|
|
If Not StringToDouble(Part.LockEdgeOverMaterial, dVal) Then
|
|
|
|
|
MessageBox.Show(String.Format(EgtMsg(50141), K_LOCKEDGEOVERMATERIAL_INI), EgtMsg(50101), MessageBoxButton.OK, MessageBoxImage.Error)
|
|
|
|
@@ -714,7 +726,12 @@ Friend Module DdfFile
|
|
|
|
|
DdfFileContent.Add(m_sSpace2Tab & ConstCompo.K_OVERMATERIAL & ": " & sVal)
|
|
|
|
|
End If
|
|
|
|
|
End If
|
|
|
|
|
DdfFileContent.Add(m_sSpace1Tab & ConstCompo.K_HINGEEDGE & ": " & SetBevel(Part.TypePart, Part.HingeEdgeType.Name, Part.DispositionItem.Name, Part.SwingAlias.Name))
|
|
|
|
|
If OptionModule.m_sVersionDDF = "2" Then ' K_TYPE
|
|
|
|
|
DdfFileContent.Add(m_sSpace1Tab & ConstCompo.K_HINGEEDGE & ": ")
|
|
|
|
|
DdfFileContent.Add(m_sSpace2Tab & ConstCompo.K_TYPEEDGE & ": " & SetBevel(Part.TypePart, Part.HingeEdgeType.Name, Part.DispositionItem.Name, Part.SwingAlias.Name))
|
|
|
|
|
Else
|
|
|
|
|
DdfFileContent.Add(m_sSpace1Tab & ConstCompo.K_HINGEEDGE & ": " & SetBevel(Part.TypePart, Part.HingeEdgeType.Name, Part.DispositionItem.Name, Part.SwingAlias.Name))
|
|
|
|
|
End If
|
|
|
|
|
DdfFileContent.Add(m_sSpace2Tab & ConstCompo.K_MACHINING & ": " & ConvertBooleanToOnOff(Part.HingeEdgeMachining))
|
|
|
|
|
If Not StringToDouble(Part.HingeEdgeOverMaterial, dVal) Then
|
|
|
|
|
MessageBox.Show(String.Format(EgtMsg(50141), K_HINGEDGEOVERMATERIAL_INI), EgtMsg(50101), MessageBoxButton.OK, MessageBoxImage.Error)
|
|
|
|
@@ -730,7 +747,12 @@ Friend Module DdfFile
|
|
|
|
|
DdfFileContent.Add(m_sSpace2Tab & ConstCompo.K_OVERMATERIAL & ": " & sVal)
|
|
|
|
|
End If
|
|
|
|
|
End If
|
|
|
|
|
DdfFileContent.Add(m_sSpace1Tab & ConstCompo.K_TOP & ": " & SetBevel(Part.TypePart, Part.TopType.Name, Part.DispositionItem.Name, Part.SwingAlias.Name))
|
|
|
|
|
If OptionModule.m_sVersionDDF = "2" Then ' K_TYPE
|
|
|
|
|
DdfFileContent.Add(m_sSpace1Tab & ConstCompo.K_TOP & ": ")
|
|
|
|
|
DdfFileContent.Add(m_sSpace2Tab & ConstCompo.K_TYPEEDGE & ": " & SetBevel(Part.TypePart, Part.TopType.Name, Part.DispositionItem.Name, Part.SwingAlias.Name))
|
|
|
|
|
Else
|
|
|
|
|
DdfFileContent.Add(m_sSpace1Tab & ConstCompo.K_TOP & ": " & SetBevel(Part.TypePart, Part.TopType.Name, Part.DispositionItem.Name, Part.SwingAlias.Name))
|
|
|
|
|
End If
|
|
|
|
|
DdfFileContent.Add(m_sSpace2Tab & ConstCompo.K_MACHINING & ": " & ConvertBooleanToOnOff(Part.TopMachining))
|
|
|
|
|
If Not StringToDouble(Part.TopOverMaterial, dVal) Then
|
|
|
|
|
MessageBox.Show(String.Format(EgtMsg(50141), K_TOPOVERMATERIAL_INI), EgtMsg(50101), MessageBoxButton.OK, MessageBoxImage.Error)
|
|
|
|
@@ -746,7 +768,12 @@ Friend Module DdfFile
|
|
|
|
|
DdfFileContent.Add(m_sSpace2Tab & ConstCompo.K_OVERMATERIAL & ": " & sVal)
|
|
|
|
|
End If
|
|
|
|
|
End If
|
|
|
|
|
DdfFileContent.Add(m_sSpace1Tab & ConstCompo.K_BOTTOM & ": " & SetBevel(Part.TypePart, Part.BottomType.Name, Part.DispositionItem.Name, Part.SwingAlias.Name))
|
|
|
|
|
If OptionModule.m_sVersionDDF = "2" Then ' K_TYPE
|
|
|
|
|
DdfFileContent.Add(m_sSpace1Tab & ConstCompo.K_BOTTOM & ": ")
|
|
|
|
|
DdfFileContent.Add(m_sSpace2Tab & ConstCompo.K_TYPEEDGE & ": " & SetBevel(Part.TypePart, Part.BottomType.Name, Part.DispositionItem.Name, Part.SwingAlias.Name))
|
|
|
|
|
Else
|
|
|
|
|
DdfFileContent.Add(m_sSpace1Tab & ConstCompo.K_BOTTOM & ": " & SetBevel(Part.TypePart, Part.BottomType.Name, Part.DispositionItem.Name, Part.SwingAlias.Name))
|
|
|
|
|
End If
|
|
|
|
|
DdfFileContent.Add(m_sSpace2Tab & ConstCompo.K_MACHINING & ": " & ConvertBooleanToOnOff(Part.BottomMachining))
|
|
|
|
|
If Not StringToDouble(Part.BottomOverMaterial, dVal) Then
|
|
|
|
|
MessageBox.Show(String.Format(EgtMsg(50141), K_BOTTOMOVERMATERIAL_INI), EgtMsg(50101), MessageBoxButton.OK, MessageBoxImage.Error)
|
|
|
|
@@ -763,8 +790,9 @@ Friend Module DdfFile
|
|
|
|
|
End If
|
|
|
|
|
End If
|
|
|
|
|
|
|
|
|
|
DdfFileContent.Add(" ")
|
|
|
|
|
If OptionModule.m_sVersionDDF = "2" Then
|
|
|
|
|
DdfFileContent.Add(ConstCompo.K_HARDWARE & "hardware: ")
|
|
|
|
|
DdfFileContent.Add(ConstCompo.K_HARDWARE & ": ")
|
|
|
|
|
End If
|
|
|
|
|
' Riordino e stampo le compo
|
|
|
|
|
SearchCompo(DdfFileContent, Part, bIsDDF)
|
|
|
|
|