-pulizia codice
This commit is contained in:
@@ -1,7 +1,5 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.Windows
|
||||
Imports System.Windows.Input
|
||||
Imports System.Windows.Media
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
@@ -436,7 +434,6 @@ Public Class BTLFeatureM
|
||||
EgtRemoveInfo(BTLPartM.m_nPartId, ITG_PROJ_MSG)
|
||||
EgtRemoveInfo(BTLPartM.m_nPartId, ITG_PROJ_FALL)
|
||||
EgtRemoveInfo(BTLPartM.m_nPartId, ITG_PROJ_ROT)
|
||||
'EgtDuploSetModified(DirectCast(m_ParentPart, BTLPartM).m_nPartId)
|
||||
End If
|
||||
' Ripristino stato segnalazione modifica
|
||||
DisableMgr.ReEnable()
|
||||
@@ -504,9 +501,6 @@ Public Class BTLFeatureM
|
||||
vTempPar(BTLPar.nId - 1) = BTLPar.dValue
|
||||
Case BTLParamType.STRING_
|
||||
sTempPar = BTLPar.sValue
|
||||
'Case BTLParamType.COMBO
|
||||
' Dim cBTLPar As BTLParamCombo = DirectCast(ParentFeature.PParamList(ParIndex), BTLParamCombo)
|
||||
' vPar(ParIndex) = cBTLPar.
|
||||
End Select
|
||||
Next
|
||||
vPar = vTempPar
|
||||
|
||||
@@ -1,9 +1,4 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.Windows
|
||||
Imports System.Windows.Input
|
||||
Imports System.Windows.Media
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
Imports EgtUILib
|
||||
|
||||
Public Class BTLParamM
|
||||
|
||||
@@ -304,33 +299,6 @@ Public Class BTLParamM
|
||||
Return NewBTLParam
|
||||
End Function
|
||||
|
||||
'' new per double e length
|
||||
'Sub New(ParentFeature As BTLFeatureM, IsP As Boolean, nType As BTLParamType, sParamName As String, dMin As Double, dMax As Double, dDefault As Double, sDescription As String)
|
||||
' StdInit(ParentFeature, IsP, nType, sParamName, sDescription)
|
||||
' m_dMin = dMin
|
||||
' m_dMax = dMax
|
||||
' m_dDefault = dDefault
|
||||
'End Sub
|
||||
|
||||
'' new per stringhe
|
||||
'Sub New(ParentFeature As BTLFeatureM, IsP As Boolean, nType As BTLParamType, sParamName As String, sDescription As String)
|
||||
' StdInit(ParentFeature, IsP, nType, sParamName, sDescription)
|
||||
'End Sub
|
||||
|
||||
'' new per combobox
|
||||
'Sub New(ParentFeature As BTLFeatureM, IsP As Boolean, nType As BTLParamType, sParamName As String, nMin As Integer, nMax As Integer, nDefault As Integer, sDescription As String, ValueList As List(Of String))
|
||||
' StdInit(ParentFeature, IsP, nType, sParamName, sDescription)
|
||||
' m_dMin = nMin
|
||||
' m_dMax = nMax
|
||||
' m_dDefault = nDefault
|
||||
' m_ValueList = ValueList
|
||||
'End Sub
|
||||
|
||||
'' new per parametro vuoto
|
||||
'Sub New(IsP As Boolean, nType As BTLParamType, sParamName As String)
|
||||
' StdInit(Nothing, IsP, nType, sParamName, "")
|
||||
'End Sub
|
||||
|
||||
#End Region ' CONSTRUCTOR
|
||||
|
||||
#Region "METHODS"
|
||||
|
||||
@@ -4,14 +4,6 @@ Imports EgtWPFLib5
|
||||
|
||||
Public Class BTLPartM
|
||||
|
||||
'' Feature a cui appartiene il parametro
|
||||
'Public m_BTLStructureM As BTLStructureM
|
||||
'Public ReadOnly Property BTLStructureM As BTLStructureM
|
||||
' Get
|
||||
' Return m_BTLStructureM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
' Id geometrico del pezzo
|
||||
Public m_nPartId As Integer
|
||||
Public ReadOnly Property nPartId As Integer
|
||||
@@ -876,7 +868,6 @@ Public Class BTLPartM
|
||||
EgtGetInfo(nPartId, BTL_PRT_ELEMENTNUM, NewBTLPart.m_sELEMENTNUM)
|
||||
EgtGetInfo(nPartId, BTL_PRT_LAYER, NewBTLPart.m_nLAYER)
|
||||
EgtGetInfo(nPartId, BTL_PRT_MODULENUM, NewBTLPart.m_sMODULENUM)
|
||||
'EgtGetInfo(nPartId, BTL_PRT_USERATTRIBUTE, m_sUSERATTRIBUTE)
|
||||
EgtGetInfo(nPartId, BTL_PRT_COMMENT, NewBTLPart.m_sCOMMENT)
|
||||
|
||||
EgtGetInfo(nPartId, BTL_PRT_GRAINDIR, sValue)
|
||||
@@ -1001,197 +992,6 @@ Public Class BTLPartM
|
||||
Return TempList
|
||||
End Function
|
||||
|
||||
'Sub New(ParentStructure As BTLStructureVM, nPartId As Integer)
|
||||
' MyBase.New(ParentStructure, nPartId)
|
||||
' ' leggo info pezzo
|
||||
' Dim sValArray() As String
|
||||
' Dim sValue As String = String.Empty
|
||||
' Dim nValue As Integer = 0
|
||||
' EgtGetInfo(nPartId, BTL_PRT_PDN, nPDN)
|
||||
' Dim nDO As Integer = 1
|
||||
' If EgtGetInfo(nPartId, BTL_PRT_DO, nDO) Then
|
||||
' m_bDO = (nDO <> 0)
|
||||
' Else
|
||||
' m_bDO = True
|
||||
' End If
|
||||
' EgtGetInfo(nPartId, BTL_PRT_NAM, m_sNAM)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_L, m_dL)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_W, m_dW)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_H, m_dH)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_CNT, m_nCNT)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_ASSEMBLYNUM, m_sASSEMBLYNUM)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_ORDERNUM, m_nORDERNUM)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_DESIGNATION, m_sDESIGN)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_ANNOTATION, m_sANNOT)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_STOREY, m_sSTOREY)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_GROUP, m_sGROUP)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_PACKAGE, m_sPACKAGE)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_TIMBERGRADE, m_sTIMBERGRADE)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_QUALITYGRADE, m_sQUALITYGRADE)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_COLOUR, sValue)
|
||||
' m_colCOLOR.FromString(sValue)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_PLANINGLENGTH, m_dPLANINGLEN)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_STARTOFFSET, m_dSTARTOFFSET)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_ENDOFFSET, m_dENDOFFSET)
|
||||
|
||||
' Dim ind As Integer = 1
|
||||
' While EgtGetInfo(nPartId, BTL_PRT_UID & ind, nValue)
|
||||
' ocUID.Add(nValue)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_TRANSFORMATION & ind, sValue)
|
||||
' m_refTransf = New Frame3d
|
||||
' Dim ptOri As New Point3d
|
||||
' Dim vtVersX As New Vector3d
|
||||
' Dim vtVersY As New Vector3d
|
||||
' sValArray = sValue.Split({","}, StringSplitOptions.RemoveEmptyEntries)
|
||||
' If sValArray.Count() >= 9 Then
|
||||
' StringToLenAdv(sValArray(0), ptOri.x)
|
||||
' StringToLenAdv(sValArray(1), ptOri.y)
|
||||
' StringToLenAdv(sValArray(2), ptOri.z)
|
||||
' StringToDoubleAdv(sValArray(3), vtVersX.x)
|
||||
' StringToDoubleAdv(sValArray(4), vtVersX.y)
|
||||
' StringToDoubleAdv(sValArray(5), vtVersX.z)
|
||||
' StringToDoubleAdv(sValArray(6), vtVersY.x)
|
||||
' StringToDoubleAdv(sValArray(7), vtVersY.y)
|
||||
' StringToDoubleAdv(sValArray(8), vtVersY.z)
|
||||
' m_refTransf.ChangeOrigin(ptOri)
|
||||
' m_refTransf.Setup(ptOri, ptOri + vtVersX, ptOri + vtVersY)
|
||||
' End If
|
||||
' refTransfList.Add(m_refTransf)
|
||||
' ind = ind + 1
|
||||
' End While
|
||||
|
||||
' EgtGetInfo(nPartId, BTL_PRT_CAMBER, sValue)
|
||||
' sValArray = sValue.Split(New String() {": ", " P"}, StringSplitOptions.RemoveEmptyEntries)
|
||||
' If sValArray.Count() >= 5 Then
|
||||
' StringToLenAdv(sValArray(3), m_dCamberLen1)
|
||||
' StringToLenAdv(sValArray(5), m_dCamberLen2)
|
||||
' StringToLenAdv(sValArray(7), m_dCamberLen3)
|
||||
' StringToLenAdv(sValArray(9), m_dCamberCross3)
|
||||
' End If
|
||||
' Dim pFrom As Integer = sValue.IndexOf("SIDE: ") + "SIDE: ".Length
|
||||
' Dim pTo As Integer = sValue.LastIndexOf(" P01")
|
||||
' If pTo >= 0 Then
|
||||
' nValue = CInt(sValue.Substring(pFrom, pTo - pFrom))
|
||||
' m_SelCAMBERSIDE = ocCAMBERSIDE.IndexOf(CInt(sValue.Substring(pFrom, pTo - pFrom)))
|
||||
' End If
|
||||
|
||||
' EgtGetInfo(nPartId, BTL_PRT_PARTOFFSET, sValue)
|
||||
' sValArray = sValue.Split(New String() {": ", " P"}, StringSplitOptions.RemoveEmptyEntries)
|
||||
' If sValArray.Count() >= 5 Then
|
||||
' StringToLenAdv(sValArray(3), m_dPartOffsetSide1)
|
||||
' StringToLenAdv(sValArray(5), m_dPartOffsetSide2)
|
||||
' StringToLenAdv(sValArray(7), m_dPartOffsetSide3)
|
||||
' StringToLenAdv(sValArray(9), m_dPartOffsetSide4)
|
||||
' End If
|
||||
' pFrom = sValue.IndexOf("P04: ") + "P04: ".Length
|
||||
' pTo = sValue.LastIndexOf(" P11")
|
||||
' If pTo >= 0 Then
|
||||
' m_SelREFSIDEFIXCLAMP = IdNameStruct.IndFromId(IdNameStruct.IdFromName(sValue.Substring(pFrom, pTo - pFrom), ocREFSIDEFIXCLAMP), ocREFSIDEFIXCLAMP)
|
||||
' End If
|
||||
|
||||
' EgtGetInfo(nPartId, BTL_PRT_PROCESSINGQUALITY, sValue)
|
||||
' m_SelPROCESSINGQUALITY = IdNameStruct.IndFromId(IdNameStruct.IdFromName(sValue, ocPROCESSINGQUALITY), ocPROCESSINGQUALITY)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_RECESS, sValue)
|
||||
' m_SelRECESS = IdNameStruct.IndFromId(IdNameStruct.IdFromName(sValue, ocRECESS), ocRECESS)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_STOREYTYPE, sValue)
|
||||
' m_SelSTOREYTYPE = IdNameStruct.IndFromId(IdNameStruct.IdFromName(sValue, ocSTOREYTYPE), ocSTOREYTYPE)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_ELEMENTNUM, m_sELEMENTNUM)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_LAYER, m_nLAYER)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_MODULENUM, m_sMODULENUM)
|
||||
' 'EgtGetInfo(nPartId, BTL_PRT_USERATTRIBUTE, m_sUSERATTRIBUTE)
|
||||
' EgtGetInfo(nPartId, BTL_PRT_COMMENT, m_sCOMMENT)
|
||||
|
||||
' EgtGetInfo(nPartId, BTL_PRT_GRAINDIR, sValue)
|
||||
' m_refGrainDir = New Vector3d
|
||||
' sValArray = sValue.Split(New String() {",", ";"}, StringSplitOptions.RemoveEmptyEntries)
|
||||
' If sValArray.Count() >= 4 Then
|
||||
' StringToDoubleAdv(sValArray(0), m_refGrainDir.x)
|
||||
' StringToDoubleAdv(sValArray(1), m_refGrainDir.y)
|
||||
' StringToDoubleAdv(sValArray(2), m_refGrainDir.z)
|
||||
' m_bGRAINDIRALIGN = (CInt(sValArray(3)) = 1)
|
||||
' End If
|
||||
|
||||
' EgtGetInfo(nPartId, BTL_PRT_REFSIDE, sValue)
|
||||
' sValArray = sValue.Split({";"}, StringSplitOptions.RemoveEmptyEntries)
|
||||
' If sValArray.Count() >= 2 Then
|
||||
' m_SelREFSIDE = ocREFSIDE.IndexOf(CInt(sValArray(0)))
|
||||
' m_bREFSIDEALIGN = (CInt(sValArray(1)) = 1)
|
||||
' End If
|
||||
|
||||
' EgtGetInfo(nPartId, BTL_PRT_ALIGNMENT, sValue)
|
||||
' sValArray = sValue.Split({":"}, StringSplitOptions.RemoveEmptyEntries)
|
||||
' If sValArray.Count() >= 2 Then
|
||||
' m_SelALIGNLOCATION = IdNameStruct.IndFromId(IdNameStruct.IdFromName(sValArray(0), ocALIGNLOCATION), ocALIGNLOCATION)
|
||||
' m_SelALIGNENDTYPE = IdNameStruct.IndFromId(IdNameStruct.IdFromName(sValArray(1).Trim(), ocALIGNENDTYPE), ocALIGNENDTYPE)
|
||||
' End If
|
||||
|
||||
' EgtGetInfo(nPartId, BTL_PRT_MATERIALTYPE, sValue)
|
||||
' sValArray = sValue.Split({":"}, StringSplitOptions.RemoveEmptyEntries)
|
||||
' If sValArray.Count() >= 1 Then
|
||||
' m_SelMATERIALTYPEGRP = IdNameStruct.IndFromId(IdNameStruct.IdFromName(sValArray(0), ocMATERIALTYPEGRP), ocMATERIALTYPEGRP)
|
||||
' If sValArray.Count() >= 2 Then m_sMATERIALTYPESPEC = sValArray(1).Trim()
|
||||
' End If
|
||||
|
||||
' If Not EgtGetInfo(nPartId, BTL_PRT_ROTATED, m_nROTATED) Then
|
||||
' m_nROTATED = 0
|
||||
' End If
|
||||
' If Not EgtGetInfo(nPartId, BTL_PRT_INVERTED, m_nINVERTED) Then
|
||||
' m_nINVERTED = 0
|
||||
' End If
|
||||
' If EgtGetInfo(nPartId, BTL_PRT_MATERIAL, m_sMATERIAL) Then
|
||||
' If Not ParentStructure.MaterialList.Contains(m_sMATERIAL) Then
|
||||
' ParentStructure.MaterialList.Add(m_sMATERIAL)
|
||||
' End If
|
||||
' End If
|
||||
' If Not ParentStructure.SectionList.Contains(Section) Then
|
||||
' ParentStructure.SectionList.Add(Section)
|
||||
' End If
|
||||
' ' Leggo outline
|
||||
' Dim nOutlineLayerId As Integer = EgtGetFirstNameInGroup(nPartId, OUTLINE)
|
||||
' Dim nOutlineId As Integer = EgtGetFirstInGroup(nOutlineLayerId)
|
||||
' While nOutlineId <> GDB_ID.NULL
|
||||
' ' verifico che sia una feature
|
||||
' Dim nGRP As Integer
|
||||
' If EgtGetInfo(nOutlineId, BTL_FTR_GRP, nGRP) Then
|
||||
' ' creo la feature
|
||||
' m_FeatureList.Add(New BTLFeatureVM(Me, nOutlineId))
|
||||
' End If
|
||||
' nOutlineId = EgtGetNext(nOutlineId)
|
||||
' End While
|
||||
' ' Leggo feature
|
||||
' Dim nProcessingId As Integer = EgtGetFirstNameInGroup(nPartId, PROCESSINGS)
|
||||
' Dim nFeatureId As Integer = EgtGetFirstInGroup(nProcessingId)
|
||||
' While nFeatureId <> GDB_ID.NULL
|
||||
' ' verifico che sia una feature
|
||||
' Dim nGRP As Integer
|
||||
' If EgtGetInfo(nFeatureId, BTL_FTR_GRP, nGRP) Then
|
||||
' ' creo la feature
|
||||
' m_FeatureList.Add(New BTLFeatureVM(Me, nFeatureId))
|
||||
' End If
|
||||
' nFeatureId = EgtGetNext(nFeatureId)
|
||||
' End While
|
||||
' ' Aggiorno check DOALL
|
||||
' NotifyPropertyChanged("bDOALL")
|
||||
' ' leggo calc error
|
||||
' Dim nErr As Integer = 0
|
||||
' Dim nRot As Integer = 0
|
||||
' Dim nFall As Integer = 0
|
||||
' Dim sMsg As String = ""
|
||||
' Dim bCalc As Boolean = False
|
||||
' bCalc = EgtGetInfo(nPartId, ITG_PROJ_ERR, nErr)
|
||||
' EgtGetInfo(nPartId, ITG_PROJ_ROT, nRot)
|
||||
' EgtGetInfo(nPartId, ITG_PROJ_FALL, sMsg)
|
||||
' EgtGetInfo(nPartId, ITG_PROJ_MSG, sMsg)
|
||||
' CalcPartUpdate(bCalc, nErr, nRot, nFall, sMsg)
|
||||
' CalcFeatureUpdate()
|
||||
'End Sub
|
||||
|
||||
'Sub New(ParentStructure As BTLStructure, nPartId As Integer)
|
||||
' m_BTLStructureM = ParentStructure
|
||||
' Me.SetPartId = nPartId
|
||||
' m_FeatureList = New ObservableCollection(Of BTLFeature)
|
||||
'End Sub
|
||||
|
||||
#End Region ' CONSTRUCTOR
|
||||
|
||||
#Region "METHODS"
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
Imports System.IO
|
||||
Imports EgtUILib
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
Public Class BTLStructureM
|
||||
@@ -436,11 +435,6 @@ Public Class BTLStructureM
|
||||
If NewBTLStructure.m_nPROJTYPE <> BWType.NULL Then BTLIniFile.m_nBTLBWType = NewBTLStructure.m_nPROJTYPE
|
||||
' recupero i part
|
||||
NewBTLStructure.m_BTLPartMList = LoadParts(ProjId)
|
||||
'Dim nPartId As Integer = EgtGetFirstPart()
|
||||
'While nPartId <> GDB_ID.NULL
|
||||
' NewBTLStructure.m_BTLPartMList.Add(BTLPartM.CreateBTLPart(nPartId))
|
||||
' nPartId = EgtGetNextPart(nPartId)
|
||||
'End While
|
||||
Return NewBTLStructure
|
||||
End Function
|
||||
|
||||
@@ -483,7 +477,6 @@ Public Class BTLStructureM
|
||||
If IsNothing(BTLPartM) Then Return
|
||||
If Not m_BTLPartMList.Contains(BTLPartM) Then Return
|
||||
m_BTLPartMList.Remove(BTLPartM)
|
||||
'RaiseEvent BTLPartAdded(Me, New BTLPartAddedEventArgs(BTLPartM))
|
||||
End Sub
|
||||
|
||||
Public Function GetBTLParts() As List(Of BTLPartM)
|
||||
|
||||
@@ -1,9 +1,5 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.Collections.Specialized
|
||||
Imports System.ComponentModel
|
||||
Imports System.Windows
|
||||
Imports System.Windows
|
||||
Imports System.Windows.Media
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
@@ -206,19 +202,6 @@ Public Class BTLFeatureVM
|
||||
|
||||
#Region "CONSTRUCTOR"
|
||||
|
||||
'Sub New(BTLFeatureM As BTLFeatureM, BTLPartM As BTLPartM)
|
||||
' m_BTLFeatureM = BTLFeatureM
|
||||
' AddHandler m_BTLFeatureM.PBTLParamAdded, AddressOf OnPBTLParamAdded
|
||||
' AddHandler m_BTLFeatureM.QBTLParamAdded, AddressOf OnQBTLParamAdded
|
||||
' m_BTLPartM = BTLPartM
|
||||
' CreatePBTLParamVMList()
|
||||
' CreateQBTLParamVMList()
|
||||
' NotifyPropertyChanged(NameOf(Calc_Background))
|
||||
' NotifyPropertyChanged(NameOf(CALC_ROT_Visibility))
|
||||
' NotifyPropertyChanged(NameOf(CALC_ERR_Letter))
|
||||
' NotifyPropertyChanged(NameOf(CALC_ERR_Foreground))
|
||||
'End Sub
|
||||
|
||||
Sub New()
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtWPFLib5
|
||||
|
||||
Public Class MyBeamMachiningsWindowVM
|
||||
|
||||
@@ -3,8 +3,6 @@ Imports System.Threading
|
||||
Imports System.Globalization
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
Imports EgtBEAMWALL.Core.ConstBeam
|
||||
Imports EgtBEAMWALL.Core
|
||||
|
||||
Public Module CalcIntegration
|
||||
|
||||
@@ -166,7 +164,6 @@ Public Module CalcIntegration
|
||||
RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(nCurrBar))) 'ProcessResults(vBar(nCurrBar))
|
||||
ElseIf vBar(nCurrBar).nCmdType = CmdTypes.GENERATE Then
|
||||
RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(nCurrBar))) 'ProcessResults(vBar(nCurrBar))
|
||||
'RaiseEvent Calc_ProcessEnd(Nothing, New CalcProcessEndEventArgs(vBar(nCurrBar))) 'ProcessResults(vBar(nCurrBar))
|
||||
End If
|
||||
bDone = True
|
||||
nCurrBar += 1
|
||||
@@ -182,7 +179,6 @@ Public Module CalcIntegration
|
||||
RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(vProc(j).nBar))) ' ProcessResults(vBar(vProc(j).nBar))
|
||||
ElseIf vBar(vProc(j).nBar).nCmdType = CmdTypes.GENERATE Then
|
||||
RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(vProc(j).nBar))) ' ProcessResults(vBar(vProc(j).nBar))
|
||||
'RaiseEvent Calc_ProcessEnd(Nothing, New CalcProcessEndEventArgs(vBar(vProc(j).nBar))) 'ProcessResults(vBar(nCurrBar))
|
||||
End If
|
||||
bDone = True
|
||||
vProc(j).nBar = -1
|
||||
@@ -205,7 +201,6 @@ Public Module CalcIntegration
|
||||
RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(vProc(j).nBar))) ' ProcessResults(vBar(vProc(j).nBar))
|
||||
ElseIf vBar(vProc(j).nBar).nCmdType = CmdTypes.GENERATE Then
|
||||
RaiseEvent Calc_ProcessResult(Nothing, New CalcResultEventArgs(vBar(vProc(j).nBar))) ' ProcessResults(vBar(vProc(j).nBar))
|
||||
'RaiseEvent Calc_ProcessEnd(Nothing, New CalcProcessEndEventArgs(vBar(vProc(j).nBar))) 'ProcessResults(vBar(nCurrBar))
|
||||
End If
|
||||
bDone = True
|
||||
vProc(j).nBar = -1
|
||||
@@ -416,11 +411,6 @@ Public Module CalcIntegration
|
||||
Dim nTaskId As Integer = nOutlineId
|
||||
If EgtGetInfo(nOutlineId, BTL_FTR_MAINID, nMainOffsId) Then
|
||||
nTaskId = nOutlineId + nMainOffsId
|
||||
'' assegno TASKID alla feature per calcoli
|
||||
'EgtSetInfo(nOutlineId, "TASKID", nOutlineId + nMainOffsId, True)
|
||||
'Else
|
||||
' ' assegno TASKID alla feature per calcoli
|
||||
' EgtSetInfo(nOutlineId, "TASKID", nOutlineId, True)
|
||||
End If
|
||||
' assegno TASKID alla feature per calcoli
|
||||
EgtSetInfo(nOutlineId, "TASKID", nTaskId)
|
||||
@@ -455,11 +445,6 @@ Public Module CalcIntegration
|
||||
Dim nTaskId As Integer = nFeatureId
|
||||
If EgtGetInfo(nFeatureId, BTL_FTR_MAINID, nMainOffsId) Then
|
||||
nTaskId = nFeatureId + nMainOffsId
|
||||
' ' assegno TASKID alla feature per calcoli
|
||||
' EgtSetInfo(nFeatureId, "TASKID", nFeatureId + nMainOffsId, True)
|
||||
'Else
|
||||
' ' assegno TASKID alla feature per calcoli
|
||||
' EgtSetInfo(nFeatureId, "TASKID", nFeatureId, True)
|
||||
End If
|
||||
' assegno TASKID alla feature per calcoli
|
||||
EgtSetInfo(nFeatureId, "TASKID", nTaskId)
|
||||
@@ -485,7 +470,6 @@ Public Module CalcIntegration
|
||||
End Module
|
||||
|
||||
Public Class Bar
|
||||
'Public piInfo As PatternInfo
|
||||
Public nBarState As Integer
|
||||
Public nBarId As Integer
|
||||
Public sBarPath As String
|
||||
|
||||
@@ -104,9 +104,6 @@
|
||||
|
||||
Public Const BTLFEATURES_FILE_NAME As String = "BTLFeatures.ini"
|
||||
|
||||
'Public Const S_GENERAL As String = "General"
|
||||
'Public Const K_DEBUG As String = "Debug"
|
||||
|
||||
' Tipo di progetto
|
||||
Public Enum ProjectType As Integer
|
||||
PROJ = 1
|
||||
@@ -171,7 +168,6 @@
|
||||
Public Const BTL_PRT_ELEMENTNUM = "ELEMENTNUMBER"
|
||||
Public Const BTL_PRT_LAYER = "LAYER"
|
||||
Public Const BTL_PRT_MODULENUM = "MODULENUMBER"
|
||||
'Friend Const BTL_PRT_USERATTRIBUTE = "USERATTRIBUTE"
|
||||
Public Const BTL_PRT_COMMENT = "COMMENT"
|
||||
Public Const BTL_PRT_GRAINDIR = "GRAINDIRECTION"
|
||||
Public Const BTL_PRT_REFSIDE = "REFERENCESIDE"
|
||||
|
||||
@@ -15,29 +15,17 @@ Public Module ConstIni
|
||||
|
||||
Public Const INI_FILE_NAME As String = "EgtBEAMWALL.ini"
|
||||
|
||||
'Public Const S_GENERAL As String = "General"
|
||||
'Public Const K_DEBUG As String = "Debug"
|
||||
'Public Const K_LICENCE As String = "Licence"
|
||||
'Public Const K_USERLEVEL As String = "UserLevel"
|
||||
'Public Const K_MAXINST As String = "MaxInstances"
|
||||
Public Const K_NETKEY As String = "NetKey"
|
||||
Public Const K_MAXCAMINST As String = "MaxCamInstances"
|
||||
Public Const K_VIEWOPTIM_INSTANCES As String = "ViewOptimInstances"
|
||||
Public Const K_SUPERVISOR_INSTANCES As String = "SupervisorInstances"
|
||||
'Public Const K_COMMANDLOG As String = "CommandLog"
|
||||
'Public Const K_MESSAGESDIR As String = "MessagesDir"
|
||||
'Public Const K_MESSAGES As String = "Messages"
|
||||
'Public Const K_WINPLACE As String = "WinPlace"
|
||||
Public Const K_VIEWOPTIMWINPLACE As String = "ViewOptimWinPlace"
|
||||
Public Const K_SUPERVISORWINPLACE As String = "SupervisorWinPlace"
|
||||
'Public Const K_LASTPROJ As String = "LastProj"
|
||||
'Public Const K_AUTOLOADLASTPROJ As String = "AutoLoadLastProj"
|
||||
Public Const K_LASTIMPDIR As String = "LastImpDir"
|
||||
Public Const K_LASTNGEXPDIR As String = "LastNgexpDir"
|
||||
Public Const K_LASTUPDATEDIR As String = "LastUpdateDir"
|
||||
Public Const K_PROJSINDEX As String = "ProjsIndex"
|
||||
Public Const K_PRODSINDEX As String = "ProdsIndex"
|
||||
'Public Const K_SUPPORT As String = "Support"
|
||||
Public Const K_DBADDRESS As String = "DbAddress"
|
||||
Public Const K_DBMASTERKEY As String = "DbMasterKey"
|
||||
Public Const K_SHAREDFOLDER As String = "SharedFolder"
|
||||
@@ -48,51 +36,7 @@ Public Module ConstIni
|
||||
Public Const K_ADDPROJ As String = "AddProj"
|
||||
Public Const K_PROJECTMODE As String = "ProjectMode"
|
||||
|
||||
'Public Const S_LANGUAGES As String = "Languages"
|
||||
'Public Const K_LANGUAGE As String = "Language"
|
||||
|
||||
'Public Const S_LUA As String = "Lua"
|
||||
'Public Const K_LIBSDIR As String = "LibsDir"
|
||||
'Public Const K_BASELIB As String = "BaseLib"
|
||||
|
||||
'Public Const S_GEOMDB As String = "GeomDB"
|
||||
'Public Const K_DEFAULTFONT As String = "DefaultFont"
|
||||
'Public Const K_NFEFONTDIR As String = "NfeFontDir"
|
||||
'Public Const K_DEFAULTCOLOR As String = "DefaultColor"
|
||||
'Public Const K_SAVETYPE As String = "SaveType"
|
||||
|
||||
'Public Const S_OPENGL As String = "OpenGL"
|
||||
'Public Const K_DOUBLEBUFFER As String = "DoubleBuffer"
|
||||
'Public Const K_COLORBITS As String = "ColorBits"
|
||||
'Public Const K_DEPTHBITS As String = "DepthBits"
|
||||
'Public Const K_DRIVER As String = "Driver"
|
||||
|
||||
'Public Const S_SCENE As String = "Scene"
|
||||
'Public Const K_BACKTOP As String = "BackTop"
|
||||
'Public Const K_BACKBOTTOM As String = "BackBottom"
|
||||
'Public Const K_SHOWGFRAME As String = "ShowGFrame"
|
||||
'Public Const K_MARK As String = "Mark"
|
||||
'Public Const K_SELSURF As String = "SelSurf"
|
||||
'Public Const K_SHOWMODE As String = "ShowMode"
|
||||
Public Const K_SHOWBUILDING As String = "ShowBuilding"
|
||||
'Public Const K_CURVEDIR As String = "CurveDir"
|
||||
'Public Const K_SHOWTRIAADV As String = "ShowTriaAdv"
|
||||
'Public Const K_SHOWZMAP As String = "ShowZmap"
|
||||
'Public Const K_TEXMAXLINPIX As String = "TextureMaxLinPixels"
|
||||
'Public Const K_ZOOMWIN As String = "ZoomWin"
|
||||
'Public Const K_DISTLINE As String = "DistLine"
|
||||
'Public Const K_MMUNITS As String = "MmUnits"
|
||||
|
||||
'Public Const S_GRID As String = "Grid"
|
||||
'Public Const K_SHOWGRID As String = "ShowGrid"
|
||||
'Public Const K_SHOWFRAME As String = "ShowFrame"
|
||||
'Public Const K_SNAPSTEP As String = "SnapStep"
|
||||
'Public Const K_SNAPSTEPINCH As String = "SnapStepInch"
|
||||
'Public Const K_MINLINESSTEP As String = "MinLineSStep"
|
||||
'Public Const K_MAJLINESSTEP As String = "MajLineSStep"
|
||||
'Public Const K_EXTSSTEP As String = "ExtSStep"
|
||||
'Public Const K_MINLNCOLOR As String = "MinLnColor"
|
||||
'Public Const K_MAJLNCOLOR As String = "MajLnColor"
|
||||
|
||||
Public Const S_IMPORT As String = "Import"
|
||||
Public Const K_BTLFLAG As String = "BtlFlag"
|
||||
@@ -100,19 +44,11 @@ Public Module ConstIni
|
||||
Public Const K_BTLAUXDIR As String = "BtlAuxDir"
|
||||
Public Const K_WALLOPPOSITESIDENESTING As String = "WallOppositeSideNesting"
|
||||
|
||||
'Public Const S_MACH As String = "Mach"
|
||||
'Public Const K_MACHINESDIR As String = "MachinesDir"
|
||||
'Public Const K_TOOLMAKERSDIR As String = "ToolMakersDir"
|
||||
'Public Const K_CURRMACH As String = "CurrMach"
|
||||
Public Const K_SUPERVISORMACH As String = "SupervisorMach"
|
||||
Public Const K_PASSWORD As String = "Password"
|
||||
Public Const K_CHANGEMACH As String = "ChangeMach"
|
||||
Public Const K_EXPORTBWE As String = "ExpBwe"
|
||||
|
||||
'Public Const S_SIMUL As String = "Simul"
|
||||
'Public Const K_SLIDERX As String = "SliderX"
|
||||
'Public Const K_SLIDERVAL As String = "SliderVal"
|
||||
|
||||
Public Const S_BEAM As String = "Beam"
|
||||
Public Const K_CALCPATH As String = "CalcPath"
|
||||
Public Const K_BEAMBASEDIR As String = "BaseDir"
|
||||
@@ -132,7 +68,6 @@ Public Module ConstIni
|
||||
Public Const S_OPENFILEDIALOG As String = "OpenFileDialog"
|
||||
Public Const K_VIEWARCHIVED As String = "ViewArchived"
|
||||
|
||||
'Public Const S_NEST As String = "Nest"
|
||||
Public Const K_NESTEXEC As String = "NestExec"
|
||||
Public Const K_FLIPROT As String = "FlipRot"
|
||||
Public Const K_SECTIONTIME As String = "SectionTime"
|
||||
|
||||
@@ -1,8 +1,4 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.IO
|
||||
Imports System.Windows
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
Imports EgtUILib
|
||||
|
||||
Public Class MachGroupM
|
||||
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.IO
|
||||
Imports System.Windows
|
||||
Imports System.Windows
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
@@ -140,34 +138,6 @@ Public Class MachGroupPanelM
|
||||
Return New List(Of MachGroupM)(m_MachGroupMList)
|
||||
End Function
|
||||
|
||||
'Public Function InitMachGroupPanel(IsMultiMachGroup As Boolean,
|
||||
' MachineList As List(Of Machine), DefaultMachine As String,
|
||||
' Optional sBaseName As String = "MachGroup_1") As Boolean
|
||||
' m_IsMultiMachGroup = IsMultiMachGroup
|
||||
' ' se è a gruppo singolo, nascondo il panel
|
||||
' If Not m_IsMultiMachGroup Then SetMachGroupPanelVisibility(False)
|
||||
' ' Assegno nome base
|
||||
' m_BaseName = sBaseName
|
||||
' ' Recupero lista macchine
|
||||
' m_MachineList = MachineList
|
||||
' ' Assegno macchina di default
|
||||
' m_DefaultMachine = DefaultMachine
|
||||
' Return MachineList.Count > 0
|
||||
'End Function
|
||||
|
||||
'Public Overridable Sub LoadMachGroupList()
|
||||
' ' Carico i gruppi di lavorazione nella lista
|
||||
' Dim nId = EgtGetFirstMachGroup()
|
||||
' While nId <> GDB_ID.NULL
|
||||
' Dim sName As String = String.Empty
|
||||
' Dim sMachine As String = String.Empty
|
||||
' EgtGetMachGroupName(nId, sName)
|
||||
' EgtGetMachGroupMachineName(nId, sMachine)
|
||||
' MachGroupMList.Add(New MachGroup(nId, sName, sMachine))
|
||||
' nId = EgtGetNextMachGroup(nId)
|
||||
' End While
|
||||
'End Sub
|
||||
|
||||
Public Overridable Function NewMachGroup() As MachGroupM
|
||||
' Sistemazioni preliminari
|
||||
OnPreNewMachGroup()
|
||||
|
||||
@@ -1,8 +1,4 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.IO
|
||||
Imports System.Windows
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
Imports EgtWPFLib5
|
||||
|
||||
Public Class MachGroupVM
|
||||
Inherits VMBase
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.Collections.Specialized
|
||||
Imports System.ComponentModel
|
||||
Imports System.IO
|
||||
Imports System.Windows
|
||||
Imports System.Windows.Input
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
@@ -280,7 +278,6 @@ Public Class NewMachGroupPanelVM
|
||||
|
||||
Protected Overridable Sub OnMachGroupVMPropertyChanged(sender As Object, e As PropertyChangedEventArgs)
|
||||
Select Case e.PropertyName
|
||||
'Case nameof(sender.sMATERIAL)
|
||||
End Select
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -1,9 +1,6 @@
|
||||
Imports System.Timers
|
||||
Imports System.Windows
|
||||
Imports System.Windows
|
||||
Imports System.Windows.Input
|
||||
Imports System.Windows.Threading
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
Public Class LoadingWndVM
|
||||
@@ -218,12 +215,6 @@ Public Class LoadingWndVM
|
||||
''' Execute the Open. This method is invoked by the OpenCommand.
|
||||
''' </summary>
|
||||
Friend Sub Cancel()
|
||||
'' chiedo conferma
|
||||
'If MessageBox.Show("Are you sure you want to stop the nesting?", "Warning", MessageBoxButton.YesNo, MessageBoxImage.Warning) = MessageBoxResult.No Then Return
|
||||
'' fermo il nesting
|
||||
'Map.refOptimizePanelVM.m_StopNesting = True
|
||||
'' fermo timer e chiudo finestra
|
||||
'CloseNesting()
|
||||
End Sub
|
||||
|
||||
#End Region ' Cancel
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.IO
|
||||
Imports EgtUILib
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
Public Class MyMachGroupPanelM
|
||||
@@ -130,7 +128,6 @@ Public Class MyMachGroupPanelM
|
||||
End Function
|
||||
|
||||
Public Overrides Function OnPreNewMachGroup() As Boolean
|
||||
'EgtSetCurrentContext(Map.refSceneHostVM.MainScene.GetCtx())
|
||||
Return True
|
||||
End Function
|
||||
|
||||
@@ -141,17 +138,6 @@ Public Class MyMachGroupPanelM
|
||||
Dim sCurrMachName As String = String.Empty
|
||||
EgtGetCurrMachineName(sCurrMachName)
|
||||
WriteMainPrivateProfileString(S_MACH, K_CURRMACH, sCurrMachName)
|
||||
'' leggo nome attrezzaggio di default
|
||||
'Dim sDefaultSetUpName As String = String.Empty
|
||||
'Dim sMachineIniPath As String = Map.refMainWindowVM.MainWindowM.sMachinesRoot & "\" & sCurrMachName & "\" & sCurrMachName & ".ini"
|
||||
'EgtUILib.GetPrivateProfileString(S_SETUP, K_DEFAULT, "", sDefaultSetUpName, sMachineIniPath)
|
||||
'' se è attiva l'opzione, rendo corrente l'attrezzaggio di default
|
||||
'If Not String.IsNullOrEmpty(sDefaultSetUpName) Then
|
||||
' If Not EgtImportSetup(sDefaultSetUpName) Then
|
||||
' EgtOutLog("Error loading default setup " & sDefaultSetUpName)
|
||||
' MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 9) & " " & sDefaultSetUpName, EgtMsg(MSG_MESSAGEBOX + 1), MessageBoxButton.OK, MessageBoxImage.Exclamation)
|
||||
' End If
|
||||
'End If
|
||||
Return True
|
||||
End Function
|
||||
|
||||
@@ -402,20 +388,6 @@ Public Class MyMachGroupPanelM
|
||||
End If
|
||||
End While
|
||||
ToRedrawMachGroupList.Add(nMachGroupId)
|
||||
|
||||
|
||||
|
||||
'' elimino vecchio grezzo ed eseguo script creazione nuovo
|
||||
'Dim nRawId As Integer = EgtGetFirstRawPart()
|
||||
'While nRawId <> GDB_ID.NULL
|
||||
' EgtRemovePartFromRawPart(EgtGetFirstPartInRawPart(nRawId))
|
||||
' EgtRemoveRawPart(nRawId)
|
||||
' nRawId = EgtGetFirstRawPart()
|
||||
'End While
|
||||
'If Not ExecBeam(Map.refMainWindowVM.MainWindowM.sTempDir, Map.refMachinePanelVM.SelectedMachine.Name, CalcIntegration.CmdTypes.RAWPART, False) Then Return False
|
||||
|
||||
|
||||
|
||||
' lo setto come corrente
|
||||
EgtSetCurrMachGroup(nMachGroupId)
|
||||
' elimino pezzo copia
|
||||
@@ -466,15 +438,6 @@ Public Class MyMachGroupPanelM
|
||||
Return EgtGetParent(nSwapItem)
|
||||
End If
|
||||
Return GDB_ID.NULL
|
||||
|
||||
|
||||
|
||||
'Dim nRawId As Integer = GDB_ID.NULL
|
||||
'If EgtGetInfo(nDuploId, GDB_SI_LIST, nRawId) AndAlso nRawId > 0 Then
|
||||
' Return nRawId
|
||||
'Else
|
||||
' Return GDB_ID.NULL
|
||||
'End If
|
||||
End Function
|
||||
|
||||
#End Region ' METHODS
|
||||
|
||||
@@ -1,8 +1,4 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.IO
|
||||
Imports System.Windows.Input
|
||||
Imports System.Windows.Media
|
||||
Imports EgtUILib
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
Public Class PartM
|
||||
@@ -299,7 +295,6 @@ Public Class PartM
|
||||
Else
|
||||
Return m_dPOSY
|
||||
End If
|
||||
'Return m_dPOSY
|
||||
End Get
|
||||
Set(value As Double)
|
||||
m_dPOSY = value
|
||||
|
||||
@@ -1,7 +1,4 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.ComponentModel
|
||||
Imports System.IO
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports System.ComponentModel
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
@@ -118,17 +115,9 @@ Public MustInherit Class MyMachGroupPanelVM
|
||||
EgtRemoveRawPart(nRawId)
|
||||
nRawId = EgtGetFirstRawPart()
|
||||
End While
|
||||
'If Not ExecBeam(Map.refMainWindowVM.MainWindowM.sTempDir, Map.refMachinePanelVM.SelectedMachine.Name, CalcIntegration.CmdTypes.RAWPART, False) Then Return False
|
||||
|
||||
Next
|
||||
End Sub
|
||||
|
||||
'Public Overrides Sub AddMachGroup()
|
||||
' Dim MyMachGroupM As MyMachGroupM = m_MyMachGroupPanelM.NewMyMachGroup(CurrentMachine.sMachineName, Map.refProjectVM.BTLStructureVM.nPROJTYPE)
|
||||
' ' e lo seleziono
|
||||
' SelectedMachGroup = MachGroupVMList.FirstOrDefault(Function(x) x.MachGroupM Is MyMachGroupM)
|
||||
'End Sub
|
||||
|
||||
Public Overrides Function OnPreSetCurrMachGroup() As Boolean
|
||||
EgtSetCurrentContext(CoreMap.refSceneHostVM.MainScene.GetCtx())
|
||||
Return True
|
||||
@@ -145,18 +134,6 @@ Public MustInherit Class MyMachGroupPanelVM
|
||||
Return True
|
||||
End Function
|
||||
|
||||
' funzione che seleziona primo gruppo
|
||||
'Friend Sub SelFirstMachGroup()
|
||||
' If Not IsNothing(Me) AndAlso Not IsNothing(MachGroupVMList) AndAlso MachGroupVMList.Count > 0 Then
|
||||
' SelectedMachGroup = MachGroupVMList(0)
|
||||
' Else
|
||||
' SelectedMachGroup = Nothing
|
||||
' EgtResetCurrMachGroup()
|
||||
' ' nascondo tutti i pezzi
|
||||
' Map.refProjectVM.BTLStructureVM.HideAll()
|
||||
' End If
|
||||
'End Sub
|
||||
|
||||
' funzione che seleziona ultimo gruppo
|
||||
Public Sub SelLastMachGroup()
|
||||
If Not IsNothing(Me) AndAlso Not IsNothing(MachGroupVMList) AndAlso MachGroupVMList.Count > 0 Then
|
||||
|
||||
@@ -1,11 +1,9 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.Collections.Specialized
|
||||
Imports System.ComponentModel
|
||||
Imports System.IO
|
||||
Imports System.Windows
|
||||
Imports System.Windows.Input
|
||||
Imports System.Windows.Media
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
|
||||
@@ -6,8 +6,6 @@ Imports System.Windows.Input
|
||||
Imports System.Windows.Media
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports System.Windows.Threading
|
||||
|
||||
Public MustInherit Class PartVM
|
||||
Inherits VMBase
|
||||
@@ -638,9 +636,6 @@ Public MustInherit Class PartVM
|
||||
End Sub
|
||||
|
||||
Protected Overridable Sub OnBTLFeatureVMPropertyChanged(sender As Object, e As PropertyChangedEventArgs)
|
||||
'Select Case e.PropertyName
|
||||
' Case NameOf(sender.nSelGRP), NameOf(sender.nSelSIDE)
|
||||
'End Select
|
||||
End Sub
|
||||
|
||||
#End Region ' EVENTS
|
||||
|
||||
@@ -4,8 +4,6 @@ Imports System.Windows
|
||||
Imports System.Windows.Controls
|
||||
Imports System.Windows.Data
|
||||
Imports System.Windows.Input
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtBEAMWALL.Core.ConstBeam
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
@@ -590,22 +588,6 @@ Public MustInherit Class NewOpenProjectFileDialogVM
|
||||
End Sub
|
||||
|
||||
Protected Sub LoadColumns()
|
||||
'If ProjectType = ProjectType.PROJ Then
|
||||
' carico le colonne della datagrid
|
||||
' GetPrivateProfileColumns(S_OPENPROJFILEDLG_PROJ, ProjColumns)
|
||||
' ' carico campi su cui eseguire il filtro di ricerca
|
||||
' m_BTLDateTypeList = New List(Of String)({CreateDate_Msg, ExportDate_Msg})
|
||||
' m_SelBTLDateType = BTLDateTypes.CREATEDATE
|
||||
' NotifyPropertyChanged(NameOf(BTLDateTypeList))
|
||||
' NotifyPropertyChanged(NameOf(SelBTLDateType))
|
||||
' m_FilterTypeList = New ObservableCollection(Of IdNameStruct)({New IdNameStruct(FilterTypes.NULL, ""),
|
||||
' New IdNameStruct(FilterTypes.ID, Id_Msg),
|
||||
' New IdNameStruct(FilterTypes.BTLFILENAME, BTLFileName_Msg),
|
||||
' New IdNameStruct(FilterTypes.LISTNAME, ListName_Msg),
|
||||
' New IdNameStruct(FilterTypes.MACHINE, Machine_Msg)})
|
||||
' m_SelFilterType = m_FilterTypeList.FirstOrDefault(Function(x) x.Id = FilterTypes.NULL)
|
||||
' NotifyPropertyChanged(NameOf(SelFilterType))
|
||||
'ElseIf ProjectType = ProjectType.PROD Then
|
||||
' carico le colonne della datagrid
|
||||
GetPrivateProfileColumns(S_NEWOPENPROJFILEDLG_PROD, ProdColumns)
|
||||
' carico campi su cui eseguire il filtro di ricerca
|
||||
@@ -661,15 +643,6 @@ Public MustInherit Class NewOpenProjectFileDialogVM
|
||||
(m_SelFilterType.Id = FilterTypes.BTLFILENAME AndAlso CurrProj.ProjFileList.Any(Function(x) DirectCast(x, ProjFileVM).sBTLFileName.IndexOf(SearchText, StringComparison.InvariantCultureIgnoreCase) < 0)) OrElse
|
||||
(m_SelFilterType.Id = FilterTypes.LISTNAME AndAlso CurrProj.ProjFileList.Any(Function(x) DirectCast(x, ProjFileVM).sListName.IndexOf(SearchText, StringComparison.InvariantCultureIgnoreCase) < 0)) OrElse
|
||||
(m_SelFilterType.Id = FilterTypes.MACHINE AndAlso CurrProj.sMachine.IndexOf(SearchText, StringComparison.InvariantCultureIgnoreCase) < 0)) Then bProjectOk = False
|
||||
'ElseIf TypeOf Proj Is ProdFileVM Then
|
||||
' Dim CurrProj As ProdFileVM = DirectCast(Proj, ProdFileVM)
|
||||
' If m_SelFilterType.Id <> FilterTypes.NULL AndAlso (
|
||||
' (m_SelFilterType.Id = BTLDateTypes.CREATEDATE AndAlso Not SearchDate.Contains(CurrProj.dtCreateDate.Date))) Then bProjectOk = False
|
||||
' If m_SelFilterType.Id <> FilterTypes.NULL AndAlso m_SearchText <> String.Empty AndAlso (
|
||||
' (m_SelFilterType.Id = FilterTypes.ID AndAlso CurrProj.sProdId.ToString.IndexOf(SearchText, StringComparison.InvariantCultureIgnoreCase) < 0) OrElse
|
||||
' (m_SelFilterType.Id = FilterTypes.BTLFILENAME AndAlso CurrProj.sBTLFileName.IndexOf(SearchText, StringComparison.InvariantCultureIgnoreCase) < 0) OrElse
|
||||
' (m_SelFilterType.Id = FilterTypes.MACHINE AndAlso CurrProj.sMachine.IndexOf(SearchText, StringComparison.InvariantCultureIgnoreCase) < 0)) Then bProjectOk = False
|
||||
'End If
|
||||
Return bProjectOk
|
||||
End Function
|
||||
|
||||
|
||||
@@ -84,42 +84,6 @@
|
||||
</Grid>
|
||||
</GroupBox>
|
||||
|
||||
|
||||
<!--<StackPanel>
|
||||
<Grid Grid.Row="0" Margin="5">
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="1*" />
|
||||
<RowDefinition Height="1*" />
|
||||
</Grid.RowDefinitions>
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*" />
|
||||
<ColumnDefinition Width="1*" />
|
||||
</Grid.ColumnDefinitions>
|
||||
|
||||
<TextBlock Text="{Binding FilterType_Msg}"
|
||||
Grid.Row="0" Grid.Column="0"
|
||||
Style="{StaticResource OptionTextBlock}"/>
|
||||
<ComboBox ItemsSource="{Binding SearchColumnList}"
|
||||
SelectedItem="{Binding SelSearchColumn}"
|
||||
Width="Auto"
|
||||
Margin="5"
|
||||
Grid.Row="0" Grid.Column="1"
|
||||
Style="{StaticResource FeatureComboBox}"/>
|
||||
<TextBlock Text="{Binding Search_Msg}"
|
||||
Margin="0,5,0,0"
|
||||
Grid.Row="1" Grid.Column="0"
|
||||
Style="{StaticResource OptionTextBlock}"/>
|
||||
<EgtWPFLib5:EgtTextBox Text="{Binding SearchText}"
|
||||
Margin="5"
|
||||
Grid.Row="1" Grid.Column="1"
|
||||
Visibility="{Binding SearchText_Visibility}"/>
|
||||
<Calendar SelectedDatesChanged="Calendar_SelectedDatesChanged"
|
||||
SelectionMode="MultipleRange"
|
||||
Grid.Row="1" Grid.Column="1"
|
||||
Visibility="{Binding SearchDate_Visibility}"/>
|
||||
</Grid>
|
||||
</StackPanel>-->
|
||||
|
||||
<EgtBEAMWALL:EgtDataGrid Grid.Row="1"
|
||||
ItemsSource="{Binding ProjectList}"
|
||||
SelectedItem="{Binding SelProject}"
|
||||
@@ -199,31 +163,7 @@
|
||||
<TextBlock Text="{Binding Path=DataContext.Name_Msg,RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OpenProjectFileDialogV}}}"/>
|
||||
</DataGridTextColumn.Header>
|
||||
</DataGridTextColumn>
|
||||
<!-- Delete -->
|
||||
<!--
|
||||
<DataGridTemplateColumn x:Key="colDELETE"
|
||||
Width="Auto"
|
||||
IsReadOnly="True">
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<Button Content="X"
|
||||
Command="{Binding Delete_Command}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>-->
|
||||
</DataGrid.Resources>
|
||||
<!--<ListBox.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding OpenFileName}"
|
||||
Padding="4,1,4,1">
|
||||
<TextBlock.InputBindings>
|
||||
<MouseBinding MouseAction="LeftDoubleClick"
|
||||
Command="{Binding DataContext.ProjectDoubleClick_Command, RelativeSource={RelativeSource AncestorType={x:Type ListBox}}}"
|
||||
CommandParameter="{Binding nProjId}" />
|
||||
</TextBlock.InputBindings>
|
||||
</TextBlock>
|
||||
</DataTemplate>
|
||||
</ListBox.ItemTemplate>-->
|
||||
<DataGrid.RowStyle>
|
||||
<Style TargetType="DataGridRow">
|
||||
<Setter Property="IsEnabled" Value="{Binding bIsEnabled}"/>
|
||||
@@ -232,38 +172,6 @@
|
||||
</DataGrid.RowStyle>
|
||||
</EgtBEAMWALL:EgtDataGrid>
|
||||
|
||||
<!--<ListBox Grid.Row="0"
|
||||
ItemsSource="{Binding ProjectList}"
|
||||
SelectedItem="{Binding SelProject}"
|
||||
Margin="5">
|
||||
-->
|
||||
<!--<ListBox.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding ProjFileName}"/>
|
||||
</DataTemplate>
|
||||
</ListBox.ItemTemplate>-->
|
||||
<!--
|
||||
<ListBox.ItemContainerStyle>
|
||||
<Style TargetType="ListBoxItem">
|
||||
<Setter Property="HorizontalContentAlignment" Value="Stretch"></Setter>
|
||||
<Setter Property="Padding" Value="0"></Setter>
|
||||
</Style>
|
||||
</ListBox.ItemContainerStyle>
|
||||
<ListBox.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding OpenFileName}"
|
||||
Padding="4,1,4,1">
|
||||
<TextBlock.InputBindings>
|
||||
<MouseBinding MouseAction="LeftDoubleClick"
|
||||
Command="{Binding DataContext.ProjectDoubleClick_Command, RelativeSource={RelativeSource AncestorType={x:Type ListBox}}}"
|
||||
CommandParameter="{Binding nProjId}" />
|
||||
</TextBlock.InputBindings>
|
||||
</TextBlock>
|
||||
</DataTemplate>
|
||||
</ListBox.ItemTemplate>
|
||||
</ListBox>-->
|
||||
|
||||
|
||||
<UniformGrid Columns="3" Grid.Row="2" Margin="0,0,0,5">
|
||||
<Button IsDefault="True" Name="OpenBtn"
|
||||
Content="{Binding Open_Msg}" Style="{DynamicResource EgtWPFLib5_InputButton}"/>
|
||||
|
||||
@@ -4,8 +4,6 @@ Imports System.Windows
|
||||
Imports System.Windows.Controls
|
||||
Imports System.Windows.Data
|
||||
Imports System.Windows.Input
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtBEAMWALL.Core.ConstBeam
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
|
||||
@@ -1,7 +1,4 @@
|
||||
Imports System.IO
|
||||
Imports EgtUILib
|
||||
|
||||
Public Class ProdFileM
|
||||
Public Class ProdFileM
|
||||
Inherits ProjectFileM
|
||||
|
||||
Protected m_nProjIdList As List(Of Integer)
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
|
||||
Imports EgtWPFLib5
|
||||
Imports EgtWPFLib5
|
||||
Imports System.Windows
|
||||
|
||||
Public Class ProdItem
|
||||
|
||||
@@ -1,7 +1,4 @@
|
||||
Imports System.IO
|
||||
Imports EgtUILib
|
||||
|
||||
Public Class ProjFileM
|
||||
Public Class ProjFileM
|
||||
Inherits ProjectFileM
|
||||
|
||||
Protected m_dtExportDate As DateTime
|
||||
|
||||
@@ -1,17 +1,4 @@
|
||||
Imports System.IO
|
||||
Imports EgtUILib
|
||||
|
||||
Public Class ProjectFileM
|
||||
|
||||
'Protected m_nProjectType As ProjectType
|
||||
'Public ReadOnly Property nProjectType As ProjectType
|
||||
' Get
|
||||
' Return m_nProjectType
|
||||
' End Get
|
||||
'End Property
|
||||
'Public Sub SetProjectType(nProjectType As ProjectType)
|
||||
' m_nProjectType = nProjectType
|
||||
'End Sub
|
||||
Public Class ProjectFileM
|
||||
|
||||
Protected m_nProjId As Integer = 0
|
||||
Public ReadOnly Property nProjId As Integer
|
||||
|
||||
@@ -68,23 +68,6 @@ Public Module BTLIniFile
|
||||
Return IpGRPList.Count > 0
|
||||
End Function
|
||||
|
||||
'Public Function GetBeamPrivateProfileVerifyGRP(IpAppName As String, IpGPRtoVerify As String) As Boolean
|
||||
' ' ciclo sui tipi di gruppo
|
||||
' Dim sBTLGroup As String = String.Empty
|
||||
' If EgtUILib.GetPrivateProfileString(IpAppName, BTL_FTR_GRP, String.Empty, sBTLGroup, m_sBTLIniFile) > 0 Then
|
||||
' Dim sBTLGroups() As String = sBTLGroup.Split(","c)
|
||||
' ' verifico numero minimo di parametri
|
||||
' If sBTLGroups.Count >= 0 Then
|
||||
' ' cancello spazi
|
||||
' For Index = 0 To sBTLGroups.Count - 1
|
||||
' sBTLGroups(Index) = sBTLGroups(Index).Trim()
|
||||
' Next
|
||||
' End If
|
||||
' Return sBTLGroups.Contains(IpGPRtoVerify)
|
||||
' End If
|
||||
' Return False
|
||||
'End Function
|
||||
|
||||
Public Function CalcBeamPrivateProfileGRP(nGRP As Integer) As Integer
|
||||
If nGRP = 1 Or nGRP = 2 Then
|
||||
Return 1
|
||||
|
||||
@@ -2,326 +2,53 @@
|
||||
|
||||
Public Module CoreMap
|
||||
|
||||
'Private m_refMainWindowVM As MainWindowVM
|
||||
'Private m_refMyStatusBarVM As MyStatusBarVM
|
||||
'Private m_refProjManagerVM As ProjManagerVM
|
||||
'Private m_refProdManagerVM As ProdManagerVM
|
||||
'Private m_refProjectVM As ProjectVM
|
||||
'Private m_refMainMenuVM As MainMenuVM
|
||||
Private m_refMachinePanelVM As MachinePanelVM
|
||||
Private m_refMyMachGroupPanelVM As MyMachGroupPanelVM
|
||||
'Private m_refLeftPanelVM As LeftPanelVM
|
||||
'Private m_refBottomPanelVM As BottomPanelVM
|
||||
'Private m_refShowBeamPanelVM As ShowBeamPanelVM
|
||||
'Private m_refConfigurationPageVM As ConfigurationPageVM
|
||||
'Private m_refRawPartListVM As RawPartListVM
|
||||
'Private m_refPartInRawPartListVM As PartInRawPartListVM
|
||||
'Private m_refWarehouseWndVM As WarehouseWndVM
|
||||
'Private m_refFeatureListVM As FeatureListVM
|
||||
'Private m_refFreeContourManagerVM As FreeContourManagerVM
|
||||
'Private m_refFreeContourInputVM As FreeContourInputVM
|
||||
'Private m_refPartManagerVM As PartManagerVM
|
||||
'Private m_refInstrumentPanelVM As InstrumentPanelVM
|
||||
'Private m_refTopPanelVM As TopPanelVM
|
||||
'Private m_refOptimizePanelVM As OptimizePanelVM
|
||||
'Private m_refOpenProjectFileDialogVM As OpenProjectFileDialogVM
|
||||
|
||||
#Region "Get"
|
||||
|
||||
'Public ReadOnly Property refMainWindowVM As MainWindowVM
|
||||
' Get
|
||||
' Return m_refMainWindowVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refMyStatusBarVM As MyStatusBarVM
|
||||
' Get
|
||||
' Return LibMap.refStatusBarVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refProjManagerVM As ProjManagerVM
|
||||
' Get
|
||||
' Return m_refProjManagerVM
|
||||
' End Get
|
||||
'End Property
|
||||
'Public ReadOnly Property refProdManagerVM As ProdManagerVM
|
||||
' Get
|
||||
' Return m_refProdManagerVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refProjectVM As ProjectVM
|
||||
' Get
|
||||
' Return m_refProjectVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
Public ReadOnly Property refSceneHostVM As SceneHostVM
|
||||
Get
|
||||
Return LibMap.refSceneHostVM
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'Public ReadOnly Property refShowPanelVM As ShowPanelVM
|
||||
' Get
|
||||
' Return LibMap.refShowPanelVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refMainMenuVM As MainMenuVM
|
||||
' Get
|
||||
' Return m_refMainMenuVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
Public ReadOnly Property refMachinePanelVM As MachinePanelVM
|
||||
Get
|
||||
Return m_refMachinePanelVM
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'Public ReadOnly Property refLeftPanelVM As LeftPanelVM
|
||||
' Get
|
||||
' Return m_refLeftPanelVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
Public ReadOnly Property refMachGroupPanelVM As MyMachGroupPanelVM
|
||||
Get
|
||||
Return m_refMyMachGroupPanelVM
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'Public ReadOnly Property refBottomPanelVM As BottomPanelVM
|
||||
' Get
|
||||
' Return m_refBottomPanelVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refShowBeamPanelVM As ShowBeamPanelVM
|
||||
' Get
|
||||
' Return m_refShowBeamPanelVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refConfigurationPageVM As ConfigurationPageVM
|
||||
' Get
|
||||
' Return m_refConfigurationPageVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refRawPartListVM As RawPartListVM
|
||||
' Get
|
||||
' Return m_refRawPartListVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refPartInRawPartListVM As PartInRawPartListVM
|
||||
' Get
|
||||
' Return m_refPartInRawPartListVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refWarehouseWndVM As WarehouseWndVM
|
||||
' Get
|
||||
' Return m_refWarehouseWndVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refFeatureListVM As FeatureListVM
|
||||
' Get
|
||||
' Return m_refFeatureListVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refFreeContourManagerVM As FreeContourManagerVM
|
||||
' Get
|
||||
' Return m_refFreeContourManagerVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refFreeContourInputVM As FreeContourInputVM
|
||||
' Get
|
||||
' Return m_refFreeContourInputVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refPartManagerVM As PartManagerVM
|
||||
' Get
|
||||
' Return m_refPartManagerVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refInstrumentPanelVM As MyInstrumentPanelVM
|
||||
' Get
|
||||
' Return m_refInstrumentPanelVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refTopPanelVM As TopPanelVM
|
||||
' Get
|
||||
' Return m_refTopPanelVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refOptimizePanelVM As OptimizePanelVM
|
||||
' Get
|
||||
' Return m_refOptimizePanelVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refOpenProjectFileDialogVM As OpenProjectFileDialogVM
|
||||
' Get
|
||||
' Return m_refOpenProjectFileDialogVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
#End Region ' Get
|
||||
|
||||
#Region "Set"
|
||||
|
||||
'Friend Function SetRefMyStatusBarVM(MyStatusBarVM As MyStatusBarVM) As Boolean
|
||||
' LibMap.SetRefStatusBarVM(MyStatusBarVM)
|
||||
' Return Not IsNothing(LibMap.refStatusBarVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefProjManagerVM(ProjManagerVM As ProjManagerVM) As Boolean
|
||||
' m_refProjManagerVM = ProjManagerVM
|
||||
' Return Not IsNothing(m_refProjManagerVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefProdManagerVM(ProdManagerVM As ProdManagerVM) As Boolean
|
||||
' m_refProdManagerVM = ProdManagerVM
|
||||
' Return Not IsNothing(m_refProdManagerVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefProjectVM(ProjectVM As ProjectVM) As Boolean
|
||||
' m_refProjectVM = ProjectVM
|
||||
' Return Not IsNothing(m_refProjectVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefMainMenuVM(MainMenuVM As MainMenuVM) As Boolean
|
||||
' m_refMainMenuVM = MainMenuVM
|
||||
' Return Not IsNothing(m_refMainMenuVM)
|
||||
'End Function
|
||||
|
||||
Public Function SetRefSceneHostVM(SceneHostVM As SceneHostVM) As Boolean
|
||||
LibMap.SetRefSceneHostVM(SceneHostVM)
|
||||
Return Not IsNothing(LibMap.refSceneHostVM)
|
||||
End Function
|
||||
|
||||
'Friend Function SetRefShowPanelVM(ShowPanelVM As ShowPanelVM) As Boolean
|
||||
' LibMap.SetRefShowPanelVM(ShowPanelVM)
|
||||
' Return Not IsNothing(LibMap.refShowPanelVM)
|
||||
'End Function
|
||||
|
||||
Public Function SetRefMachinePanelVM(MachinePanelVM As MachinePanelVM) As Boolean
|
||||
m_refMachinePanelVM = MachinePanelVM
|
||||
Return Not IsNothing(m_refMachinePanelVM)
|
||||
End Function
|
||||
|
||||
'Friend Function SetRefLeftPanelVM(LeftPanelVM As LeftPanelVM) As Boolean
|
||||
' m_refLeftPanelVM = LeftPanelVM
|
||||
' Return Not IsNothing(m_refLeftPanelVM)
|
||||
'End Function
|
||||
|
||||
Public Function SetRefMachGroupPanelVM(MachGroupPanelVM As MyMachGroupPanelVM) As Boolean
|
||||
m_refMyMachGroupPanelVM = MachGroupPanelVM
|
||||
Return Not IsNothing(m_refMyMachGroupPanelVM)
|
||||
End Function
|
||||
|
||||
'Friend Function SetRefBottomPanelVM(BottomPanelVM As BottomPanelVM) As Boolean
|
||||
' m_refBottomPanelVM = BottomPanelVM
|
||||
' Return Not IsNothing(m_refBottomPanelVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefShowBeamPanelVM(ShowBeamPanelVM As ShowBeamPanelVM) As Boolean
|
||||
' m_refShowBeamPanelVM = ShowBeamPanelVM
|
||||
' Return Not IsNothing(m_refShowBeamPanelVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefConfigurationPageVM(ConfigurationPageVM As ConfigurationPageVM) As Boolean
|
||||
' m_refConfigurationPageVM = ConfigurationPageVM
|
||||
' Return Not IsNothing(m_refConfigurationPageVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefRawPartListVM(RawPartListVM As RawPartListVM) As Boolean
|
||||
' m_refRawPartListVM = RawPartListVM
|
||||
' Return Not IsNothing(m_refRawPartListVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefPartInRawPartListVM(PartInRawPartListVM As PartInRawPartListVM) As Boolean
|
||||
' m_refPartInRawPartListVM = PartInRawPartListVM
|
||||
' Return Not IsNothing(m_refPartInRawPartListVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefWarehouseWndVM(WarehouseWndVM As WarehouseWndVM) As Boolean
|
||||
' m_refWarehouseWndVM = WarehouseWndVM
|
||||
' Return Not IsNothing(m_refWarehouseWndVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefFeatureListVM(FeatureListVM As FeatureListVM) As Boolean
|
||||
' m_refFeatureListVM = FeatureListVM
|
||||
' Return Not IsNothing(m_refFeatureListVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefFreeContourManagerVM(FreeContourManagerVM As FreeContourManagerVM) As Boolean
|
||||
' m_refFreeContourManagerVM = FreeContourManagerVM
|
||||
' Return Not IsNothing(m_refFreeContourManagerVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefFreeContourInputVM(FreeContourInputVM As FreeContourInputVM) As Boolean
|
||||
' m_refFreeContourInputVM = FreeContourInputVM
|
||||
' Return Not IsNothing(m_refFreeContourInputVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefPartManagerVM(PartManagerVM As PartManagerVM) As Boolean
|
||||
' m_refPartManagerVM = PartManagerVM
|
||||
' Return Not IsNothing(m_refPartManagerVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefInstrumentPanelVM(InstrumentPanelVM As InstrumentPanelVM) As Boolean
|
||||
' m_refInstrumentPanelVM = InstrumentPanelVM
|
||||
' Return Not IsNothing(m_refInstrumentPanelVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefTopPanelVM(TopPanelVM As TopPanelVM) As Boolean
|
||||
' m_refTopPanelVM = TopPanelVM
|
||||
' Return Not IsNothing(m_refTopPanelVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefOptimizePanelVM(OptimizePanelVM As OptimizePanelVM) As Boolean
|
||||
' m_refOptimizePanelVM = OptimizePanelVM
|
||||
' Return Not IsNothing(m_refOptimizePanelVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefOpenProjectFileDialogVM(OpenProjectFileDialogVM As OpenProjectFileDialogVM) As Boolean
|
||||
' m_refOpenProjectFileDialogVM = OpenProjectFileDialogVM
|
||||
' Return Not IsNothing(m_refOpenProjectFileDialogVM)
|
||||
'End Function
|
||||
|
||||
#End Region ' Set
|
||||
|
||||
#Region "Init"
|
||||
|
||||
'Friend Function BeginInit(MainWindowVM As MainWindowVM) As Boolean
|
||||
' m_refMainWindowVM = MainWindowVM
|
||||
' Return Not IsNothing(m_refMainWindowVM)
|
||||
'End Function
|
||||
Friend Function EndInit() As Boolean
|
||||
'Return Not IsNothing(m_refMainWindowVM) AndAlso Not IsNothing(m_refMainMenuVM) AndAlso
|
||||
' Not IsNothing(LibMap.refStatusBarVM) AndAlso Not IsNothing(m_refProjManagerVM) AndAlso
|
||||
' Not IsNothing(m_refProdManagerVM) AndAlso Not IsNothing(m_refConfigurationPageVM) AndAlso
|
||||
' Not IsNothing(LibMap.refSceneHostVM) AndAlso Not IsNothing(LibMap.refShowPanelVM) AndAlso
|
||||
' Not IsNothing(m_refMachinePanelVM) AndAlso Not IsNothing(LibMap.refMachGroupPanelVM) AndAlso
|
||||
' Not IsNothing(m_refRawPartListVM) AndAlso Not IsNothing(m_refWarehouseWndVM) AndAlso
|
||||
' Not IsNothing(m_refFeatureListVM) AndAlso Not IsNothing(m_refPartInRawPartListVM) AndAlso
|
||||
' Not IsNothing(m_refFreeContourManagerVM) AndAlso Not IsNothing(m_refFreeContourInputVM) AndAlso
|
||||
' Not IsNothing(m_refInstrumentPanelVM) AndAlso Not IsNothing(m_refTopPanelVM) AndAlso
|
||||
' Not IsNothing(m_refPartManagerVM) AndAlso Not IsNothing(m_refOptimizePanelVM) AndAlso
|
||||
' Not IsNothing(m_refShowBeamPanelVM) AndAlso Not IsNothing(m_refOpenProjectFileDialogVM) AndAlso
|
||||
' LibMap.EndInit()
|
||||
Return Not IsNothing(m_refMachinePanelVM) AndAlso Not IsNothing(LibMap.refMachGroupPanelVM)
|
||||
End Function
|
||||
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.Windows
|
||||
Imports System.Windows.Controls
|
||||
Imports EgtWPFLib5
|
||||
|
||||
Public Class GridDimension
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
Imports System.Windows
|
||||
Imports EgtUILib
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
Public Class SectionXMaterial
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
Imports EgtBEAMWALL.Core.ConstBeam
|
||||
Imports EgtUILib
|
||||
Imports EgtUILib
|
||||
|
||||
Public Class ViewPanelVM
|
||||
Inherits EgtWPFLib5.ViewPanelVM
|
||||
@@ -16,26 +15,6 @@ Public Class ViewPanelVM
|
||||
Private Shared m_nViewDir As VT = VT.ISO_SW
|
||||
|
||||
Public Shared Sub BWSetView(nView As VT, Optional bRedraw As Boolean = True)
|
||||
' condizioni che cambiano la vista del progetto
|
||||
'Select Case m_Type
|
||||
' Case BWType.BEAM
|
||||
' Select Case nView
|
||||
' Case VT.TOP
|
||||
' EgtSetView(VT.TOP, bRedraw)
|
||||
' Case VT.FRONT
|
||||
' EgtSetView(VT.FRONT, bRedraw)
|
||||
' Case VT.BACK
|
||||
' EgtSetView(VT.BACK, bRedraw)
|
||||
' Case VT.RIGHT
|
||||
' EgtSetView(VT.RIGHT, bRedraw)
|
||||
' Case VT.LEFT
|
||||
' EgtSetView(VT.LEFT, bRedraw)
|
||||
' Case VT.ISO_SW
|
||||
' EgtSetView(VT.ISO_SW, bRedraw)
|
||||
' Case Else ' VT.ISO_SW
|
||||
' EgtSetView(VT.ISO_SW, bRedraw)
|
||||
' End Select
|
||||
' Case BWType.WALL
|
||||
Select Case nView
|
||||
Case VT.TOP
|
||||
Select Case m_nViewDir
|
||||
@@ -155,32 +134,8 @@ Public Class ViewPanelVM
|
||||
|
||||
#End Region ' RightViewCommand
|
||||
|
||||
'#Region "IsoViewSECommand"
|
||||
|
||||
' ''' <summary>
|
||||
' ''' Returns a command that do IsoViewSE.
|
||||
' ''' </summary>
|
||||
' Public ReadOnly Property IsoViewSECommand As ICommand
|
||||
' Get
|
||||
' If m_cmdIsoViewSE Is Nothing Then
|
||||
' m_cmdIsoViewSE = New Command(AddressOf IsoViewSE)
|
||||
' End If
|
||||
' Return m_cmdIsoViewSE
|
||||
' End Get
|
||||
' End Property
|
||||
|
||||
' ''' <summary>
|
||||
' ''' Execute the IsoViewSE. This method is invoked by the IsoViewSECommand.
|
||||
' ''' </summary>
|
||||
' Public Sub IsoViewSE(ByVal param As Object)
|
||||
' LibMap.refSceneHostVM.MainScene.IsoViewSE()
|
||||
' End Sub
|
||||
|
||||
'#End Region ' IsoViewSECommand
|
||||
|
||||
#Region "IsoViewSWCommand"
|
||||
|
||||
|
||||
''' <summary>
|
||||
''' Execute the IsoViewSW. This method is invoked by the IsoViewSWCommand.
|
||||
''' </summary>
|
||||
@@ -190,75 +145,6 @@ Public Class ViewPanelVM
|
||||
|
||||
#End Region ' IsoViewSWCommand
|
||||
|
||||
'#Region "IsoViewNECommand"
|
||||
|
||||
' ''' <summary>
|
||||
' ''' Returns a command that do IsoViewNE.
|
||||
' ''' </summary>
|
||||
' Public ReadOnly Property IsoViewNECommand As ICommand
|
||||
' Get
|
||||
' If m_cmdIsoViewNE Is Nothing Then
|
||||
' m_cmdIsoViewNE = New Command(AddressOf IsoViewNE)
|
||||
' End If
|
||||
' Return m_cmdIsoViewNE
|
||||
' End Get
|
||||
' End Property
|
||||
|
||||
' ''' <summary>
|
||||
' ''' Execute the IsoViewNE. This method is invoked by the IsoViewNECommand.
|
||||
' ''' </summary>
|
||||
' Public Sub IsoViewNE(ByVal param As Object)
|
||||
' LibMap.refSceneHostVM.MainScene.IsoViewNE()
|
||||
' End Sub
|
||||
|
||||
'#End Region ' IsoViewNECommand
|
||||
|
||||
'#Region "IsoViewNWCommand"
|
||||
|
||||
' ''' <summary>
|
||||
' ''' Returns a command that do IsoViewNW.
|
||||
' ''' </summary>
|
||||
' Public ReadOnly Property IsoViewNWCommand As ICommand
|
||||
' Get
|
||||
' If m_cmdIsoViewNW Is Nothing Then
|
||||
' m_cmdIsoViewNW = New Command(AddressOf IsoViewNW)
|
||||
' End If
|
||||
' Return m_cmdIsoViewNW
|
||||
' End Get
|
||||
' End Property
|
||||
|
||||
' ''' <summary>
|
||||
' ''' Execute the IsoViewNW. This method is invoked by the IsoViewNWCommand.
|
||||
' ''' </summary>
|
||||
' Public Sub IsoViewNW(ByVal param As Object)
|
||||
' LibMap.refSceneHostVM.MainScene.IsoViewNW()
|
||||
' End Sub
|
||||
|
||||
'#End Region ' IsoViewNWCommand
|
||||
|
||||
'#Region "ViewToCPlaneCommand"
|
||||
|
||||
' ''' <summary>
|
||||
' ''' Returns a command that do GetDist.
|
||||
' ''' </summary>
|
||||
' Public ReadOnly Property ViewToCPlaneCommand As ICommand
|
||||
' Get
|
||||
' If m_cmdViewToCPlane Is Nothing Then
|
||||
' m_cmdViewToCPlane = New Command(AddressOf ViewToCPlane)
|
||||
' End If
|
||||
' Return m_cmdViewToCPlane
|
||||
' End Get
|
||||
' End Property
|
||||
|
||||
' ''' <summary>
|
||||
' ''' Execute the GetDist. This method is invoked by the GetDistCommand.
|
||||
' ''' </summary>
|
||||
' Public Sub ViewToCPlane(ByVal param As Object)
|
||||
' LibMap.refSceneHostVM.MainScene.CPlaneView()
|
||||
' End Sub
|
||||
|
||||
'#End Region ' ViewToCPlaneCommand
|
||||
|
||||
#End Region ' COMMANDS
|
||||
|
||||
End Class
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports EgtWPFLib5
|
||||
Imports EgtUILib
|
||||
|
||||
Public Class AxesPanelVM
|
||||
Inherits VMBase
|
||||
|
||||
@@ -1,9 +1,5 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.Collections.Specialized
|
||||
Imports System.ComponentModel
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
Public Class BTLFeatureVM
|
||||
Inherits Core.BTLFeatureVM
|
||||
|
||||
@@ -111,10 +111,6 @@ Public Class CALCPanelVM
|
||||
End Sub
|
||||
|
||||
Private Sub Calc_ProcessEnded(sender As Object, e As CalcProcessEndEventArgs)
|
||||
'Dim nRawid As Integer = e.m_Result.nBarId
|
||||
'If nRawid <= 0 Then Return
|
||||
'Dim Machgroup As MyMachGroupVM = GetMachgroupVMFromMachgroupId(nRawid)
|
||||
'Machgroup.CALCEnd()
|
||||
End Sub
|
||||
|
||||
Private Shared Sub ProcessResults(Bar As Bar)
|
||||
@@ -176,9 +172,6 @@ Public Class CALCPanelVM
|
||||
Dim nVal As Integer? = GetVal(line, "TIME")
|
||||
nTotTime = (If(Not IsNothing(nVal), nVal.Value, 0))
|
||||
ProcessResultList.Add(ProcessResult.CreateTimeResult(cutId, nTotTime))
|
||||
'If Bar.nBarType = ProjectType.PROJ AndAlso Not IsNothing(currBTLPart) Then
|
||||
' EgtSetInfo(currBTLPart.nPartId, If(Bar.nBarType = ProjectType.PROJ, ITG_PROJ_TIME, ITG_PROD_TIME), nTotTime, True)
|
||||
'End If
|
||||
ElseIf Not String.IsNullOrWhiteSpace(line) AndAlso line <> "---" Then
|
||||
sMsg = line
|
||||
End If
|
||||
|
||||
@@ -5,24 +5,6 @@
|
||||
IsTopDockable="True" IsBottomDockable="False" IsLeftDockable="False"
|
||||
IsRightDockable="False" Style="{StaticResource ToolBar_EgtFloatingPanel}">
|
||||
|
||||
<!--<Button Content="V"
|
||||
FontSize="20"
|
||||
FontWeight="Light"
|
||||
ToolTip="{Binding Verify_ToolTip}"
|
||||
Style="{StaticResource ToolBar_Button}"
|
||||
Command="{Binding Verify_Command}"
|
||||
IsEnabled="{Binding CALCPanel_IsEnabled}">
|
||||
--><!--<Image Source="/Resources/InstrumentPanel/Analyze.png" Stretch="Uniform"/>--><!--
|
||||
</Button>
|
||||
<Button Content="Vall"
|
||||
FontSize="20"
|
||||
FontWeight="Light"
|
||||
ToolTip="{Binding Verify_ToolTip}"
|
||||
Style="{StaticResource ToolBar_Button}"
|
||||
Command="{Binding VerifyAll_Command}"
|
||||
IsEnabled="{Binding CALCPanel_IsEnabled}">
|
||||
--><!--<Image Source="/Resources/InstrumentPanel/Analyze.png" Stretch="Uniform"/>--><!--
|
||||
</Button>-->
|
||||
<Button ToolTip="{Binding Simulate_ToolTip}"
|
||||
Style="{StaticResource ToolBar_Button}"
|
||||
Command="{Binding Simulate_Command}"
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtBEAMWALL.Core.ConstMachComm
|
||||
Imports EgtBEAMWALL.Core.ConstMachComm
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
@@ -150,25 +149,13 @@ Public Class NUMAxiumComm
|
||||
Dim tc = objDReadOperatorMessage.Init(objDGroupManager.Handle)
|
||||
If tc <> 0 Then EgtOutLog("Init failed ! return code : " + tc)
|
||||
|
||||
' Initialize FXServer class DReadELS
|
||||
'objDReadELS = CreateObject("APServer.DReadELS")
|
||||
'AddHandler objDReadELS.ValueChanged, AddressOf objDReadELS_ValueChanged
|
||||
'Dim y = objDReadELS.Init(objDGroupManager.Handle)
|
||||
|
||||
objDReadPlcVarList = CreateObject("APServer.DReadPlcVarList")
|
||||
AddHandler objDReadPlcVarList.ValueChanged, AddressOf objDPlcVariables_ReadPLCVariablesChanged
|
||||
' Init & send the list of requested variables
|
||||
'tc = objDReadPlcVarList.Init(objDGroupManager.Handle)
|
||||
'If tc <> 0 Then EgtOutLog(" objDReadPlcVarList.Init() Error : " + tc)
|
||||
|
||||
'Initialize FXServer class DVariables
|
||||
objDVariables = CreateObject("APServer.DVariables")
|
||||
'AddHandler objDVariables.ValueChanged, AddressOf objDVariables_ValueChanged
|
||||
' Init & send the list of requested variables
|
||||
'Dim rc As Short = objDVariables.Init(objDGroupManager.Handle, "E80000", 0)
|
||||
AddHandler objDVariables.VariableWritten, AddressOf objDVariables_VariableWritten
|
||||
AddHandler objDVariables.ValueChanged, AddressOf objDPlcVariables_ReadVariablesChanged
|
||||
'If rc <> 0 Then EgtOutLog(" objDVariables.Init() Error : " + rc)
|
||||
|
||||
' attivo programma main
|
||||
Map.refMachManaging.Num_Axium_APServer.ActivateProg(9000)
|
||||
@@ -263,10 +250,8 @@ Public Class NUMAxiumComm
|
||||
m_MachManaging.SetConnected(True)
|
||||
m_ResultCallbackDlg(CommandTypes.CONNECT, CommandStates.OK, ResultTypes.RESULT, "")
|
||||
' avvio lettura variabili
|
||||
'MachManaging.CommandList.Add(ThreadCommand.CreateCommand(CommandTypes.READ_NUMFLEXIUM))
|
||||
StartReadList()
|
||||
StartReadPLCList()
|
||||
'StartReadELS()
|
||||
Case Else
|
||||
End Select
|
||||
End Sub
|
||||
@@ -289,7 +274,6 @@ Public Class NUMAxiumComm
|
||||
|
||||
Friend Sub SetChannel(value As Integer)
|
||||
ChangeChannel(CShort(value))
|
||||
'objDGroupManager.AxisGroup = CShort(value)
|
||||
End Sub
|
||||
|
||||
Friend Sub ActivateProg(PartProgramNumberActivate As Integer)
|
||||
@@ -305,12 +289,6 @@ Public Class NUMAxiumComm
|
||||
End Sub
|
||||
|
||||
Friend Sub StartReadList()
|
||||
'Dim AddressList() As String = (From CommVar In m_ReadingVars
|
||||
' Where Not IsNothing(CommVar) AndAlso CommVar.nType = CommVar.Types.PLC
|
||||
' Select CommVar.sAddress).ToArray()
|
||||
'm_PlcVariablesList = New ArrayList((From CommVar In m_ReadingVars
|
||||
' Where Not IsNothing(CommVar) AndAlso CommVar.nType = CommVar.Types.PLC
|
||||
' Select CommVar.sAddress).ToArray())
|
||||
Dim nPLCVarIndex As Integer = 0
|
||||
Dim PlcVariablesList As New ArrayList
|
||||
Dim sPLCVariableList = ""
|
||||
@@ -326,28 +304,10 @@ Public Class NUMAxiumComm
|
||||
nPLCVarIndex += 1
|
||||
End If
|
||||
Next
|
||||
'Dim sPLCVariableList = ""
|
||||
'For VariableIndex = 0 To PlcVariablesList.Count - 1
|
||||
' If VariableIndex <> 0 Then
|
||||
' sPLCVariableList &= ","
|
||||
' End If
|
||||
' sPLCVariableList &= """" & PlcVariablesList(VariableIndex) & """"
|
||||
'Next
|
||||
Dim _FXReturn As Short = objDVariables.Init(objDGroupManager.Handle, sPLCVariableList, 1) 'PlcVariablesList.ToArray().ToString())
|
||||
'Dim _FXReturn As Short = objDVariables.ReadVariables(PlcVariablesList.ToArray())
|
||||
|
||||
'If _FXReturn <> 0 Then
|
||||
' EgtOutLog("Error ReadVariables:" & " " & _FXReturn.ToString())
|
||||
'End If
|
||||
End Sub
|
||||
|
||||
Friend Sub StartReadPLCList()
|
||||
'Dim AddressList() As String = (From CommVar In m_ReadingVars
|
||||
' Where Not IsNothing(CommVar) AndAlso CommVar.nType = CommVar.Types.PLC
|
||||
' Select CommVar.sAddress).ToArray()
|
||||
'm_PlcVariablesList = New ArrayList((From CommVar In m_ReadingVars
|
||||
' Where Not IsNothing(CommVar) AndAlso CommVar.nType = CommVar.Types.PLC
|
||||
' Select CommVar.sAddress).ToArray())
|
||||
Dim nPLCVarIndex As Integer = 0
|
||||
Dim PlcVariablesList As New ArrayList
|
||||
Dim sPLCVariableList = ""
|
||||
@@ -366,35 +326,15 @@ Public Class NUMAxiumComm
|
||||
Next
|
||||
objDReadPlcVarList.Argument = sPLCVariableList ' "%M5.L,%M5.B"
|
||||
Dim h = objDReadPlcVarList.Init(objDGroupManager.Handle)
|
||||
'Dim _FXReturn As Short = objDVariables.ReadVariables(PlcVariablesList.ToArray())
|
||||
|
||||
'If _FXReturn <> 0 Then
|
||||
' EgtOutLog("Error ReadVariables:" & " " & _FXReturn.ToString())
|
||||
'End If
|
||||
End Sub
|
||||
|
||||
Friend Sub CloseReadList()
|
||||
'objDPlcVariables.CloseReadList()
|
||||
End Sub
|
||||
|
||||
Private Sub ReadVariablesOnce(Address As String)
|
||||
'Dim _ReadSymbolicPlcVariableOnetime As String = "Application.IOCONFIG_GLOBALS.Flexium_NCK.RCNC.General.Mode"
|
||||
'Dim _FXReturn As Int16 = objDPlcVariables.ReadVariablesOnce(10, Address)
|
||||
|
||||
'If _FXReturn <> 0 Then
|
||||
' EgtOutLog("Error ReadVariablesOnce:" & " " & _FXReturn.ToString())
|
||||
'End If
|
||||
|
||||
End Sub
|
||||
|
||||
Friend Sub WritePlcVariables(Address As String, value As String)
|
||||
'Dim _WriteSymbolicPlcVariable As String = _txtReadWritePlcVariables0.Text
|
||||
'Dim _FXReturn As Int16 = objDPlcVariables.WriteVariables2(11, Address, value)
|
||||
'
|
||||
'If _FXReturn <> 0 Then
|
||||
' EgtOutLog("Error WriteVariables2 :" & " " & _FXReturn.ToString())
|
||||
'End If
|
||||
|
||||
End Sub
|
||||
|
||||
Public Shared Function InitVar(Variable As CommVar) As CommVar
|
||||
@@ -412,7 +352,6 @@ Public Class NUMAxiumComm
|
||||
End Sub
|
||||
|
||||
Friend Sub CloseReadELS()
|
||||
'objDPlcVariables.CloseReadList()
|
||||
End Sub
|
||||
|
||||
#Region "File transfer"
|
||||
@@ -476,9 +415,6 @@ Public Class NUMAxiumComm
|
||||
Dim dValue As Double = 0
|
||||
StringToDoubleAdv(value, dValue)
|
||||
Dim rc As Short = objDVariables.WriteVariables(objDGroupManager.Handle, Address, value)
|
||||
|
||||
'If rc <> 0 Then EgtOutLog(" objDVariables.WriteVariables2() Error : " & rc)
|
||||
|
||||
Catch ex As Exception
|
||||
EgtOutLog(" objDVariables.WriteVariables2() Exception : " & ex.Message)
|
||||
End Try
|
||||
@@ -501,7 +437,6 @@ Public Class NUMAxiumComm
|
||||
|
||||
Private Sub objDGeneralFunction_ProgramActivated(ByVal nerrorCode As Short)
|
||||
EgtOutLog("Part program activated:" & " " & nerrorCode)
|
||||
'DbControllers.m_LogMachineController.Create(MachLog.CreateResultLog(CommandTypes.SENDPROG, CommandStates.OK, ResultTypes.EXECUTED, "Part program activated:" & " " & nerrorCode))
|
||||
' scrivo evento programma attivato
|
||||
DbControllers.m_LogMachineController.Create(LogEvent.CreateMachCommandLog(LogEvent.MachineCommands.PROGRAM_ACTIVATION, "", nerrorCode, DbControllers.SupervisorId))
|
||||
End Sub
|
||||
@@ -535,13 +470,6 @@ Public Class NUMAxiumComm
|
||||
End Sub
|
||||
|
||||
Private Sub _comboCncAxisChannel_SelectedIndexChanged(ByVal sender As Object, ByVal e As EventArgs)
|
||||
'Select Case _comboCncAxisChannel.SelectedItem.ToString()
|
||||
' Case "Channel 1"
|
||||
' objDGroupManager.AxisGroup = 0
|
||||
' Case "Channel 2"
|
||||
' objDGroupManager.AxisGroup = 1
|
||||
' Case Else
|
||||
'End Select
|
||||
End Sub
|
||||
|
||||
Private Sub objDGeneralFunction_VariableWritten(ByVal errorCode As Short)
|
||||
@@ -553,17 +481,12 @@ Public Class NUMAxiumComm
|
||||
End Sub
|
||||
|
||||
Private Sub objErrorHandler_ErrorOnCnc(ByVal cnc As Short, ByVal channel As Short, ByVal [set] As Short)
|
||||
'AplCncNumber.Add(cnc)
|
||||
'AplChannel.Add(channel)
|
||||
'AplSet.Add([set])
|
||||
End Sub
|
||||
|
||||
Private Sub objErrorHandler_ErrorOnOtherChannel(ByVal status As Short)
|
||||
'AplStatus = status
|
||||
End Sub
|
||||
|
||||
Private Sub objErrorHandler_Exception(ByVal status As Short)
|
||||
'ExceptStatus = status
|
||||
End Sub
|
||||
|
||||
Friend Sub objErrorHandler_ErrorFromActiveCnc2(ErrorNumber As List(Of Integer))
|
||||
@@ -653,16 +576,6 @@ Public Class NUMAxiumComm
|
||||
End Sub
|
||||
|
||||
Private Sub objDPlcVariables_ReadOnceVariablesChanged(ByVal lHandle As Integer, ByVal value As Object)
|
||||
'Dim _ObjValue As Object() = CType(value, Object())
|
||||
|
||||
'If lHandle = 10 Then
|
||||
|
||||
' For i As Integer = 0 To _ObjValue.Length - 1
|
||||
' _ReadPlcVariableOnetime(i).Invoke(CType(Function()
|
||||
' _ReadPlcVariableOnetime(i).Text = _ObjValue(i).ToString()
|
||||
' End Function, MethodInvoker))
|
||||
' Next
|
||||
'End If
|
||||
End Sub
|
||||
|
||||
Private Sub objDPlcVariables_VariablesWritten2(ByVal lHandle As Integer, ByVal errorCode As Integer)
|
||||
|
||||
@@ -60,14 +60,6 @@ Public Class NUMAxiumPcToolkitComm
|
||||
<FieldOffset(4)> Public Quantity As UInt16
|
||||
End Structure
|
||||
|
||||
'Public Structure tDNC20_Position_OPOM
|
||||
' Dim Valid As UINT8
|
||||
' Dim dummy(3) As UINT8
|
||||
' Dim Position As Int32
|
||||
' Dim ToGo As SINT32
|
||||
' Dim Offset As SINT32
|
||||
'End Structure
|
||||
|
||||
<System.Runtime.InteropServices.DllImport("LIB_UNIT2.DLL")>
|
||||
Private Shared Function SetPLCTool(ByVal conf As String) As Int16
|
||||
End Function
|
||||
@@ -255,11 +247,9 @@ Public Class NUMAxiumPcToolkitComm
|
||||
m_MachManaging.SetConnected(True)
|
||||
m_ResultCallbackDlg(CommandTypes.CONNECT, CommandStates.OK, ResultTypes.RESULT, "")
|
||||
End If
|
||||
'EgtOutLog("Activating program 9000")
|
||||
|
||||
' attivo programma main
|
||||
Map.refMachManaging.Num_Axium_PCToolkit.ActivateProg(9000)
|
||||
'EgtOutLog("Activated program 9000")
|
||||
Return True
|
||||
End Function
|
||||
|
||||
@@ -327,26 +317,6 @@ Public Class NUMAxiumPcToolkitComm
|
||||
End Sub
|
||||
|
||||
Friend Sub GetGeneralFunctions()
|
||||
'Select Case _GetConnectState
|
||||
' Case 0
|
||||
' ' Not connected
|
||||
' m_MachManaging.SetConnected(False)
|
||||
' m_ResultCallbackDlg(CommandTypes.CONNECT, CommandStates.NULL, ResultTypes.RESULT, "")
|
||||
' Case 1
|
||||
' ' Connection error
|
||||
' m_MachManaging.SetConnected(False)
|
||||
' m_ResultCallbackDlg(CommandTypes.CONNECT, CommandStates.ERROR_, ResultTypes.RESULT, "")
|
||||
' Case 2
|
||||
' ' Connected
|
||||
' m_MachManaging.SetConnected(True)
|
||||
' m_ResultCallbackDlg(CommandTypes.CONNECT, CommandStates.OK, ResultTypes.RESULT, "")
|
||||
' avvio lettura variabili
|
||||
'MachManaging.CommandList.Add(ThreadCommand.CreateCommand(CommandTypes.READ_NUMFLEXIUM))
|
||||
'StartReadList()
|
||||
'StartReadPLCList()
|
||||
'StartReadELS()
|
||||
'Case Else
|
||||
'End Select
|
||||
End Sub
|
||||
|
||||
Friend Sub Start()
|
||||
@@ -391,15 +361,12 @@ Public Class NUMAxiumPcToolkitComm
|
||||
nRes = WriteObjectVarious2(nPortFileTransfer, ACTIVE_PROG, PartProgramNumberActivate)
|
||||
If nRes <> 0 Then
|
||||
EgtOutLog("Error Activate Program: " & nRes.ToString())
|
||||
'Else
|
||||
' DbControllers.m_LogMachineController.Create(MachLog.CreateResultLog(CommandTypes.SENDPROG, CommandStates.OK, ResultTypes.EXECUTED, "Part program activated:" & " " & PartProgramNumberActivate))
|
||||
End If
|
||||
' scrivo evento programma attivato
|
||||
DbControllers.m_LogMachineController.Create(LogEvent.CreateMachCommandLog(LogEvent.MachineCommands.PROGRAM_ACTIVATION, PartProgramNumberActivate, nRes <> 0, DbControllers.SupervisorId))
|
||||
End Sub
|
||||
|
||||
Private Sub ChangeChannel(Channel As Short)
|
||||
'objErrorHandler.SetChannel(1, Channel)
|
||||
End Sub
|
||||
|
||||
Friend Sub StartReadList()
|
||||
@@ -419,10 +386,6 @@ Public Class NUMAxiumPcToolkitComm
|
||||
End If
|
||||
Next
|
||||
Dim _FXReturn As Short = objDVariables.Init(objDGroupManager.Handle, sPLCVariableList, 1) 'PlcVariablesList.ToArray().ToString())
|
||||
|
||||
'If _FXReturn <> 0 Then
|
||||
' EgtOutLog("Error ReadVariables:" & " " & _FXReturn.ToString())
|
||||
'End If
|
||||
End Sub
|
||||
|
||||
Friend Sub StartReadPLCList()
|
||||
@@ -444,24 +407,12 @@ Public Class NUMAxiumPcToolkitComm
|
||||
Next
|
||||
objDReadPlcVarList.Argument = sPLCVariableList ' "%M5.L,%M5.B"
|
||||
Dim h = objDReadPlcVarList.Init(objDGroupManager.Handle)
|
||||
|
||||
'If _FXReturn <> 0 Then
|
||||
' EgtOutLog("Error ReadVariables:" & " " & _FXReturn.ToString())
|
||||
'End If
|
||||
End Sub
|
||||
|
||||
Friend Sub CloseReadList()
|
||||
'objDPlcVariables.CloseReadList()
|
||||
End Sub
|
||||
|
||||
Private Sub ReadVariablesOnce(Address As String)
|
||||
'Dim _ReadSymbolicPlcVariableOnetime As String = "Application.IOCONFIG_GLOBALS.Flexium_NCK.RCNC.General.Mode"
|
||||
'Dim _FXReturn As Int16 = objDPlcVariables.ReadVariablesOnce(10, Address)
|
||||
|
||||
'If _FXReturn <> 0 Then
|
||||
' EgtOutLog("Error ReadVariablesOnce:" & " " & _FXReturn.ToString())
|
||||
'End If
|
||||
|
||||
End Sub
|
||||
|
||||
Friend Sub WritePlcVariables(Address As String, value As String)
|
||||
@@ -491,9 +442,6 @@ Public Class NUMAxiumPcToolkitComm
|
||||
Dim rc As Short = DNC20_WriteE5E6(m_nPortWVariables, Group, ParType, ParPos, nValue, SYN)
|
||||
EgtOutLog("WritePLCVariables - return value: " & rc)
|
||||
End Select
|
||||
|
||||
'If rc <> 0 Then EgtOutLog(" objDVariables.WriteVariables2() Error : " & rc)
|
||||
|
||||
Catch ex As Exception
|
||||
EgtOutLog("Error in DNC20_WriteE5E6: " & ex.Message)
|
||||
End Try
|
||||
@@ -514,7 +462,6 @@ Public Class NUMAxiumPcToolkitComm
|
||||
End Sub
|
||||
|
||||
Friend Sub CloseReadELS()
|
||||
'objDPlcVariables.CloseReadList()
|
||||
End Sub
|
||||
|
||||
Public Sub RefreshAllVars()
|
||||
@@ -537,38 +484,12 @@ Public Class NUMAxiumPcToolkitComm
|
||||
ElseIf nAddressNumber >= 80000 Then
|
||||
nType = eVarious4.E80000
|
||||
nAddressNumber -= 80000
|
||||
'ElseIf nAddressNumber >= 30000 Then
|
||||
' nType = eVarious4.E30000
|
||||
' nAddressNumber -= 30000
|
||||
' EgtOutLog("E30000 var trovata")
|
||||
End If
|
||||
'If nType = eVarious4.E30000 Then
|
||||
' Dim Group As UInt16 = 0
|
||||
' Dim nVal As Int32
|
||||
' Dim ObjectList As New tDNC20_ObjectList With {.ElemNum = 3,
|
||||
' .First = nAddressNumber,
|
||||
' .Quantity = 1}
|
||||
' EgtOutLog("E30000 var trovata, valori: " & nPortVariables & " " & Group & "" & ObjectList.First & " " & nVal)
|
||||
|
||||
' nret = DNC20_ReadExxxxx(nPortVariables, Group, 1, ObjectList, nVal, SYN)
|
||||
' EgtOutLog("E30000 var risultato: " & nret)
|
||||
' If nret = 0 Then
|
||||
' Var.SetValue(nVal)
|
||||
' EgtOutLog("E30000 var assegnata: " & nVal)
|
||||
' End If
|
||||
'Else
|
||||
nret = ReadObjectVarious4(nPortVariables, nType, nAddressNumber, 1, MyData, SYN)
|
||||
If nret = 0 Then
|
||||
'Var.SetValue(MyData.data(0))
|
||||
'Dim NewBytes(3) As Byte
|
||||
'For nBIndex = 3 To 0 Step -1
|
||||
' NewBytes(3 - nBIndex) = MyData.data(nBIndex)
|
||||
'Next
|
||||
Dim nVal As Integer = BitConverter.ToInt32(MyData.data, 0)
|
||||
Var.SetValue(nVal)
|
||||
End If
|
||||
'End If
|
||||
'EgtOutLog("Variabile: " & Var.sAddress & " Tipo: " & nType & " NAddres: " & nAddressNumber & " Valore: " & nVal)
|
||||
ElseIf Var.nType = CommVar.Types.PLC Then
|
||||
Dim nRet As Short = -1
|
||||
Dim nRes As Integer
|
||||
@@ -576,7 +497,6 @@ Public Class NUMAxiumPcToolkitComm
|
||||
Case "%R3.2"
|
||||
nRet = ReadLadderVar(nPortVariables, R2, &H3, 1, MyData, SYN)
|
||||
nRes = If(MyData.data(0) <> 0, 1, 0)
|
||||
'EgtOutLog("Variabile: " & Var.sAddress & "DVal: " & nRes & " Valore: " & MyData.data(0) & "," & MyData.data(1) & "," & MyData.data(2) & "," & MyData.data(3))
|
||||
Case "%R3.1"
|
||||
nRet = ReadLadderVar(nPortVariables, R1, &H3, 1, MyData, SYN)
|
||||
nRes = If(MyData.data(0) <> 0, 1, 0)
|
||||
@@ -625,7 +545,6 @@ Public Class NUMAxiumPcToolkitComm
|
||||
End If
|
||||
End Select
|
||||
If nRet = 0 Then
|
||||
'EgtOutLog("Variabile: " & Var.sAddress & "DVal: " & nRes & " Valore: " & MyData.data(0) & "," & MyData.data(1) & "," & MyData.data(2) & "," & MyData.data(3))
|
||||
EgtOutLog("Variabile: " & Var.sAddress & "DVal: " & nRes)
|
||||
Var.SetValue(nRes)
|
||||
End If
|
||||
@@ -699,12 +618,6 @@ Public Class NUMAxiumPcToolkitComm
|
||||
Try
|
||||
ISONumVariable.sValue = SentMachGroup.Name
|
||||
ISOSentVariable.sValue = 0
|
||||
'Dim TempISOSentVariable As Variable = Map.refMachCommandMessagePanelVM.MainVariablesList.FirstOrDefault(Function(x) x.sName = ISO_SENT)
|
||||
'While ISOSentVariable.sValue <> "0"
|
||||
' Threading.Thread.Sleep(100)
|
||||
' EgtOutLog("Bloccato - Sent(80046): " & TempISOSentVariable.sValue & " Num(80045): " & ISONumVariable.sValue)
|
||||
' TempISOSentVariable = Map.refMachCommandMessagePanelVM.MainVariablesList.FirstOrDefault(Function(x) x.sName = ISO_SENT)
|
||||
'End While
|
||||
SentMachGroup.SetSentToMachine(True)
|
||||
Catch ex As Exception
|
||||
EgtOutLog("Error write var after download: " & ex.Message)
|
||||
@@ -720,51 +633,9 @@ Public Class NUMAxiumPcToolkitComm
|
||||
End Sub)
|
||||
' avvio thread di gestione della macchina che avvia la connessione
|
||||
FileTransferThread.Start()
|
||||
|
||||
|
||||
'Dim nRes As Int16 = -1
|
||||
'Dim nIndex As Int16 = 0
|
||||
'nRes = DownLoadFileAsyn(nPortFileTransfer, sFileType, sFilePath, DNC_MODE_FIRST, nIndex)
|
||||
'm_BytesTransferedCounter = nIndex
|
||||
'If nRes <> DNC_IN_PROGRES Then
|
||||
' EgtOutLog("DownLoadFileAsyn error:" & nRes)
|
||||
' nRes = DownLoadFileAsyn(nPortFileTransfer, sFileType, sFilePath, DNC_MODE_ABORT, nIndex)
|
||||
' m_BytesTransferedCounter = 0
|
||||
' Return
|
||||
'End If
|
||||
'While nRes = DNC_IN_PROGRES
|
||||
' nRes = DownLoadFileAsyn(nPortFileTransfer, sFileType, sFilePath, DNC_MODE_CONTINUE, nIndex)
|
||||
' m_BytesTransferedCounter = nIndex
|
||||
' Map.refMyStatusBarVM.SetOutputMessage("Bytes sent: ", 2)
|
||||
'End While
|
||||
'If nRes <> 0 Then
|
||||
' EgtOutLog("DownLoadFileAsyn error: " & nRes)
|
||||
' Map.refMyStatusBarVM.SetOutputMessage("DownLoadFileAsyn error: " & nRes, 2)
|
||||
'Else
|
||||
' EgtOutLog("DownLoadFileAsyn OK")
|
||||
' Map.refMyStatusBarVM.SetOutputMessage("DownLoadFileAsyn OK", 2)
|
||||
' ' aggiorno variabili del MAIN
|
||||
' Dim ISONumVariable As Variable = Map.refMachCommandMessagePanelVM.MainVariablesList.FirstOrDefault(Function(x) x.sName = ISO_NUM)
|
||||
' Dim ISOSentVariable As Variable = Map.refMachCommandMessagePanelVM.MainVariablesList.FirstOrDefault(Function(x) x.sName = ISO_SENT)
|
||||
' Dim SentMachGroup As MyMachGroupVM = Map.refSupervisorMachGroupPanelVM.MachGroupVMList.FirstOrDefault(Function(x As MyMachGroupVM) x.bSendingToMachine)
|
||||
' If Not IsNothing(SentMachGroup) Then
|
||||
' ISONumVariable.sValue = SentMachGroup.Name
|
||||
' ISOSentVariable.sValue = 0
|
||||
' SentMachGroup.SetSentToMachine(True)
|
||||
' End If
|
||||
'End If
|
||||
'nRes = DownLoadFileAsyn(nPortFileTransfer, sFileType, sFilePath, DNC_MODE_ABORT, nIndex)
|
||||
'm_BytesTransferedCounter = 0
|
||||
'Return
|
||||
End Sub
|
||||
|
||||
Private Sub FileUpload(sFileType As String, sFilePath As String)
|
||||
'Dim _Return_Upload As Short
|
||||
'_Return_Upload = objDFileTransfer.FileUpload(20, sFileType, sFilePath, "")
|
||||
|
||||
'If _Return_Upload <> 0 Then
|
||||
' EgtOutLog("Error: File not stored to the job list:" & " " & _Return_Upload.ToString())
|
||||
'End If
|
||||
End Sub
|
||||
|
||||
Friend Sub FileDelete(sFileType As String, sFilePath As String)
|
||||
@@ -817,9 +688,6 @@ Public Class NUMAxiumPcToolkitComm
|
||||
MyData.data = BitConverter.GetBytes(CLng(nValue))
|
||||
EgtOutLog("WriteNCVariables - nType: " & nType & " nFirst: " & nAddressNumber & " Data: " & nValue)
|
||||
Dim rc As Short = WriteObjectVarious4(nPortWVariables, nType, nAddressNumber, 1, nValue)
|
||||
|
||||
'If rc <> 0 Then EgtOutLog(" objDVariables.WriteVariables2() Error : " & rc)
|
||||
|
||||
Catch ex As Exception
|
||||
EgtOutLog("Error in WriteObjectVarious4: " & ex.Message)
|
||||
End Try
|
||||
@@ -869,13 +737,6 @@ Public Class NUMAxiumPcToolkitComm
|
||||
End Sub
|
||||
|
||||
Private Sub _comboCncAxisChannel_SelectedIndexChanged(ByVal sender As Object, ByVal e As EventArgs)
|
||||
'Select Case _comboCncAxisChannel.SelectedItem.ToString()
|
||||
' Case "Channel 1"
|
||||
' objDGroupManager.AxisGroup = 0
|
||||
' Case "Channel 2"
|
||||
' objDGroupManager.AxisGroup = 1
|
||||
' Case Else
|
||||
'End Select
|
||||
End Sub
|
||||
|
||||
Private Sub objDGeneralFunction_VariableWritten(ByVal errorCode As Short)
|
||||
@@ -887,17 +748,12 @@ Public Class NUMAxiumPcToolkitComm
|
||||
End Sub
|
||||
|
||||
Private Sub objErrorHandler_ErrorOnCnc(ByVal cnc As Short, ByVal channel As Short, ByVal [set] As Short)
|
||||
'AplCncNumber.Add(cnc)
|
||||
'AplChannel.Add(channel)
|
||||
'AplSet.Add([set])
|
||||
End Sub
|
||||
|
||||
Private Sub objErrorHandler_ErrorOnOtherChannel(ByVal status As Short)
|
||||
'AplStatus = status
|
||||
End Sub
|
||||
|
||||
Private Sub objErrorHandler_Exception(ByVal status As Short)
|
||||
'ExceptStatus = status
|
||||
End Sub
|
||||
|
||||
Friend Sub objErrorHandler_ErrorFromActiveCnc2(ErrorNumber As List(Of Integer))
|
||||
@@ -942,7 +798,6 @@ Public Class NUMAxiumPcToolkitComm
|
||||
End If
|
||||
Next
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
#Region "PLC Variables"
|
||||
@@ -988,16 +843,6 @@ Public Class NUMAxiumPcToolkitComm
|
||||
End Sub
|
||||
|
||||
Private Sub objDPlcVariables_ReadOnceVariablesChanged(ByVal lHandle As Integer, ByVal value As Object)
|
||||
'Dim _ObjValue As Object() = CType(value, Object())
|
||||
|
||||
'If lHandle = 10 Then
|
||||
|
||||
' For i As Integer = 0 To _ObjValue.Length - 1
|
||||
' _ReadPlcVariableOnetime(i).Invoke(CType(Function()
|
||||
' _ReadPlcVariableOnetime(i).Text = _ObjValue(i).ToString()
|
||||
' End Function, MethodInvoker))
|
||||
' Next
|
||||
'End If
|
||||
End Sub
|
||||
|
||||
Private Sub objDPlcVariables_VariablesWritten2(ByVal lHandle As Integer, ByVal errorCode As Integer)
|
||||
@@ -1037,46 +882,15 @@ Public Class NUMAxiumPcToolkitComm
|
||||
Dim AxisValid(8) As Boolean
|
||||
For AxisIndex = 0 To 8
|
||||
Dim AxisStart = AxisIndex * 16
|
||||
'Dim NbDeci, FacConv As UInt16
|
||||
'NbDeci = MyData.data(AxisStart) And &H3F
|
||||
'Select Case NbDeci
|
||||
' Case 0
|
||||
' FacConv = 1
|
||||
' 'FormatStr = "%9.0f"
|
||||
' Case 1
|
||||
' FacConv = 10
|
||||
' 'FormatStr = "%9.1f "
|
||||
' Case 2
|
||||
' FacConv = 100
|
||||
' 'FormatStr = "%9.2f "
|
||||
' Case 3
|
||||
' FacConv = 1000
|
||||
' 'FormatStr = "%9.3f "
|
||||
' Case 4
|
||||
' FacConv = 10000
|
||||
' 'FormatStr = "%9.4f "
|
||||
' Case Else
|
||||
' FacConv = 1000
|
||||
' 'FormatStr = "%9.3f "
|
||||
'End Select
|
||||
|
||||
''printf("%2x ", Data[i].Valid);
|
||||
'If MyData.data(AxisStart) And &H80 Then
|
||||
' Dim dAxisPosition As Double = (BitConverter.ToInt32(MyData.data, AxisStart + 4)) / FacConv 'Vmminch ' X
|
||||
' m_AxisCoordinatesCallbackDlg(dAxisPosition, AxisIndex)
|
||||
'End If
|
||||
|
||||
Dim n As Integer = AxisIndex * 16
|
||||
AxisValid(AxisIndex) = (MyData.data(n) <> 0)
|
||||
If AxisValid(AxisIndex) Then
|
||||
If AxisIndex < 6 Then
|
||||
Dim dAxisPosition As Double = (BitConverter.ToInt32(MyData.data, n + 4)) 'Vmminch ' X
|
||||
m_AxisCoordinatesCallbackDlg(dAxisPosition, AxisIndex)
|
||||
'd_axis_delta(i) = (BitConverter.ToInt32(MyData.data, n + 8)) / Vmminch
|
||||
Else
|
||||
Dim dAxisPosition As Double = (BitConverter.ToInt32(MyData.data, n + 4)) 'NumCifreDecP4 ' A
|
||||
m_AxisCoordinatesCallbackDlg(dAxisPosition, AxisIndex)
|
||||
'd_axis_delta(i) = (BitConverter.ToInt32(MyData.data, n + 8)) / NumCifreDecP4
|
||||
End If
|
||||
End If
|
||||
Next
|
||||
@@ -1121,9 +935,7 @@ Public Class NUMAxiumPcToolkitComm
|
||||
Friend Sub ReadCncMode()
|
||||
Dim nRet As Short = -1
|
||||
Dim nMode As UInt16
|
||||
'EgtOutLog("Pre ReadObjectVarious2")
|
||||
nRet = ReadObjectVarious2(nPortVariables, eVarious2.MODE, nMode, SYN)
|
||||
'EgtOutLog("ReadObjectVarious2 Ret: " & nRet & " Mode: " & nMode)
|
||||
If nRet <> 0 Then
|
||||
EgtOutLog("Reading CncMode failed! Error: " & nRet)
|
||||
Return
|
||||
|
||||
@@ -111,9 +111,6 @@ Public Class NUMFlexiumComm
|
||||
AddHandler objErrorHandler.ErrorOnCnc, AddressOf objErrorHandler_ErrorOnCnc
|
||||
AddHandler objErrorHandler.ErrorOnOtherChannel, AddressOf objErrorHandler_ErrorOnOtherChannel
|
||||
AddHandler objErrorHandler.Exception, AddressOf objErrorHandler_Exception
|
||||
'Initialisation config for testing
|
||||
'Accepting all messages
|
||||
'Consult the documentation for detailed information
|
||||
|
||||
objErrorHandler.AllError = 1
|
||||
objErrorHandler.ErrorGlobal = 0
|
||||
@@ -122,7 +119,6 @@ Public Class NUMFlexiumComm
|
||||
objErrorHandler.AcceptException(0)
|
||||
|
||||
objDPlcVariables = New FXServer.DPlcVariables()
|
||||
'objDPlcVariables.Symbols += New FXServer.IDPlcVariablesEvents_SymbolsEventHandler(AddressOf objDPlcVariables_Symbols)
|
||||
AddHandler objDPlcVariables.ReadVariablesChanged, AddressOf objDPlcVariables_ReadVariablesChanged
|
||||
AddHandler objDPlcVariables.InvalidReadList, AddressOf objDPlcVariables_InvalidReadList
|
||||
AddHandler objDPlcVariables.AbortReadVariables, AddressOf objDPlcVariables_AbortReadVariables
|
||||
@@ -149,13 +145,7 @@ Public Class NUMFlexiumComm
|
||||
objDFileTransfer.Init(objDGroupManager.Handle)
|
||||
|
||||
objDPosition = New FXServer.DPosition()
|
||||
'objDPosition.ValidAxisChanged += New FXServer.IDPositionEvents_ValidAxisChangedEventHandler(AddressOf objDPosition_ValidAxisChanged)
|
||||
AddHandler objDPosition.PositionChanged, AddressOf objDPosition_PositionChanged
|
||||
'objDPosition.DeltaChanged += New FXServer.IDPositionEvents_DeltaChangedEventHandler(AddressOf objDPosition_DeltaChanged)
|
||||
'objDPosition.ReadOnceValidAxisChanged += New FXServer.IDPositionEvents_ReadOnceValidAxisChangedEventHandler(AddressOf objDPosition_ReadOnceValidAxisChanged)
|
||||
'objDPosition.ReadOncePositionChanged += New FXServer.IDPositionEvents_ReadOncePositionChangedEventHandler(AddressOf objDPosition_ReadOncePositionChanged)
|
||||
'objDPosition.ReadOnceDeltaChanged += New FXServer.IDPositionEvents_ReadOnceDeltaChangedEventHandler(AddressOf objDPosition_ReadOnceDeltaChanged)
|
||||
'objDPosition.EndposChanged += New FXServer.IDPositionEvents_EndposChangedEventHandler(AddressOf objDPosition_EndposChanged)
|
||||
|
||||
objDPosition.Flag = 0
|
||||
objDPosition.ModeOP = 0
|
||||
@@ -169,8 +159,6 @@ Public Class NUMFlexiumComm
|
||||
|
||||
'Initialize FXServer class DVariables
|
||||
objDVariables = New FXServer.DVariables()
|
||||
'AddHandler objDVariables.ValueChanged, AddressOf objDVariables_ValueChanged
|
||||
'AddHandler objDVariables.ValueChanged2, AddressOf objDVariables_ValueChanged2
|
||||
AddHandler objDVariables.VariableWritten, AddressOf objDVariables_VariableWritten
|
||||
AddHandler objDVariables.VariableWritten2, AddressOf objDVariables_VariableWritten2
|
||||
' Init & send the list of requested variables
|
||||
@@ -234,8 +222,6 @@ Public Class NUMFlexiumComm
|
||||
' Connected
|
||||
m_MachManaging.SetConnected(True)
|
||||
m_ResultCallbackDlg(CommandTypes.CONNECT, CommandStates.OK, ResultTypes.RESULT, "")
|
||||
' avvio lettura variabili
|
||||
'MachManaging.CommandList.Add(ThreadCommand.CreateCommand(CommandTypes.READ_NUMFLEXIUM))
|
||||
StartReadList()
|
||||
StartReadELS()
|
||||
Case Else
|
||||
@@ -269,35 +255,12 @@ Public Class NUMFlexiumComm
|
||||
EgtOutLog("Error Activate Program:" & " " & _FXReturn.ToString())
|
||||
End If
|
||||
End Sub
|
||||
'Private Sub WriteVariable(ByVal sender As Object, ByVal e As EventArgs)
|
||||
' Dim _E80011FxStd As Int32 = 88888
|
||||
' Dim _FXReturn As Short = objDGeneralFunction.WriteVariable("E80011", _E80011FxStd)
|
||||
|
||||
' If _FXReturn <> 0 Then
|
||||
' MessageBox.Show("Error from WriteVariable:" & " " & _FXReturn.ToString())
|
||||
' End If
|
||||
'End Sub
|
||||
|
||||
'Private Sub WriteVariable2(ByVal sender As Object, ByVal e As EventArgs)
|
||||
' Dim _E80010FxPlus As Double = 51515.6161
|
||||
' Dim _FXReturn As Short = objDGeneralFunction.WriteVariable2("E80010", _E80010FxPlus)
|
||||
|
||||
' If _FXReturn <> 0 Then
|
||||
' MessageBox.Show("Error from WriteVariable2:" & " " & _FXReturn.ToString())
|
||||
' End If
|
||||
'End Sub
|
||||
|
||||
Private Sub ChangeChannel(Channel As Short)
|
||||
objErrorHandler.SetChannel(0, Channel)
|
||||
End Sub
|
||||
|
||||
Friend Sub StartReadList()
|
||||
'Dim AddressList() As String = (From CommVar In m_ReadingVars
|
||||
' Where Not IsNothing(CommVar) AndAlso CommVar.nType = CommVar.Types.PLC
|
||||
' Select CommVar.sAddress).ToArray()
|
||||
'm_PlcVariablesList = New ArrayList((From CommVar In m_ReadingVars
|
||||
' Where Not IsNothing(CommVar) AndAlso CommVar.nType = CommVar.Types.PLC
|
||||
' Select CommVar.sAddress).ToArray())
|
||||
Dim nPLCVarIndex As Integer = 0
|
||||
Dim PlcVariablesList As New ArrayList
|
||||
For VarIndex = 0 To m_ReadingVars.Length - 1
|
||||
@@ -311,9 +274,6 @@ Public Class NUMFlexiumComm
|
||||
nPLCVarIndex += 1
|
||||
End If
|
||||
Next
|
||||
'm_PlcVariablesList.Add("Application.IOCONFIG_GLOBALS.Flexium_NCK.RCNC.General.Start")
|
||||
'm_PlcVariablesList.Add("Application.IOCONFIG_GLOBALS.Flexium_NCK.RCNC.General.Stop")
|
||||
'Dim AddressList As String = "Application.IOCONFIG_GLOBALS.Flexium_NCK.RCNC.General.Start;Application.IOCONFIG_GLOBALS.Flexium_NCK.RCNC.General.Stop"
|
||||
|
||||
Dim _FXReturn As Short = objDPlcVariables.ReadVariables(PlcVariablesList.ToArray())
|
||||
|
||||
@@ -327,7 +287,6 @@ Public Class NUMFlexiumComm
|
||||
End Sub
|
||||
|
||||
Private Sub ReadVariablesOnce(Address As String)
|
||||
'Dim _ReadSymbolicPlcVariableOnetime As String = "Application.IOCONFIG_GLOBALS.Flexium_NCK.RCNC.General.Mode"
|
||||
Dim _FXReturn As Int16 = objDPlcVariables.ReadVariablesOnce(10, Address)
|
||||
|
||||
If _FXReturn <> 0 Then
|
||||
@@ -337,7 +296,6 @@ Public Class NUMFlexiumComm
|
||||
End Sub
|
||||
|
||||
Friend Sub WritePlcVariables(Address As String, value As String)
|
||||
'Dim _WriteSymbolicPlcVariable As String = _txtReadWritePlcVariables0.Text
|
||||
Dim _FXReturn As Int16 = objDPlcVariables.WriteVariables2(11, Address, value)
|
||||
|
||||
If _FXReturn <> 0 Then
|
||||
@@ -368,31 +326,6 @@ Public Class NUMFlexiumComm
|
||||
|
||||
Friend Sub FileDownload(sFileType As String, sFilePath As String)
|
||||
Dim _Return_Download As Short
|
||||
'' leggo variabile E30099
|
||||
'Dim SendPermissionVariable As Variable = Map.refMachCommandMessagePanelVM.MainVariablesList.FirstOrDefault(Function(x) x.sName = SENDPERMISSION)
|
||||
'Dim dTemp As Double = 0
|
||||
'Dim nSendPermission As Integer = 0
|
||||
'EgtOutLog("Inizio invio programma")
|
||||
'While nSendPermission <> 2
|
||||
' Dim bFirstWriteOne = True
|
||||
' EgtOutLog("Inizio ciclo verifica diverso da 2")
|
||||
' ' leggo valore
|
||||
' If Not IsNothing(SendPermissionVariable.sValue) Then
|
||||
' StringToDoubleAdv(SendPermissionVariable.sValue, dTemp)
|
||||
' Integer.TryParse(dTemp, nSendPermission)
|
||||
' EgtOutLog("Lettura variabile E30099: " & nSendPermission)
|
||||
' Else
|
||||
' EgtOutLog("nSendPermission = -1")
|
||||
' nSendPermission = -1
|
||||
' End If
|
||||
' ' se uguale a zero ci scrivo uno
|
||||
' If nSendPermission = 0 And bFirstWriteOne Then
|
||||
' bFirstWriteOne = False
|
||||
' SendPermissionVariable.sValue = 1
|
||||
' EgtOutLog("Scrittura variabile E30099 = 1")
|
||||
' End If
|
||||
' Threading.Thread.Sleep(1000)
|
||||
'End While
|
||||
|
||||
_Return_Download = objDFileTransfer.FileDownload2(10, sFileType, sFilePath, "", 1, 0)
|
||||
|
||||
@@ -476,7 +409,6 @@ Public Class NUMFlexiumComm
|
||||
|
||||
Private Sub objDGeneralFunction_ProgramActivated(ByVal nerrorCode As Short)
|
||||
EgtOutLog("Part program activated:" & " " & nerrorCode)
|
||||
'DbControllers.m_LogMachineController.Create(MachLog.CreateResultLog(CommandTypes.SENDPROG, CommandStates.OK, ResultTypes.EXECUTED, "Part program activated:" & " " & nerrorCode))
|
||||
' scrivo evento programma attivato
|
||||
DbControllers.m_LogMachineController.Create(LogEvent.CreateMachCommandLog(LogEvent.MachineCommands.PROGRAM_ACTIVATION, "", nerrorCode, DbControllers.SupervisorId))
|
||||
End Sub
|
||||
@@ -510,13 +442,6 @@ Public Class NUMFlexiumComm
|
||||
End Sub
|
||||
|
||||
Private Sub _comboCncAxisChannel_SelectedIndexChanged(ByVal sender As Object, ByVal e As EventArgs)
|
||||
'Select Case _comboCncAxisChannel.SelectedItem.ToString()
|
||||
' Case "Channel 1"
|
||||
' objDGroupManager.AxisGroup = 0
|
||||
' Case "Channel 2"
|
||||
' objDGroupManager.AxisGroup = 1
|
||||
' Case Else
|
||||
'End Select
|
||||
End Sub
|
||||
|
||||
Private Sub objDGeneralFunction_VariableWritten(ByVal errorCode As Short)
|
||||
@@ -528,17 +453,12 @@ Public Class NUMFlexiumComm
|
||||
End Sub
|
||||
|
||||
Private Sub objErrorHandler_ErrorOnCnc(ByVal cnc As Short, ByVal channel As Short, ByVal [set] As Short)
|
||||
'AplCncNumber.Add(cnc)
|
||||
'AplChannel.Add(channel)
|
||||
'AplSet.Add([set])
|
||||
End Sub
|
||||
|
||||
Private Sub objErrorHandler_ErrorOnOtherChannel(ByVal status As Short)
|
||||
'AplStatus = status
|
||||
End Sub
|
||||
|
||||
Private Sub objErrorHandler_Exception(ByVal status As Short)
|
||||
'ExceptStatus = status
|
||||
End Sub
|
||||
|
||||
Private Sub objErrorHandler_ErrorFromActiveCnc2(ByVal CncNumber As Short, ByVal numberOfError As Short, ByVal ErrorTyp As Object, ByVal ErrorIndex As Object, ByVal ErrorNumber As Object, ByVal ErrorLine As Object, ByVal ErrorMessage As Object, ByVal ErrorAdditional As Object)
|
||||
@@ -624,16 +544,6 @@ Public Class NUMFlexiumComm
|
||||
End Sub
|
||||
|
||||
Private Sub objDPlcVariables_ReadOnceVariablesChanged(ByVal lHandle As Integer, ByVal value As Object)
|
||||
'Dim _ObjValue As Object() = CType(value, Object())
|
||||
|
||||
'If lHandle = 10 Then
|
||||
|
||||
' For i As Integer = 0 To _ObjValue.Length - 1
|
||||
' _ReadPlcVariableOnetime(i).Invoke(CType(Function()
|
||||
' _ReadPlcVariableOnetime(i).Text = _ObjValue(i).ToString()
|
||||
' End Function, MethodInvoker))
|
||||
' Next
|
||||
'End If
|
||||
End Sub
|
||||
|
||||
Private Sub objDPlcVariables_VariablesWritten2(ByVal lHandle As Integer, ByVal errorCode As Integer)
|
||||
@@ -701,16 +611,12 @@ Public Class NUMFlexiumComm
|
||||
|
||||
m_ReadingVars(nHandle - 1).SetValue(sValue)
|
||||
|
||||
'_ELS(nHandle - 1, 1).Text = sValue
|
||||
'_ELS(nHandle - 1, 2).Text = (CType(DataType, eDatatype)).ToString()
|
||||
'_ELS(nHandle - 1, 3).Text = If(Writable = 0, "No", If(Writable = 1, "Yes", Writable.ToString()))
|
||||
Catch Ex As Exception
|
||||
EgtOutLog("objDReadELS_ValueChanged3 " & Ex.Message & " Handle : " + nHandle)
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
Private Sub objDReadELS_ValueChanged(ByVal nHandle As Short, ByVal dValue As Double, ByVal nerrorCode As Short)
|
||||
'Throw New NotImplementedException()
|
||||
End Sub
|
||||
|
||||
#End Region ' ReadELS
|
||||
@@ -798,104 +704,6 @@ Public Class NUMFlexiumComm
|
||||
End If
|
||||
End Sub
|
||||
|
||||
'Private Sub objDVariables_ValueChanged(ByVal vtArrayIndex As Object, ByVal vtArrayValues As Object)
|
||||
' Dim AplArrayIndex As Object() = CType(vtArrayIndex, Object())
|
||||
' Dim AplArrayValue As Object() = CType(vtArrayValues, Object())
|
||||
' Dim Idx As Int16
|
||||
' If IsFlexiumPlus Then Return
|
||||
|
||||
' For index As Integer = 0 To AplArrayIndex.Length - 1
|
||||
|
||||
' Try
|
||||
' Idx = CType(AplArrayIndex.GetValue(index), Int16)
|
||||
' If Idx > 8 Then Exit For
|
||||
' _Variables(Idx, 1).Invoke(CType(Function()
|
||||
' _Variables(Idx, 1).Text = (CDbl(AplArrayValue.GetValue(index))).ToString()
|
||||
' End Function, MethodInvoker))
|
||||
' Catch Ex As Exception
|
||||
' DisplayMessage(Ex.Message)
|
||||
' End Try
|
||||
' Next
|
||||
'End Sub
|
||||
|
||||
'Private Sub objDVariables_ValueChanged2(ByVal vtArrayIndex As Object, ByVal vtArrayValues As Object)
|
||||
' Dim AplArrayIndex As Object() = CType(vtArrayIndex, Object())
|
||||
' Dim AplArrayValue As Object() = CType(vtArrayValues, Object())
|
||||
' Dim index, IdxVar, IdxData, Idx As Int16, Datatype As Int16 = -1
|
||||
' Dim _objValue As Object = Nothing
|
||||
' Dim sValue As String
|
||||
|
||||
' For index = 0 To AplArrayIndex.Length - 1
|
||||
|
||||
' Try
|
||||
' Idx = CType(AplArrayIndex.GetValue(index), Int16)
|
||||
' IdxVar = CShort((Idx / 10))
|
||||
' IdxData = CShort((Idx Mod 10))
|
||||
' If IdxData < 0 OrElse IdxData > 2 OrElse IdxVar > 8 Then Continue For
|
||||
|
||||
' Select Case IdxData
|
||||
' Case 0
|
||||
' _objValue = AplArrayValue.GetValue(index)
|
||||
' Case 1
|
||||
' Me.Invoke(CType(Function()
|
||||
' _Variables(IdxVar, 2).Tag = CShort(AplArrayValue.GetValue(index))
|
||||
' _Variables(IdxVar, 2).Text = (CType(AplArrayValue.GetValue(index), eDatatype)).ToString()
|
||||
' End Function, MethodInvoker))
|
||||
' Case 2
|
||||
' Me.Invoke(CType(Function()
|
||||
' _Variables(IdxVar, 3).Text = If((CShort(AplArrayValue.GetValue(index))) = 0, "No", If((CShort(AplArrayValue.GetValue(index))) = 1, "Yes", (CShort(AplArrayValue.GetValue(index))).ToString()))
|
||||
' End Function, MethodInvoker))
|
||||
' End Select
|
||||
|
||||
' Me.Invoke(CType(Function()
|
||||
' Datatype = If(_Variables(IdxVar, 2).Tag IsNot Nothing, CShort(_Variables(IdxVar, 2).Tag), CShort(-2))
|
||||
' End Function, MethodInvoker))
|
||||
|
||||
' If IdxData = 1 OrElse IdxData = 0 AndAlso Datatype <> -1 Then
|
||||
|
||||
' Select Case Datatype
|
||||
' Case 0
|
||||
' sValue = (CSByte(_objValue)).ToString()
|
||||
' Case 1
|
||||
' sValue = (CByte(_objValue)).ToString()
|
||||
' Case 2
|
||||
' sValue = (CType(_objValue, Int16)).ToString()
|
||||
' Case 3
|
||||
' sValue = (CType(_objValue, UInt16)).ToString()
|
||||
' Case 4
|
||||
' sValue = (CType(_objValue, Int32)).ToString()
|
||||
' Case 5
|
||||
' sValue = (CType(_objValue, UInt32)).ToString()
|
||||
' Case 6
|
||||
' sValue = (CDbl(_objValue)).ToString()
|
||||
' Case 7
|
||||
' sValue = (CBool(_objValue)).ToString()
|
||||
' Case 8
|
||||
' sValue = (CBool(_objValue)).ToString()
|
||||
' Case 9
|
||||
' sValue = (CBool(_objValue)).ToString()
|
||||
' Case 10
|
||||
' sValue = (CType(_objValue, Int64)).ToString()
|
||||
' Case 11
|
||||
' sValue = (CType(_objValue, UInt32)).ToString()
|
||||
' Case -1
|
||||
' sValue = (CType(_objValue, Int32)).ToString()
|
||||
' Case Else
|
||||
' sValue = String.Empty
|
||||
' DisplayMessage("objDVariables_ValueChanged2() : Unknown Datatype !")
|
||||
' End Select
|
||||
|
||||
' Me.Invoke(CType(Function()
|
||||
' _Variables(IdxVar, 1).Text = sValue
|
||||
' End Function, MethodInvoker))
|
||||
' End If
|
||||
|
||||
' Catch Ex As Exception
|
||||
' DisplayMessage("objDVariables_ValueChanged2 " & Ex.Message & " Index : " + index)
|
||||
' End Try
|
||||
' Next
|
||||
'End Sub
|
||||
|
||||
#End Region ' Variables
|
||||
|
||||
#Region "CNCMode"
|
||||
|
||||
@@ -68,7 +68,6 @@ Public Class TPAComm
|
||||
Private m_Proxy_ListInfoEventHandler As New ListInfoEventHandler(AddressOf RemoteObject_ListInfoResponse)
|
||||
Private m_Proxy_RPCUpdateEventHandler As New RPCUpdateEventHandler(AddressOf RemoteObject_RPCUpdate)
|
||||
Private m_Proxy_VariableCommandExecutedEventHandler As New VariableCommandExecutedEventHandler(AddressOf RemoteObject_VariableCommandExecuted)
|
||||
'Private m_Proxy_TickUpdateEventHandler As New TickUpdateEventHandler(AddressOf RemoteObject_TickUpdate)
|
||||
Private m_Rem_CommandExecutedEventHandler As CommandExecutedEventHandler
|
||||
Private m_Rem_ServerErrorEventHandler As ServerErrorEventHandler
|
||||
Private m_Rem_AxesCoordinatesUpdateEventHandler As AxesCoordinatesUpdateEventHandler
|
||||
@@ -77,7 +76,6 @@ Public Class TPAComm
|
||||
Private m_Rem_ListInfoEventHandler As ListInfoEventHandler
|
||||
Private m_Rem_RPCUpdateEventHandler As RPCUpdateEventHandler
|
||||
Private m_Rem_VariableCommandExecutedEventHandler As VariableCommandExecutedEventHandler
|
||||
'Private m_Rem_TickUpdateEventHandler As TickUpdateEventHandler
|
||||
|
||||
<SecurityPermission(SecurityAction.Demand)>
|
||||
Public Sub New(MachManaging As MachManaging)
|
||||
@@ -110,7 +108,6 @@ Public Class TPAComm
|
||||
AddHandler m_eventProxy.ListInfoResponse, m_Proxy_ListInfoEventHandler
|
||||
AddHandler m_eventProxy.RPCUpdate, m_Proxy_RPCUpdateEventHandler
|
||||
AddHandler m_eventProxy.VariableCommandExecuted, m_Proxy_VariableCommandExecutedEventHandler
|
||||
'AddHandler m_eventProxy.TickUpdate, m_Proxy_TickUpdateEventHandler
|
||||
|
||||
_remObject = CType(Activator.GetObject(GetType(ISOCNC.Remoting_Server), serverURI), ISOCNC.Remoting_Server)
|
||||
Try
|
||||
@@ -122,7 +119,6 @@ Public Class TPAComm
|
||||
m_Rem_ListInfoEventHandler = New ListInfoEventHandler(AddressOf m_eventProxy.LocallyHandleListInfo)
|
||||
m_Rem_RPCUpdateEventHandler = New RPCUpdateEventHandler(AddressOf m_eventProxy.LocallyHandleRPCUpdate)
|
||||
m_Rem_VariableCommandExecutedEventHandler = New VariableCommandExecutedEventHandler(AddressOf m_eventProxy.LocallyHandleVariableCommandExecuted)
|
||||
'm_Rem_TickUpdateEventHandler = New TickUpdateEventHandler(AddressOf m_eventProxy.LocallyHandleTickUpdate)
|
||||
AddHandler _remObject.CommandExecuted, m_Rem_CommandExecutedEventHandler
|
||||
AddHandler _remObject.ServerError, m_Rem_ServerErrorEventHandler
|
||||
AddHandler _remObject.AxisCoordinatesUpdate, m_Rem_AxesCoordinatesUpdateEventHandler
|
||||
@@ -131,7 +127,6 @@ Public Class TPAComm
|
||||
AddHandler _remObject.ListInfoResponse, m_Rem_ListInfoEventHandler
|
||||
AddHandler _remObject.RPCUpdate, m_Rem_RPCUpdateEventHandler
|
||||
AddHandler _remObject.VariableCommandExecuted, m_Rem_VariableCommandExecutedEventHandler
|
||||
'AddHandler _remObject.TickUpdate, m_Rem_TickUpdateEventHandler
|
||||
Catch ex As System.Runtime.Remoting.RemotingException
|
||||
Dim dR As MessageBoxResult = MessageBox.Show(ex.Message)
|
||||
End Try
|
||||
@@ -156,7 +151,6 @@ Public Class TPAComm
|
||||
RemoveHandler m_eventProxy.ListInfoResponse, m_Proxy_ListInfoEventHandler
|
||||
RemoveHandler m_eventProxy.RPCUpdate, m_Proxy_RPCUpdateEventHandler
|
||||
RemoveHandler m_eventProxy.VariableCommandExecuted, m_Proxy_VariableCommandExecutedEventHandler
|
||||
'RemoveHandler m_eventProxy.TickUpdate, m_Proxy_TickUpdateEventHandler
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -241,8 +235,4 @@ Public Class TPAComm
|
||||
End Select
|
||||
End Sub
|
||||
|
||||
Private Sub RemoteObject_TickUpdate(ByVal newTick As ULong)
|
||||
'EgtUILib.EgtOutLog("Tick: " & newTick)
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
|
||||
@@ -636,16 +636,6 @@ Public Class MachParam
|
||||
m_IsModifiedValue = String.Compare(value, m_sValue) <> 0
|
||||
End Select
|
||||
End If
|
||||
' se valore immesso è diverso e password non inserita
|
||||
'If m_IsModifiedValue AndAlso Not Map.refConfigurationPageVM.bModifyMachParam Then
|
||||
' Map.refConfigurationPageVM.bModifyMachParam = Map.refConfigurationPageVM.VerifyConfigPagePassword()
|
||||
' If Not Map.refConfigurationPageVM.bModifyMachParam Then
|
||||
' NotifyPropertyChanged("sValue")
|
||||
' m_IsModifiedValue = False
|
||||
' Return
|
||||
' End If
|
||||
'End If
|
||||
|
||||
Select Case nType
|
||||
Case MachParamType.DOUBLE_, MachParamType.LENGTH
|
||||
UpdateParamValue(dNewValue, "")
|
||||
|
||||
@@ -357,11 +357,17 @@
|
||||
<DependentUpon>MachineLogPageV.xaml</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="MachineLogPage\MachineLogPageVM.vb" />
|
||||
<Compile Include="MachineLogPage\OnlyProdMachineLogPageV.xaml.vb">
|
||||
<DependentUpon>OnlyProdMachineLogPageV.xaml</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="MachinePanel\MachinePanelVM.vb" />
|
||||
<Compile Include="MDIPage\MDIPageV.xaml.vb">
|
||||
<DependentUpon>MDIPageV.xaml</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="MDIPage\MDIPageVM.vb" />
|
||||
<Compile Include="MDIPage\OnlyProdMDIPageV.xaml.vb">
|
||||
<DependentUpon>OnlyProdMDIPageV.xaml</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="OutputsPage\OutputsPageV.xaml.vb">
|
||||
<DependentUpon>OutputsPageV.xaml</DependentUpon>
|
||||
</Compile>
|
||||
@@ -515,10 +521,18 @@
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
<SubType>Designer</SubType>
|
||||
</Page>
|
||||
<Page Include="MachineLogPage\OnlyProdMachineLogPageV.xaml">
|
||||
<SubType>Designer</SubType>
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
</Page>
|
||||
<Page Include="MDIPage\MDIPageV.xaml">
|
||||
<SubType>Designer</SubType>
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
</Page>
|
||||
<Page Include="MDIPage\OnlyProdMDIPageV.xaml">
|
||||
<SubType>Designer</SubType>
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
</Page>
|
||||
<Page Include="OutputsPage\OutputsPageV.xaml">
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
<SubType>Designer</SubType>
|
||||
|
||||
@@ -23,8 +23,6 @@ Public Class InputsPageVM
|
||||
#Region "Constructor"
|
||||
|
||||
Sub New()
|
||||
'' imposto riferimento in Map
|
||||
'Map.SetRefInputsPageVM(Me)
|
||||
m_InputVariableListVM = New VariablesListVM(S_INPUTVARIABLES)
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -3,12 +3,7 @@
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Supervisor"
|
||||
xmlns:EgtBEAMWALLCORE="clr-namespace:EgtBEAMWALL.Core;assembly=EgtBEAMWALL.Core">
|
||||
<!--<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="1*"/>
|
||||
<RowDefinition Height="30"/>
|
||||
<RowDefinition Height="30"/>
|
||||
</Grid.RowDefinitions>-->
|
||||
|
||||
<EgtBEAMWALLCORE:EgtDataGrid ItemsSource="{Binding Tag.FeatureVMList,
|
||||
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:FeatureInPartInRawPartListV}}}"
|
||||
SelectedItem="{Binding Tag.SelFeatureVM,
|
||||
@@ -47,7 +42,6 @@
|
||||
</Grid.ColumnDefinitions>
|
||||
<Border Width="{Binding ActualHeight, RelativeSource={RelativeSource self}}"
|
||||
Background="{Binding Calc_Background}"/>
|
||||
<!--Width="{Binding ActualHeigth, Source=Self}"/>-->
|
||||
<Grid Grid.Column="1"
|
||||
HorizontalAlignment="Center">
|
||||
<Grid.RowDefinitions>
|
||||
@@ -66,16 +60,6 @@
|
||||
FontWeight="Bold"
|
||||
FontSize="12"
|
||||
Margin="0,-6,0,-2"/>
|
||||
<!--<Ellipse Width="5"
|
||||
Height="5"
|
||||
Fill="Red"
|
||||
Visibility="{Binding CALC_ROT_Visibility}"/>
|
||||
<TextBlock Text="{Binding CALC_ERR_Letter}"
|
||||
Foreground="{Binding CALC_ERR_Foreground}"
|
||||
FontWeight="Bold"
|
||||
FontSize="10"/>-->
|
||||
<!--<TextBlock Text="➔"
|
||||
Visibility="{Binding CALC_FALL_Visibility}"/>-->
|
||||
</Grid>
|
||||
</Grid>
|
||||
</DataTemplate>
|
||||
|
||||
@@ -178,8 +178,6 @@ Public Class PartInRawPartListVM
|
||||
If Not IsNothing(m_colPartInRawPart_PosY) Then
|
||||
m_colPartInRawPart_PosY.ColumnVisibility = Visibility.Collapsed
|
||||
End If
|
||||
'PartInRawPartColumns.Clear()
|
||||
'GetPrivateProfileColumns(S_PARTINRAWPARTLIST_BEAM, PartInRawPartColumns)
|
||||
ElseIf nMachType = MachineType.WALL Then
|
||||
If Not IsNothing(m_colPartInRawPart_Rot) Then
|
||||
m_colPartInRawPart_Rot.ColumnVisibility = Visibility.Visible
|
||||
@@ -203,8 +201,6 @@ Public Class PartInRawPartListVM
|
||||
If Not IsNothing(m_colPartInRawPart_Offset) Then
|
||||
m_colPartInRawPart_Offset.ColumnVisibility = Visibility.Collapsed
|
||||
End If
|
||||
' PartInRawPartColumns.Clear()
|
||||
'GetPrivateProfileColumns(S_PARTINRAWPARTLIST_WALL, PartInRawPartColumns)
|
||||
End If
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Supervisor"
|
||||
xmlns:EgtBEAMWALLCORE="clr-namespace:EgtBEAMWALL.Core;assembly=EgtBEAMWALL.Core">
|
||||
<!--<ToggleButton IsChecked="{Binding DataContext.bL_IsReadOnly, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:RawPartListV}}}"/>-->
|
||||
|
||||
<EgtBEAMWALLCORE:EgtDataGrid x:Name="MachGroupDataGrid"
|
||||
ItemsSource="{Binding Tag.MachGroupVMList_View,
|
||||
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:RawPartListV}}}"
|
||||
|
||||
@@ -127,8 +127,6 @@ Public Class RawPartListVM
|
||||
If Not IsNothing(m_colRawPart_PosZ) Then
|
||||
m_colRawPart_PosZ.ColumnVisibility = Visibility.Collapsed
|
||||
End If
|
||||
'RawPartColumns.Clear()
|
||||
'GetPrivateProfileColumns(S_RAWPARTLIST_BEAM, RawPartColumns)
|
||||
ElseIf nMachType = MachineType.WALL Then
|
||||
' aggiorno la visibilità delle colonne
|
||||
For Each col In RawPartColumns
|
||||
@@ -140,8 +138,6 @@ Public Class RawPartListVM
|
||||
If Not IsNothing(m_colRawPart_PosZ) Then
|
||||
m_colRawPart_PosZ.ColumnVisibility = Visibility.Visible
|
||||
End If
|
||||
'RawPartColumns.Clear()
|
||||
'GetPrivateProfileColumns(S_RAWPARTLIST_WALL, RawPartColumns)
|
||||
End If
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -1,9 +1,7 @@
|
||||
<Grid x:Class="LeftPanelV"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
|
||||
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Supervisor"
|
||||
Width="Auto">
|
||||
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Supervisor">
|
||||
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto"/>
|
||||
|
||||
@@ -672,10 +672,6 @@ Public Class LeftPanelVM
|
||||
' se ora d'inizio non e' gia' fissata
|
||||
Dim Time As DateTime = DateTime.Now()
|
||||
If Part.nProduction_State = ItemState.Scrapped Then
|
||||
' fare domanda se modificare quantita' aggiunti se viene resettato un pezzo scraped??
|
||||
'If MessageBox.Show("There are scraped parts in this bar. Would you like to add them to the added quantity?", "", MessageBoxButton.YesNo, MessageBoxImage.Information) = MessageBoxResult.Yes Then
|
||||
' DbControllers.m_StatusMapController.UpdateAction("", Map.refSupervisorManagerVM.CurrProd.nProdId, Part.nPartId, StatusMapItemType.Part, StatusMapOpType.AddQtyForUnscraped, "")
|
||||
'End If
|
||||
End If
|
||||
If Part.dtStartTime <> DateTime.MinValue Then
|
||||
DbControllers.m_PartController.UpdateStart(Map.refSupervisorManagerVM.CurrProd.nProdId, MachGroup.Id, Part.nPartId, DateTime.MinValue)
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
<Grid x:Class="OnlyProdLeftPanelV"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Supervisor"
|
||||
Width="Auto">
|
||||
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Supervisor">
|
||||
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto"/>
|
||||
|
||||
@@ -0,0 +1,76 @@
|
||||
<UserControl x:Class="OnlyProdMDIPageV"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Supervisor"
|
||||
xmlns:EgtBEAMWALLCORE="clr-namespace:EgtBEAMWALL.Core;assembly=EgtBEAMWALL.Core">
|
||||
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="1*"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
</Grid.RowDefinitions>
|
||||
|
||||
<EgtBEAMWALLCORE:EgtDataGrid ItemsSource="{Binding MDICommandList}"
|
||||
SelectedItem="{Binding SelMDICommand}"
|
||||
AutoGenerateColumns="False"
|
||||
CanUserDeleteRows="False"
|
||||
CanUserResizeRows="False"
|
||||
SelectionMode="Single"
|
||||
ScrollViewer.CanContentScroll="True"
|
||||
ScrollViewer.VerticalScrollBarVisibility="Auto"
|
||||
ScrollViewer.HorizontalScrollBarVisibility="Auto"
|
||||
Margin="0,0,0,5"
|
||||
BindingColumns="{Binding MDICommandColumns}"
|
||||
AlternatingRowBackground="{StaticResource BeamWall_LinkWater}"
|
||||
AlternationCount="2"
|
||||
ColumnHeaderBackground="{StaticResource BeamWall_Teal}"
|
||||
ColumnHeaderForeground="{StaticResource BeamWall_White}"
|
||||
ColumnHeaderHorizontalContentAlignment="Center"
|
||||
ColumnHeaderFontWeight="Bold"
|
||||
ColumnHeaderFontSize="15"
|
||||
ColumnHeaderPadding="0,2,0,2"
|
||||
Style="{StaticResource DataGrid_OnlyProd}"
|
||||
CellStyle="{StaticResource CellDataGrid_CustomHighLight}"
|
||||
RowStyle="{StaticResource RowDataGrid_CustomHighLight}">
|
||||
<DataGrid.Resources>
|
||||
<!-- Command -->
|
||||
<DataGridTextColumn x:Key="colCOMMAND" Binding="{Binding sCommand}">
|
||||
<DataGridTextColumn.HeaderTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=DataContext.Command_Msg,
|
||||
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdMDIPageV}}}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTextColumn.HeaderTemplate>
|
||||
</DataGridTextColumn>
|
||||
<!-- Descrizione -->
|
||||
<DataGridTextColumn x:Key="colDESCRIPTION" Binding="{Binding sDescription}">
|
||||
<DataGridTextColumn.HeaderTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=DataContext.Description_Msg,
|
||||
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdMDIPageV}}}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTextColumn.HeaderTemplate>
|
||||
</DataGridTextColumn>
|
||||
</DataGrid.Resources>
|
||||
|
||||
</EgtBEAMWALLCORE:EgtDataGrid>
|
||||
|
||||
<Grid Grid.Row="1">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<TextBox Text="{Binding sMDICommand_Text, UpdateSourceTrigger=PropertyChanged}"
|
||||
Background="{Binding MDIText_Background}"
|
||||
VerticalAlignment="Center"
|
||||
CharacterCasing="Upper"
|
||||
Margin="5,0,2.5,0"/>
|
||||
<Button Grid.Column="1"
|
||||
Command="{Binding SendMDI_Command}"
|
||||
Margin="2.5,0,5,0"
|
||||
Style="{StaticResource ToolBar_SmallButton}">
|
||||
<Image Source="/Resources/MDIPage/Send.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</Grid>
|
||||
</Grid>
|
||||
</UserControl>
|
||||
@@ -0,0 +1,3 @@
|
||||
Public Class OnlyProdMDIPageV
|
||||
|
||||
End Class
|
||||
@@ -1,6 +1,7 @@
|
||||
<UserControl x:Class="MachCommandMessagePanelV"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
||||
|
||||
<StackPanel>
|
||||
<TextBlock Text="{Binding sErrCycle}"
|
||||
Background="{Binding ErrCycle_Foreground}"
|
||||
@@ -28,9 +29,6 @@
|
||||
Command="{Binding Reset_Command}"
|
||||
Style="{StaticResource ToolBar_TextButton}"
|
||||
IsEnabled="{Binding CommBtn_IsEnabled}"/>
|
||||
<!--<Button Content="STEP"
|
||||
Command="{Binding Step_Command}"
|
||||
Style="{StaticResource ToolBar_TextButton}"/>-->
|
||||
<Button Content="SET POINT"
|
||||
Command="{Binding SetPoint_Command}"
|
||||
Style="{StaticResource ToolBar_TextButton}"
|
||||
|
||||
@@ -115,33 +115,6 @@ Public Class MachCommandMessagePanelVM
|
||||
NotifyPropertyChanged(NameOf(VarValue))
|
||||
End Sub
|
||||
|
||||
'Private m_OPState As MachineOperatingState
|
||||
|
||||
'Public ReadOnly Property OPState As MachineOperatingState
|
||||
' Get
|
||||
' Return m_OPState
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property sOPState As String
|
||||
' Get
|
||||
' Select Case m_OPState
|
||||
' Case MachineOperatingState.Start
|
||||
' Return "START"
|
||||
' Case MachineOperatingState.Stop
|
||||
' Return "STOP"
|
||||
' Case MachineOperatingState.End
|
||||
' Return "RESET"
|
||||
' Case MachineOperatingState.SetPoint
|
||||
' Return "SETPOINT"
|
||||
' Case MachineOperatingState.Pending
|
||||
' Return "PENDING"
|
||||
' Case Else
|
||||
' Return "UNSPECIFIED"
|
||||
' End Select
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
Friend bMsgTranslationActive As Boolean = False
|
||||
|
||||
Private m_ErrCycle As New List(Of Alarm)
|
||||
@@ -332,55 +305,6 @@ Public Class MachCommandMessagePanelVM
|
||||
End Sub
|
||||
|
||||
Private Sub Init()
|
||||
'' inizializzo tutte le variabili
|
||||
'RWVariableManager.InitVar(ASSE_X, "0.TESTA.AsseX.X", CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(ASSE_Y, "0.TESTA.AsseY.Y", CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(ASSE_Z, "0.TESTA.AsseZ.Z", CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(ASSE_B, "0.TESTA.AsseC.B", CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(P_PROD, "0.FUNM.E81295", CommVar.CommVarTypes.CONTINUOUS)
|
||||
'RWVariableManager.InitVar(P_MACHGROUP, "0.FUNM.E81296", CommVar.CommVarTypes.CONTINUOUS)
|
||||
'RWVariableManager.InitVar(P_PART, "0.FUNM.E81297", CommVar.CommVarTypes.CONTINUOUS)
|
||||
'RWVariableManager.InitVar(P_STATE, "0.FUNM.E81298", CommVar.CommVarTypes.CONTINUOUS)
|
||||
'RWVariableManager.InitVar(RESET_STATE, "0.FUNM.E80048", CommVar.CommVarTypes.CONTINUOUS)
|
||||
'RWVariableManager.InitVar(VPAR & "1", "0.ENTRATA.V01NextPiece", CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "2", "0.ENTRATA.V02NextPiece", CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "3", "0.ENTRATA.V03NextPiece", CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "4", "0.ENTRATA.V04NextPiece", CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "5", "0.ENTRATA.V05NextPiece", CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "6", "0.ENTRATA.V06NextPiece", CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "7", "0.ENTRATA.V07NextPiece", CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "8", "0.ENTRATA.V08NextPiece", CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "9", "0.ENTRATA.V09NextPiece", CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "10", "0.ENTRATA.V10NextPiece", CommVar.CommVarTypes.ONETIME)
|
||||
|
||||
|
||||
' inizializzo valori assi leggendoli da variabili (non funziona nessuna combinazione)
|
||||
'MachManaging.CommandList.Add(ThreadCommand.CreateCommand(CommandTypes.READ, ASSE_X))
|
||||
'MachManaging.CommandList.Add(ThreadCommand.CreateCommand(CommandTypes.READ, ASSE_Y))
|
||||
'MachManaging.CommandList.Add(ThreadCommand.CreateCommand(CommandTypes.READ, ASSE_Z))
|
||||
'MachManaging.CommandList.Add(ThreadCommand.CreateCommand(CommandTypes.READ, ASSE_B))
|
||||
'MachManaging.CommandList.Add(ThreadCommand.CreateCommand(CommandTypes.READ, ASSE_C))
|
||||
'Dim t = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadAny, "0.TESTA.X", "")
|
||||
't = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadAny, "0.TESTA.Y", "")
|
||||
't = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadAny, "0.TESTA.Z", "")
|
||||
't = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadAny, "0.TESTA.C", "")
|
||||
't = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadAny, "0.TESTA.B", "")
|
||||
'Dim t = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadAxis, 0, "")
|
||||
''t = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadAxis, 1, "")
|
||||
't = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadAxis, 2, "")
|
||||
't = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadAxis, 3, "")
|
||||
't = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadAxis, 4, "")
|
||||
'Dim t = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadVar, "0.TESTA.AsseX.X", "")
|
||||
't = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadVar, "0.TESTA.AsseY.Y", "")
|
||||
't = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadVar, "0.TESTA.AsseZ.Z", "")
|
||||
't = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadVar, "0.TESTA.AsseC.C", "")
|
||||
't = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadVar, "0.TESTA.AsseB.B", "")
|
||||
'Dim t = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadVar, "0.TESTA.X", "")
|
||||
't = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadVar, "0.TESTA.Y", "")
|
||||
't = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadVar, "0.TESTA.Z", "")
|
||||
't = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadVar, "0.TESTA.C", "")
|
||||
't = Map.refMachManaging.Tpa.remObject.SetVariableCommand(ISOCNC.Remoting.VariableCommands.ReadVar, "0.TESTA.B", "")
|
||||
|
||||
' inizializzo le variabili principali
|
||||
Dim Index As Integer = 1
|
||||
Dim CommVariable As CommVar = MachManaging.InitVar(S_MAINVARIABLES, Index)
|
||||
@@ -389,34 +313,6 @@ Public Class MachCommandMessagePanelVM
|
||||
Index += 1
|
||||
CommVariable = MachManaging.InitVar(S_MAINVARIABLES, Index)
|
||||
End While
|
||||
|
||||
'm_MainVariablesList.Add(New Variable(MachManaging.InitVar(S_MAINVARIABLES, 1)))
|
||||
'm_MainVariablesList.Add(New Variable(MachManaging.InitVar(S_MAINVARIABLES, 2)))
|
||||
'm_MainVariablesList.Add(New Variable(MachManaging.InitVar(S_MAINVARIABLES, 3)))
|
||||
'm_MainVariablesList.Add(New Variable(MachManaging.InitVar(S_MAINVARIABLES, 4)))
|
||||
'm_MainVariablesList.Add(New Variable(MachManaging.InitVar(S_MAINVARIABLES, 5)))
|
||||
'm_MainVariablesList.Add(New Variable(MachManaging.InitVar(S_MAINVARIABLES, 6)))
|
||||
|
||||
'RWVariableManager.InitVar(ASSE_X, GetVarPathByName(ASSE_X), CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(ASSE_Y, GetVarPathByName(ASSE_Y), CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(ASSE_Z, GetVarPathByName(ASSE_Z), CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(ASSE_B, GetVarPathByName(ASSE_B), CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(P_PROD, GetVarPathByName(P_PROD), CommVar.CommVarTypes.CONTINUOUS)
|
||||
'RWVariableManager.InitVar(P_MACHGROUP, GetVarPathByName(P_MACHGROUP), CommVar.CommVarTypes.CONTINUOUS)
|
||||
'RWVariableManager.InitVar(P_PART, GetVarPathByName(P_PART), CommVar.CommVarTypes.CONTINUOUS)
|
||||
'RWVariableManager.InitVar(P_STATE, GetVarPathByName(P_STATE), CommVar.CommVarTypes.CONTINUOUS)
|
||||
'RWVariableManager.InitVar(RESET_STATE, GetVarPathByName(RESET_STATE), CommVar.CommVarTypes.CONTINUOUS)
|
||||
'RWVariableManager.InitVar(VPAR & "1", GetVarPathByName(VPAR & "1"), CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "2", GetVarPathByName(VPAR & "2"), CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "3", GetVarPathByName(VPAR & "3"), CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "4", GetVarPathByName(VPAR & "4"), CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "5", GetVarPathByName(VPAR & "5"), CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "6", GetVarPathByName(VPAR & "6"), CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "7", GetVarPathByName(VPAR & "7"), CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "8", GetVarPathByName(VPAR & "8"), CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "9", GetVarPathByName(VPAR & "9"), CommVar.CommVarTypes.ONETIME)
|
||||
'RWVariableManager.InitVar(VPAR & "10", GetVarPathByName(VPAR & "10"), CommVar.CommVarTypes.ONETIME)
|
||||
|
||||
End Sub
|
||||
|
||||
Public ReadOnly Property Disconnect_Command As ICommand
|
||||
@@ -555,7 +451,6 @@ Public Class MachCommandMessagePanelVM
|
||||
DbControllers.m_LogMachineController.Create(LogEvent.CreateMachCommandLog(LogEvent.MachineCommands.DISCONNECTION, "", 0, DbControllers.SupervisorId))
|
||||
End If
|
||||
End Select
|
||||
'DbControllers.m_LogMachineController.Create(MachLog.CreateResultLog(CommandType, CommandState, ResultType, Params))
|
||||
End Sub
|
||||
Friend Sub CloseCallbackDlg(ByRef bCancel As Boolean)
|
||||
' serve?
|
||||
@@ -577,30 +472,18 @@ Public Class MachCommandMessagePanelVM
|
||||
m_Iso.Add(Alarm.CreateAlarm(AlarmCode, AlarmMessage))
|
||||
Else
|
||||
m_Iso.RemoveAll(Function(x) x.sCode = AlarmCode)
|
||||
'Dim ToRemove As Alarm = m_ErrCycle.FirstOrDefault(Function(x) x.sCode = AlarmCode)
|
||||
'If Not IsNothing(ToRemove) Then
|
||||
' m_ErrCycle.Remove(ToRemove)
|
||||
'End If
|
||||
End If
|
||||
Case CInt(ISOCNC.Remoting.AlarmType.ISO)
|
||||
If AlarmOperation = CInt(ISOCNC.Remoting.AlarmOperation.Addition) Then
|
||||
m_ErrSystem.Add(Alarm.CreateAlarm(AlarmCode, AlarmMessage))
|
||||
Else
|
||||
m_ErrSystem.RemoveAll(Function(x) x.sCode = AlarmCode)
|
||||
'Dim ToRemove As Alarm = m_Iso.FirstOrDefault(Function(x) x.sCode = AlarmCode)
|
||||
'If Not IsNothing(ToRemove) Then
|
||||
' m_Iso.Remove(ToRemove)
|
||||
'End If
|
||||
End If
|
||||
Case CInt(ISOCNC.Remoting.AlarmType.Message)
|
||||
If AlarmOperation = CInt(ISOCNC.Remoting.AlarmOperation.Addition) Then
|
||||
m_Message.Add(Alarm.CreateAlarm(AlarmCode, AlarmMessage))
|
||||
Else
|
||||
m_Message.RemoveAll(Function(x) x.sCode = AlarmCode)
|
||||
'Dim ToRemove As Alarm = m_Message.FirstOrDefault(Function(x) x.sCode = AlarmCode)
|
||||
'If Not IsNothing(ToRemove) Then
|
||||
' m_Message.Remove(ToRemove)
|
||||
'End If
|
||||
End If
|
||||
Case CInt(ISOCNC.Remoting.AlarmType.None)
|
||||
Case CInt(ISOCNC.Remoting.AlarmType.System)
|
||||
@@ -608,10 +491,6 @@ Public Class MachCommandMessagePanelVM
|
||||
m_ErrCycle.Add(Alarm.CreateAlarm(AlarmCode, AlarmMessage))
|
||||
Else
|
||||
m_ErrCycle.RemoveAll(Function(x) x.sCode = AlarmCode)
|
||||
'Dim ToRemove As Alarm = m_ErrSystem.FirstOrDefault(Function(x) x.sCode = AlarmCode)
|
||||
'If Not IsNothing(ToRemove) Then
|
||||
' m_ErrSystem.Remove(ToRemove)
|
||||
'End If
|
||||
End If
|
||||
Case Else
|
||||
End Select
|
||||
@@ -622,7 +501,6 @@ Public Class MachCommandMessagePanelVM
|
||||
' fermo timer degli allarmi
|
||||
m_AlarmTimer.Stop()
|
||||
End If
|
||||
'DbControllers.m_LogMachineController.Create(MachLog.CreateAlarmLog(AlarmOperation, AlarmType, AlarmMessage, AlarmCode, AlarmDateTime))
|
||||
DbControllers.m_LogMachineController.Create(LogEvent.CreateAlarmLog(DateTime.Now(), AlarmOperation & LogEvent.cSeparator & AlarmType & LogEvent.cSeparator & AlarmMessage & LogEvent.cSeparator & AlarmCode & LogEvent.cSeparator & AlarmDateTime, DbControllers.m_SupervisorId))
|
||||
End Sub
|
||||
|
||||
@@ -800,7 +678,6 @@ Public Class MachCommandMessagePanelVM
|
||||
' fermo timer degli allarmi
|
||||
m_AlarmTimer.Stop()
|
||||
End If
|
||||
'DbControllers.m_LogMachineController.Create(MachLog.CreateAlarmLog(AlarmOperation, ErrorTyp, AlarmMessage, AlarmCode, DateTime.Now))
|
||||
DbControllers.m_LogMachineController.Create(LogEvent.CreateAlarmLog(DateTime.Now(), AlarmOperation & LogEvent.cSeparator & ErrorTyp & LogEvent.cSeparator & AlarmMessage & LogEvent.cSeparator & AlarmCode & LogEvent.cSeparator, DbControllers.m_SupervisorId))
|
||||
End Sub
|
||||
|
||||
@@ -824,7 +701,6 @@ Public Class MachCommandMessagePanelVM
|
||||
Case NCTypes.NUM_FLEXIUM, NCTypes.NUM_AXIUM_APSERVER, NCTypes.NUM_AXIUM_PCTOOLKIT
|
||||
Map.refLeftPanelVM.SetOPState(NewState)
|
||||
End Select
|
||||
'DbControllers.m_LogMachineController.Create(MachLog.CreateOPStateLog(newOpState))
|
||||
DbControllers.m_LogMachineController.Create(LogEvent.CreateMachineStateLog(newOpState, DbControllers.m_SupervisorId))
|
||||
End Sub
|
||||
|
||||
@@ -838,7 +714,6 @@ Public Class MachCommandMessagePanelVM
|
||||
Case NCTypes.NUM_FLEXIUM, NCTypes.NUM_AXIUM_APSERVER, NCTypes.NUM_AXIUM_PCTOOLKIT
|
||||
Map.refLeftPanelVM.SetOPMode(NewState)
|
||||
End Select
|
||||
'DbControllers.m_LogMachineController.Create(MachLog.CreateOPStateLog(newOpState))
|
||||
DbControllers.m_LogMachineController.Create(LogEvent.CreateMachineModeLog(newOpState, DbControllers.m_SupervisorId))
|
||||
End Sub
|
||||
|
||||
@@ -848,7 +723,6 @@ Public Class MachCommandMessagePanelVM
|
||||
Case NCTypes.NUM_FLEXIUM, NCTypes.NUM_AXIUM_APSERVER, NCTypes.NUM_AXIUM_PCTOOLKIT
|
||||
Map.refLeftPanelVM.SetChannel(NewChannel)
|
||||
End Select
|
||||
'DbControllers.m_LogMachineController.Create(MachLog.CreateOPStateLog(NewChannelId))
|
||||
End Sub
|
||||
|
||||
Friend Sub ReadVarCallbackDlg(CommandExecutedCorrectly As Boolean, VarAddress As String, VarValue As String, VarType As Integer)
|
||||
@@ -858,7 +732,6 @@ Public Class MachCommandMessagePanelVM
|
||||
Case "AsseX", "AsseY", "AsseZ", "AsseC", "AsseB"
|
||||
SetAxisValue(VarName, VarValue)
|
||||
End Select
|
||||
'DbControllers.m_LogMachineController.Create(MachLog.CreateReadLog(CommandExecutedCorrectly, VarAddress, VarValue))
|
||||
DbControllers.m_LogMachineController.Create(LogEvent.CreateReadVarLog(VarAddress, VarValue, DbControllers.SupervisorId))
|
||||
End If
|
||||
End Sub
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.ComponentModel
|
||||
Imports System.IO
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.Collections.Specialized
|
||||
Imports System.ComponentModel
|
||||
Imports System.IO
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtUILib
|
||||
@@ -170,8 +168,6 @@ Public Class MyMachGroupVM
|
||||
If m_bToBeProduced Then Return
|
||||
' disabilito bottoni di comunicazione durante invio programma
|
||||
Map.refMachCommandMessagePanelVM.SetCommBtnIsEnabled(False)
|
||||
' macchina bloccata con reset PER TEST!!!!
|
||||
'SetResetWhileCutting(True)
|
||||
' se ripartenza
|
||||
If Map.refLeftPanelVM.bRestart Then
|
||||
' verifico se c'e' un visualizzatore o ottimizzatore aperto su questo progetto
|
||||
@@ -236,8 +232,6 @@ Public Class MyMachGroupVM
|
||||
Else
|
||||
Part.SetDo(True)
|
||||
End If
|
||||
'Part.bDO = (Part.dtEndTime = DateTime.MinValue)
|
||||
'Part.NotifyPropertyChanged(NameOf(Part.bRedo))
|
||||
Next
|
||||
' se ripresa, mostro lista feature e colonne Redo
|
||||
Map.refLeftPanelVM.bRestart = True
|
||||
@@ -459,39 +453,6 @@ Public Class MyMachGroupVM
|
||||
NotifyPropertyChanged(NameOf(Produce_IsEnabled))
|
||||
MachGroup = BeamMachGroup
|
||||
ElseIf Map.refSupervisorManagerVM.CurrProd.nType = BWType.WALL Then
|
||||
'' scrivo dati in gruppo di lavorazione
|
||||
'Dim dPosX As Double = dKerf
|
||||
'Dim dPosY As Double = dKerf
|
||||
'EgtSetInfo(nCurrMachGroup, MGR_RPT_PANELLEN, dL)
|
||||
'EgtSetInfo(nCurrMachGroup, MGR_RPT_PANELWIDTH, dW)
|
||||
'EgtSetInfo(nCurrMachGroup, MGR_RPT_PART & 1, nPartDuploId & "," & dPosX & "," & dPosY & "," & 0 & "," & 0)
|
||||
'Dim WallMachGroup As WallMachGroupVM = DirectCast(Map.refMachGroupPanelVM.MachGroupVMList(Map.refMachGroupPanelVM.MachGroupVMList.Count - 1), WallMachGroupVM)
|
||||
'' eseguo script creazione grezzo
|
||||
'If Not ExecWall(sLogPath, Map.refMachinePanelVM.SelectedMachine.Name, CalcIntegration.CmdType.RAWPART, False) Then
|
||||
' WallMachGroup.DeleteMachGroup()
|
||||
' If File.Exists(sLogPath) Then
|
||||
' Dim LogFile As String() = File.ReadAllLines(sLogPath)
|
||||
' If LogFile.Count >= 2 AndAlso Not IsNothing(LogFile(1)) Then
|
||||
' MessageBox.Show(LogFile(1), EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error)
|
||||
' End If
|
||||
' Else
|
||||
' MessageBox.Show("Impossible creating rawpart", EgtMsg(30007), MessageBoxButton.OK, MessageBoxImage.Error)
|
||||
' End If
|
||||
' Return
|
||||
'End If
|
||||
'' scrivo dati pezzo
|
||||
'EgtSetInfo(nPartDuploId, MGR_PRT_POSX, dPosX)
|
||||
'EgtSetInfo(nPartDuploId, MGR_PRT_POSY, dPosY)
|
||||
'EgtSetInfo(nPartDuploId, MGR_PRT_ROT, 0)
|
||||
'EgtSetInfo(nPartDuploId, MGR_PRT_FLIP, False)
|
||||
'' aggiorno contatore pezzi usati in Prod
|
||||
'SelPart.RefreshPartInProd()
|
||||
'' aggiorno lista pezzi
|
||||
'WallMachGroup.m_WallMachGroupM.RefreshPartList()
|
||||
'WallMachGroup.m_WallMachGroupM.RefreshGroupData()
|
||||
'' aggiorno dati ultilizzo barra
|
||||
'WallMachGroup.UpdateUsage()
|
||||
'EgtSetView(VT.TOP, False)
|
||||
End If
|
||||
' aggiorno dati utilizzo grezzo
|
||||
MachGroup.UpdateUsage()
|
||||
@@ -506,12 +467,6 @@ Public Class MyMachGroupVM
|
||||
DbControllers.m_PartController.UpdateStatus(Map.refSupervisorManagerVM.CurrProd.nProdId, MachGroup.Id, Part.nPartId, ItemState.Assigned)
|
||||
Part.nProduction_State = ItemState.Assigned
|
||||
Part.NotifyPropertyChanged(NameOf(Part.Background))
|
||||
'' disabilito impostazione modificato
|
||||
'Dim DisableMgr As New DisableModifiedMgr
|
||||
'' blocco modifica del pezzo
|
||||
'EgtDuploSetLocked(Part.nPartId)
|
||||
'' ripristino precedente impostazione modificato
|
||||
'DisableMgr.ReEnable()
|
||||
Next
|
||||
' aggiorno indice di tutte le barre in coda
|
||||
For Each CurrMachGroup As MyMachGroupVM In Map.refSupervisorMachGroupPanelVM.MachGroupVMList
|
||||
|
||||
@@ -1,9 +1,7 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.IO
|
||||
Imports System.ComponentModel
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
Public Class PartVM
|
||||
Inherits Core.PartVM
|
||||
|
||||
@@ -1,7 +1,4 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.ComponentModel
|
||||
Imports System.IO
|
||||
Imports System.Windows.Threading
|
||||
Imports System.Windows.Threading
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtBEAMWALL.DataLayer.DatabaseModels
|
||||
Imports EgtUILib
|
||||
@@ -153,188 +150,8 @@ Public Class SupervisorMachGroupPanelVM
|
||||
Next
|
||||
Map.refProjectVM.SupervisorMachGroupPanelVM.AddMachGroupToSupervisor(MachGroup)
|
||||
Next
|
||||
|
||||
|
||||
|
||||
|
||||
'' Carico i gruppi di lavorazione nella lista
|
||||
'Dim nId = EgtGetFirstMachGroup()
|
||||
'While nId <> GDB_ID.NULL
|
||||
' ' se gia' presente, vado al prossimo
|
||||
' If Map.refSupervisorMachGroupPanelVM.MachGroupVMList.Any(Function(x) x.Id = nId) Then
|
||||
' nId = EgtGetNextMachGroup(nId)
|
||||
' Continue While
|
||||
' End If
|
||||
' ' altrimenti lo carico
|
||||
' EgtSetCurrMachGroup(nId)
|
||||
' Dim sName As String = String.Empty
|
||||
' Dim sMachine As String = String.Empty
|
||||
' EgtGetMachGroupName(nId, sName)
|
||||
' EgtGetMachGroupMachineName(nId, sMachine)
|
||||
' ' cerco la macchina tra quelle presenti
|
||||
' Dim UsedMachine As MyMachine = Nothing
|
||||
' Dim bOk As Boolean = Machine.SearchMachine(sMachine, MachineList, UsedMachine)
|
||||
' If Not bOk OrElse UsedMachine.nType = MachineType.NULL Then
|
||||
' EgtOutLog("Machine incompatible with beam & wall machining!!")
|
||||
' ElseIf UsedMachine.nType = MachineType.BEAM Then
|
||||
' Map.refSupervisorMachGroupPanelVM.m_MyMachGroupPanelM.AddMachGroup(BeamMachGroupM.CreateBeamMachGroup(nId, sName, sMachine))
|
||||
' ElseIf UsedMachine.nType = MachineType.WALL Then
|
||||
' Map.refSupervisorMachGroupPanelVM.m_MyMachGroupPanelM.AddMachGroup(WallMachGroupM.CreateWallMachGroup(nId, sName, sMachine))
|
||||
' End If
|
||||
' nId = EgtGetNextMachGroup(nId)
|
||||
'End While
|
||||
'EgtResetCurrMachGroup()
|
||||
|
||||
End Sub
|
||||
|
||||
#End Region ' METHODS
|
||||
|
||||
End Class
|
||||
|
||||
'Friend Class MachGroupVMListComparer
|
||||
' Implements IComparer
|
||||
|
||||
' Dim m_Direction As ListSortDirection
|
||||
' Dim m_Column As EgtDataGridColumn
|
||||
' Dim m_ColumnList As List(Of DataGridColumn)
|
||||
' Dim m_EgtColumnList As New List(Of EgtDataGridColumn)
|
||||
|
||||
' Sub New()
|
||||
' m_Column = column
|
||||
' m_ColumnList = ColumnList
|
||||
' m_EgtColumnList = EgtColumnList
|
||||
' m_Direction = direction
|
||||
|
||||
|
||||
' Dim column As DataGridColumn = e.Column
|
||||
' Dim datagrid As DataGrid = sender
|
||||
' Dim comparer As IComparer = Nothing
|
||||
' e.Handled = True
|
||||
' Dim direction As ListSortDirection = If((column.SortDirection <> ListSortDirection.Ascending), ListSortDirection.Ascending, ListSortDirection.Descending)
|
||||
' column.SortDirection = direction
|
||||
' Dim m_ColumnList As New List(Of DataGridColumn)
|
||||
' Dim m_EgtColumnList As New List(Of EgtDataGridColumn)
|
||||
' For Each col In datagrid.Columns
|
||||
' If Not IsNothing(col.SortDirection) Then
|
||||
' m_ColumnList.Add(col)
|
||||
' m_EgtColumnList.Add(Map.refRawPartListVM.RawPartColumns(col.DisplayIndex))
|
||||
' End If
|
||||
' Next
|
||||
' Dim lcv As ListCollectionView = CType(CollectionViewSource.GetDefaultView(datagrid.ItemsSource), ListCollectionView)
|
||||
' comparer = New MyComparer(Map.refRawPartListVM.RawPartColumns(column.DisplayIndex), m_ColumnList, m_EgtColumnList, direction)
|
||||
' lcv.CustomSort = comparer
|
||||
|
||||
|
||||
|
||||
' End Sub
|
||||
|
||||
' Public Function Compare(x As Object, y As Object) As Integer Implements IComparer.Compare
|
||||
' Dim First As MyMachGroupVM = DirectCast(x, MyMachGroupVM)
|
||||
' Dim Second As MyMachGroupVM = DirectCast(y, MyMachGroupVM)
|
||||
' Dim bFirstProduced As Boolean = First.nProduction_State = Core.ItemState.WIP OrElse First.nProduction_State = Core.ItemState.Produced
|
||||
' Dim bSecondProduced As Boolean = Second.nProduction_State = Core.ItemState.WIP OrElse Second.nProduction_State = Core.ItemState.Produced
|
||||
' Dim nDirection As Integer = If(m_Direction, 1, -1)
|
||||
' If bFirstProduced AndAlso bSecondProduced Then
|
||||
' If First.nProductionIndex > Second.nProductionIndex Then
|
||||
' Return 1
|
||||
' ElseIf First.nProductionIndex < Second.nProductionIndex Then
|
||||
' Return -1
|
||||
' Else
|
||||
' Return 0
|
||||
' End If
|
||||
' ElseIf bFirstProduced Then
|
||||
' Return -1
|
||||
' ElseIf bSecondProduced Then
|
||||
' Return 1
|
||||
' Else
|
||||
' Dim ColumnIndex = 0
|
||||
' While ColumnIndex <= m_EgtColumnList.Count - 1
|
||||
' Dim nDir As ListSortDirection = If(m_ColumnList(ColumnIndex).SortDirection, 1, -1)
|
||||
' Dim nCheck As Integer = Check(First, Second, nDir, m_EgtColumnList(ColumnIndex))
|
||||
' If nCheck <> 0 Then
|
||||
' Return nCheck
|
||||
' End If
|
||||
' ColumnIndex += 1
|
||||
' End While
|
||||
' Return 0
|
||||
' End If
|
||||
' End Function
|
||||
|
||||
' Private Function Check(First As MyMachGroupVM, Second As MyMachGroupVM, nDirection As Integer, Column As EgtDataGridColumn) As Integer
|
||||
' Select Case Column.Name
|
||||
' Case COL_NAME
|
||||
' If First.nName > Second.nName Then
|
||||
' Return 1 * nDirection
|
||||
' ElseIf First.nName < Second.nName Then
|
||||
' Return -1 * nDirection
|
||||
' Else
|
||||
' Return 0
|
||||
' End If
|
||||
' Case COL_STARTCUT
|
||||
' If First.Id > Second.Id Then
|
||||
' Return 1 * nDirection
|
||||
' ElseIf First.Id < Second.Id Then
|
||||
' Return -1 * nDirection
|
||||
' Else
|
||||
' Return 0
|
||||
' End If
|
||||
' Case COL_W
|
||||
' If First.dW > Second.dW Then
|
||||
' Return 1 * nDirection
|
||||
' ElseIf First.dW < Second.dW Then
|
||||
' Return -1 * nDirection
|
||||
' Else
|
||||
' Return 0
|
||||
' End If
|
||||
' Case COL_H
|
||||
' If First.dH > Second.dH Then
|
||||
' Return 1 * nDirection
|
||||
' ElseIf First.dH < Second.dH Then
|
||||
' Return -1 * nDirection
|
||||
' Else
|
||||
' Return 0
|
||||
' End If
|
||||
' Case COL_L
|
||||
' If First.dL > Second.dL Then
|
||||
' Return 1 * nDirection
|
||||
' ElseIf First.dL < Second.dL Then
|
||||
' Return -1 * nDirection
|
||||
' Else
|
||||
' Return 0
|
||||
' End If
|
||||
' Case COL_POSZ
|
||||
' 'If First.posz > Second.dL Then
|
||||
' ' Return 1 * nDirection
|
||||
' 'ElseIf First.dL < Second.dL Then
|
||||
' ' Return -1 * nDirection
|
||||
' 'Else
|
||||
' ' Return 0
|
||||
' 'End If
|
||||
' Case COL_MATERIAL
|
||||
' If First.sMATERIAL > Second.sMATERIAL Then
|
||||
' Return 1 * nDirection
|
||||
' ElseIf First.sMATERIAL < Second.sMATERIAL Then
|
||||
' Return -1 * nDirection
|
||||
' Else
|
||||
' Return 0
|
||||
' End If
|
||||
' Case COL_USAGE
|
||||
' If First.dUsage > Second.dUsage Then
|
||||
' Return 1 * nDirection
|
||||
' ElseIf First.dUsage < Second.dUsage Then
|
||||
' Return -1 * nDirection
|
||||
' Else
|
||||
' Return 0
|
||||
' End If
|
||||
' Case COL_WASTE
|
||||
' If First.dWaste > Second.dWaste Then
|
||||
' Return 1 * nDirection
|
||||
' ElseIf First.dWaste < Second.dWaste Then
|
||||
' Return -1 * nDirection
|
||||
' Else
|
||||
' Return 0
|
||||
' End If
|
||||
' End Select
|
||||
' End Function
|
||||
|
||||
'End Class
|
||||
|
||||
@@ -58,18 +58,13 @@ Public Class MachManaging
|
||||
End Property
|
||||
Friend Shared Sub AddToCommandList(value As ThreadCommand)
|
||||
SyncLock Lock_CommandList
|
||||
' EgtOutLog("Inizio ciclo rimozioni")
|
||||
For CommandIndex = m_CommandList.Count - 1 To 0 Step -1
|
||||
Dim Command As ThreadCommand = m_CommandList(CommandIndex)
|
||||
If Command.ProcessingStatus = ThreadCommand.ProcessingStatuses.DONE Then
|
||||
' EgtOutLog("Inizio rimozione comando")
|
||||
m_CommandList.Remove(Command)
|
||||
' EgtOutLog("Fine rimozione comando")
|
||||
End If
|
||||
Next
|
||||
' EgtOutLog("Fine ciclo rimozioni")
|
||||
CommandList.Add(value)
|
||||
' EgtOutLog("Count dopo aggiunta: " & CommandList.Count)
|
||||
End SyncLock
|
||||
End Sub
|
||||
|
||||
@@ -111,136 +106,6 @@ Public Class MachManaging
|
||||
|
||||
Friend Sub Timer_Tick()
|
||||
Select Case CurrentMachine.NCType
|
||||
'Case NCTypes.TPA
|
||||
' 'Dim bCancel As Boolean = False
|
||||
' 'callback(0, "Init", bCancel)
|
||||
|
||||
' ' leggo tutte le variabili
|
||||
' CN.RWVariableManager.RefreshAllVars()
|
||||
|
||||
' ' eseguo ciclo principale
|
||||
' Dim nReset_State As Integer
|
||||
' Dim nP_Prod As Integer
|
||||
' Dim nP_Machgroup As Integer
|
||||
' Dim nP_Part As Integer
|
||||
' Dim nP_State As Integer
|
||||
' CN.RWVariableManager.ReadVar(P_PROD, nP_Prod)
|
||||
' CN.RWVariableManager.ReadVar(P_MACHGROUP, nP_Machgroup)
|
||||
' CN.RWVariableManager.ReadVar(P_PART, nP_Part)
|
||||
' CN.RWVariableManager.ReadVar(P_STATE, nP_State)
|
||||
' CN.RWVariableManager.ReadVar(RESET_STATE, nReset_State)
|
||||
' ' se non ancora fatto, preparo variabili barra successiva
|
||||
' If CurrentMachine.Flow = FlowTypes.CONTINUOUS AndAlso m_NextBarId = 0 Then
|
||||
' SetNextBarVars()
|
||||
' End If
|
||||
' 'Dim TestOpState As Integer = Tpa.remObject.MachineOperativeStatus
|
||||
' ' verifico se scattato stato reset
|
||||
' If nReset_State <> 0 Then
|
||||
' ' resetto tutti i programmi
|
||||
' If Not IsNothing(Map.refProjectVM.SupervisorMachGroupPanelVM) Then Map.refProjectVM.SupervisorMachGroupPanelVM.ResetAllMachGroups()
|
||||
' ' resetto variabili P
|
||||
' Tpa.RWVariableManager.WriteVar(P_PROD, 0)
|
||||
' Tpa.RWVariableManager.WriteVar(P_MACHGROUP, 0)
|
||||
' Tpa.RWVariableManager.WriteVar(P_PART, 0)
|
||||
' Tpa.RWVariableManager.WriteVar(P_STATE, 0)
|
||||
' ' cancello tutti i programmi da memoria CN
|
||||
' RemoveAllProgram() ' rimuovo programma default per pending
|
||||
' ' azzero variabile reset
|
||||
' Tpa.remObject.SetVariableCommand(CInt(ISOCNC.Remoting.VariableCommands.WriteVar),
|
||||
' RWVariableManager.GetReadVarFromName(RESET_STATE).sAddress, "0")
|
||||
' ' resetto prossima barra e variabili V
|
||||
' If CurrentMachine.Flow = FlowTypes.CONTINUOUS Then
|
||||
' m_NextBarId = 0
|
||||
' For Index As Integer = 1 To 6
|
||||
' Tpa.RWVariableManager.WriteVar(VPAR & Index.ToString(), 0)
|
||||
' Next
|
||||
' End If
|
||||
' Return
|
||||
' ' se macchina pronta e non sta tagliando alcun pezzo
|
||||
' ElseIf (nP_Prod = 0 AndAlso
|
||||
' nP_Machgroup = 0 AndAlso
|
||||
' nP_Part = 0 AndAlso
|
||||
' nP_State = PartState.NULL) AndAlso
|
||||
' Tpa.opState = MachineOperatingState.Pending AndAlso Tpa.remObject.MachineOperativeStatus = MachineOperatingState.Pending Then
|
||||
' ' verifico se c'e' un programma da lanciare
|
||||
' SendNextProgram()
|
||||
' ' attesa per essere sicuro che abbia scritto e riletto variabili
|
||||
' Threading.Thread.Sleep(300)
|
||||
' ' verifico stati inizio e fine pezzi
|
||||
' ElseIf nP_Prod <> 0 AndAlso
|
||||
' nP_Machgroup <> 0 AndAlso
|
||||
' nP_Part <> 0 Then
|
||||
' If nP_State = PartState.START Then
|
||||
' ' scrivo data start su Db pezzo
|
||||
' Dim dtStart As DateTime = DateTime.Now()
|
||||
' DbControllers.m_PartController.UpdateStart(nP_Prod, nP_Machgroup, nP_Part, dtStart)
|
||||
' DbControllers.m_PartController.UpdateStatus(nP_Prod, nP_Machgroup, nP_Part, ItemState.WIP)
|
||||
' ' recupero gruppo di lavorazione del pezzo
|
||||
' Dim MachGroup As MyMachGroupVM = Map.refProjectVM.SupervisorMachGroupPanelVM.MachGroupVMList.FirstOrDefault(Function(x) x.Id = nP_Machgroup)
|
||||
' ' recupero pezzo
|
||||
' Dim Part As PartVM = MachGroup.PartVMList.FirstOrDefault(Function(x) x.nPartId = nP_Part)
|
||||
' ' scrivo stato start
|
||||
' Part.nProduction_State = ItemState.WIP
|
||||
' Part.dtStartTime = dtStart
|
||||
' Part.NotifyPropertyChanged(NameOf(Part.nProduction_State))
|
||||
' ' azzero variabile per far ripartire macchina
|
||||
' Tpa.RWVariableManager.WriteVar(P_STATE, 0)
|
||||
' ' se nessun pezzo della barra diverso da quello corrente e' in start
|
||||
' If Not MachGroup.PartVMList.Any(Function(x) x.nPartId <> nP_Part AndAlso x.nProduction_State = 1) Then
|
||||
' ' scrivo data start su Db barra
|
||||
' DbControllers.m_MachGroupController.UpdateStart(nP_Prod, nP_Machgroup, dtStart)
|
||||
' DbControllers.m_MachGroupController.UpdateStatus(nP_Prod, nP_Machgroup, ItemState.WIP)
|
||||
' ' scrivo stato start
|
||||
' MachGroup.MyMachGroupM.SetProductionState(ItemState.WIP)
|
||||
' MachGroup.dtStartTime = dtStart
|
||||
' MachGroup.NotifyPropertyChanged(NameOf(MachGroup.nProduction_State))
|
||||
' End If
|
||||
' ' attesa per essere sicuro che abbia scritto e riletto variabili
|
||||
' Threading.Thread.Sleep(300)
|
||||
' ElseIf nP_State = PartState.END_ Then
|
||||
' ' scrivo data end su Db pezzo
|
||||
' Dim dtEnd As DateTime = DateTime.Now()
|
||||
' DbControllers.m_PartController.UpdateEnd(nP_Prod, nP_Machgroup, nP_Part, dtEnd)
|
||||
' DbControllers.m_PartController.UpdateStatus(nP_Prod, nP_Machgroup, nP_Part, ItemState.Produced)
|
||||
' ' recupero gruppo di lavorazione del pezzo
|
||||
' Dim MachGroup As MyMachGroupVM = Map.refProjectVM.SupervisorMachGroupPanelVM.MachGroupVMList.FirstOrDefault(Function(x) x.Id = nP_Machgroup)
|
||||
' ' recupero pezzo
|
||||
' Dim Part As PartVM = MachGroup.PartVMList.FirstOrDefault(Function(x) x.nPartId = nP_Part)
|
||||
' ' scrivo stato end
|
||||
' Part.nProduction_State = ItemState.Produced
|
||||
' Part.dtEndTime = dtEnd
|
||||
' Part.NotifyPropertyChanged(NameOf(Part.nProduction_State))
|
||||
' ' resetto stato redo
|
||||
' Part.bRedo = False
|
||||
' ' azzero variabile per far ripartire macchina
|
||||
' Tpa.RWVariableManager.WriteVar(P_STATE, 0)
|
||||
' ' se tutti i pezzi della barra sono in end
|
||||
' If MachGroup.PartVMList.All(Function(x) x.nProduction_State >= 2) Then
|
||||
' ' scrivo data end su Db barra
|
||||
' DbControllers.m_MachGroupController.UpdateEnd(nP_Prod, nP_Machgroup, dtEnd)
|
||||
' DbControllers.m_MachGroupController.UpdateStatus(nP_Prod, nP_Machgroup, ItemState.Produced)
|
||||
' ' scrivo stato end
|
||||
' MachGroup.MyMachGroupM.SetProductionState(ItemState.Produced)
|
||||
' MachGroup.dtEndTime = dtEnd
|
||||
' MachGroup.NotifyPropertyChanged(NameOf(MachGroup.nProduction_State))
|
||||
' ' azzero tutte le variabilli per iniziare barra successiva
|
||||
' Tpa.RWVariableManager.WriteVar(P_PROD, 0)
|
||||
' Tpa.RWVariableManager.WriteVar(P_MACHGROUP, 0)
|
||||
' Tpa.RWVariableManager.WriteVar(P_PART, 0)
|
||||
' Tpa.RWVariableManager.WriteVar(P_STATE, 0)
|
||||
' ' resetto stati di produzione
|
||||
' MachGroup.ResetProduce()
|
||||
' ' se partenza pezzi uno a uno
|
||||
' If CurrentMachine.Flow = FlowTypes.ONEBYONE Then
|
||||
' ' riattivo bottone produzione per tutti gli altri
|
||||
' MyMachGroupVM.UpdateProduceIsEnabledForAll()
|
||||
' End If
|
||||
' End If
|
||||
' Map.refLeftPanelVM.PrintLabel(MachGroup, Part)
|
||||
' ' attesa per essere sicuro che abbia scritto e riletto variabili
|
||||
' Threading.Thread.Sleep(300)
|
||||
' End If
|
||||
' End If
|
||||
Case NCTypes.NUM_FLEXIUM, NCTypes.TPA, NCTypes.NUM_AXIUM_APSERVER, NCTypes.NUM_AXIUM_PCTOOLKIT
|
||||
' eseguo ciclo principale
|
||||
Dim nReset_State As Integer
|
||||
@@ -370,7 +235,6 @@ Public Class MachManaging
|
||||
Case NCTypes.NUM_AXIUM_PCTOOLKIT
|
||||
' leggo tutte le variabili
|
||||
Num_Axium_PCToolkit.RefreshAllVars()
|
||||
'EgtOutLog("Post lettura variabili")
|
||||
Dim dTemp As Double = 0
|
||||
Dim nTemp As Integer = 0
|
||||
If Not IsNothing(ResetVariable.sValue) Then
|
||||
@@ -430,7 +294,6 @@ Public Class MachManaging
|
||||
Else
|
||||
nCurrMachIndex = -1
|
||||
End If
|
||||
'EgtOutLog("Post scrittura variabili lette")
|
||||
' se indice lavorazione positivo, lo aggiorno
|
||||
If nCurrMachIndex > 0 AndAlso nReset_State = 0 Then
|
||||
m_nMachIndex = nCurrMachIndex
|
||||
@@ -438,9 +301,7 @@ Public Class MachManaging
|
||||
' leggo messaggi plc
|
||||
ReadPLCMessages()
|
||||
Num_Axium_PCToolkit.ReadCncMode()
|
||||
'EgtOutLog("Pre lettura posizioni")
|
||||
Num_Axium_PCToolkit.ReadPosition()
|
||||
'EgtOutLog("Post lettura messaggi")
|
||||
End Select
|
||||
' se NUM aggiorno stato della macchina
|
||||
If CurrentMachine.NCType = NCTypes.NUM_FLEXIUM Then
|
||||
@@ -495,18 +356,11 @@ Public Class MachManaging
|
||||
MachGroupVariable.sValue = "0"
|
||||
PartVariable.sValue = "0"
|
||||
StateVariable.sValue = "0"
|
||||
'Tpa.RWVariableManager.WriteVar(P_PROD, 0)
|
||||
'Tpa.RWVariableManager.WriteVar(P_MACHGROUP, 0)
|
||||
'Tpa.RWVariableManager.WriteVar(P_PART, 0)
|
||||
'Tpa.RWVariableManager.WriteVar(P_STATE, 0)
|
||||
' cancello tutti i programmi da memoria CN
|
||||
If CurrentMachine.NCType = NCTypes.TPA Then
|
||||
RemoveAllProgram() ' rimuovo programma default per pending
|
||||
End If
|
||||
' azzero variabile reset
|
||||
ResetVariable.sValue = "0"
|
||||
'Tpa.remObject.SetVariableCommand(CInt(ISOCNC.Remoting.VariableCommands.WriteVar),
|
||||
' RWVariableManager.GetReadVarFromName(RESET_STATE).sAddress, "0")
|
||||
' resetto prossima barra e variabili V
|
||||
If CurrentMachine.NCType = NCTypes.TPA AndAlso CurrentMachine.Flow = FlowTypes.CONTINUOUS Then
|
||||
m_NextBarId = 0
|
||||
@@ -659,7 +513,6 @@ Public Class MachManaging
|
||||
|
||||
' se non impostata data start
|
||||
If MachGroup.dtStartTime = DateTime.MinValue Then
|
||||
' EgtOutLog("Start date not set on Prod " & nP_Prod & " Machgroup " & nP_Machgroup)
|
||||
Dim dtStart As DateTime = MachGroup.dtEndTime - TimeSpan.FromSeconds(60)
|
||||
' provo a recuperare tempo stimato
|
||||
If MachGroup.nCALC_TIME > 0 Then
|
||||
@@ -745,7 +598,6 @@ Public Class MachManaging
|
||||
End Function
|
||||
|
||||
Private Function SendNextProgram() As Boolean
|
||||
' EgtOutLog("Inizio SendNextProgram")
|
||||
Dim bSent As Boolean = False
|
||||
If (CurrentMachine.NCType = NCTypes.TPA AndAlso Not m_bStartPending AndAlso Tpa.opState = MachineOperatingState.Pending) OrElse
|
||||
(CurrentMachine.NCType = NCTypes.NUM_FLEXIUM AndAlso Not Num_Flexium.bIsTransferActive) OrElse
|
||||
@@ -753,20 +605,15 @@ Public Class MachManaging
|
||||
(CurrentMachine.NCType = NCTypes.NUM_AXIUM_PCTOOLKIT AndAlso Not Num_Axium_PCToolkit.bIsTransferActive) Then ' Or Tpa.opState = MachineOperatingState.Start) Then
|
||||
' verifico se c'e' un programma da lanciare
|
||||
If Not IsNothing(Map.refProjectVM.SupervisorMachGroupPanelVM) Then
|
||||
' EgtOutLog("Start " & DateTime.Now())
|
||||
Dim bMachGroupNotReady As Boolean = False
|
||||
SyncLock m_Lock_SendProgram
|
||||
For Each MyMachGroup As MyMachGroupVM In Map.refProjectVM.SupervisorMachGroupPanelVM.MachGroupVMList
|
||||
' EgtOutLog("Ciclo su name: " & MyMachGroup.Name & " id: " & MyMachGroup.Id)
|
||||
If Not MyMachGroup.bSentToMachine AndAlso (MyMachGroup.dtStartTime = DateTime.MinValue OrElse
|
||||
(Map.refSupervisorManagerVM.CurrProd.nType = BWType.WALL AndAlso MyMachGroup.bResetWhileCutting)) Then
|
||||
' EgtOutLog(MyMachGroup.Name & " id: " & MyMachGroup.Id & " è da fare")
|
||||
' verifico se ricalcolo finito
|
||||
If MyMachGroup.bReadyForMachining AndAlso If(CurrentMachine.NCType = NCTypes.NUM_FLEXIUM Or CurrentMachine.NCType = NCTypes.NUM_AXIUM_APSERVER OrElse CurrentMachine.NCType = NCTypes.NUM_AXIUM_PCTOOLKIT, Not MyMachGroup.bSendingToMachine, True) Then
|
||||
' EgtOutLog(MyMachGroup.Name & " id: " & MyMachGroup.Id & " pronto per essere lavorato")
|
||||
' lo lancio
|
||||
bSent = SendProgram(MyMachGroup.CnFilePath(), MyMachGroup.Name)
|
||||
' EgtOutLog(MyMachGroup.Name & " id: " & MyMachGroup.Id & " mandato " & DateTime.Now() & " " & MyMachGroup.Name & " " & bSent.ToString())
|
||||
Select Case CurrentMachine.NCType
|
||||
Case NCTypes.TPA
|
||||
MyMachGroup.SetSentToMachine(bSent)
|
||||
@@ -778,7 +625,6 @@ Public Class MachManaging
|
||||
Else
|
||||
' programma non ancora pronto, esco per attendere
|
||||
bMachGroupNotReady = True
|
||||
' EgtOutLog(MyMachGroup.Name & " id: " & MyMachGroup.Id & " non ancora pronto per essere mandato")
|
||||
Exit For
|
||||
'Return False
|
||||
End If
|
||||
@@ -786,7 +632,6 @@ Public Class MachManaging
|
||||
Next
|
||||
End SyncLock
|
||||
If bMachGroupNotReady Then Return False
|
||||
' EgtOutLog("End " & DateTime.Now())
|
||||
End If
|
||||
End If
|
||||
Return bSent
|
||||
@@ -794,7 +639,6 @@ Public Class MachManaging
|
||||
|
||||
Private Sub CommandList_CollectionChanged(sender As Object, e As NotifyCollectionChangedEventArgs)
|
||||
If Not IsNothing(e.NewItems) Then
|
||||
' EgtOutLog("Inizio ciclo esecuzione comandi")
|
||||
Dim nCommandCount As Integer = e.NewItems.Count
|
||||
For CommandIndex = 0 To nCommandCount - 1
|
||||
Dim Command As ThreadCommand = e.NewItems(CommandIndex)
|
||||
@@ -804,7 +648,6 @@ Public Class MachManaging
|
||||
Command.SetProcessingStatus(ThreadCommand.ProcessingStatuses.DONE)
|
||||
End If
|
||||
Next
|
||||
' EgtOutLog("Fine ciclo esecuzione di " & nCommandCount & " comandi")
|
||||
End If
|
||||
End Sub
|
||||
|
||||
@@ -833,7 +676,6 @@ Public Class MachManaging
|
||||
Case CommandTypes.READ_TPA
|
||||
Tpa.RWVariableManager.RefreshVar(Command.sVariable)
|
||||
Case CommandTypes.WRITE
|
||||
'EgtOutLog("Write" & Command.sVariable & " " & Command.sVariables(1) & " " & Command.nVariable)
|
||||
WriteVar(Command.sVariable, Command.sVariables(1), Command.nVariable)
|
||||
Case CommandTypes.DELETEALARMS
|
||||
DeleteAlarms()
|
||||
@@ -919,21 +761,18 @@ Public Class MachManaging
|
||||
m_ResultCallbackDlg(CommandTypes.DISCONNECT, CommandStates.OK, ResultTypes.EXECUTED, "")
|
||||
' chiudo classe Num_Flexium
|
||||
Me.OnDispose()
|
||||
'Num_Flexium.OnDispose()
|
||||
Case NCTypes.NUM_AXIUM_APSERVER
|
||||
m_bConnected = False
|
||||
Num_Axium_APServer.CloseFxObjects()
|
||||
m_ResultCallbackDlg(CommandTypes.DISCONNECT, CommandStates.OK, ResultTypes.EXECUTED, "")
|
||||
' chiudo classe Num_Flexium
|
||||
Me.OnDispose()
|
||||
'Num_Flexium.OnDispose()
|
||||
Case NCTypes.NUM_AXIUM_PCTOOLKIT
|
||||
m_bConnected = False
|
||||
Num_Axium_PCToolkit.CloseFxObjects()
|
||||
m_ResultCallbackDlg(CommandTypes.DISCONNECT, CommandStates.OK, ResultTypes.EXECUTED, "")
|
||||
' chiudo classe Num_Flexium
|
||||
Me.OnDispose()
|
||||
'Num_Flexium.OnDispose()
|
||||
End Select
|
||||
' termino thread di comunicazione
|
||||
MachineCommThread.StopThread()
|
||||
@@ -975,7 +814,6 @@ Public Class MachManaging
|
||||
Return
|
||||
End Try
|
||||
End If
|
||||
'ProgramPath = ProgramPath.Replace("\\", "\")
|
||||
bOk = Tpa.remObject.AddProgramToList(DefaultIsoFilePath)
|
||||
Threading.Thread.Sleep(1000)
|
||||
bOk = Tpa.remObject.SetCommand(CInt(ISOCNC.Remoting.Commands.Start))
|
||||
@@ -1074,7 +912,6 @@ Public Class MachManaging
|
||||
Num_Axium_APServer.StartTransfer()
|
||||
Return True
|
||||
Case NCTypes.NUM_AXIUM_PCTOOLKIT
|
||||
' EgtOutLog("Pre Download")
|
||||
Dim nFileType As Integer = 0
|
||||
If Integer.TryParse(ProgramId, nFileType) AndAlso nFileType > 0 Then
|
||||
Num_Axium_PCToolkit.FileDownload(nFileType * 10, ProgramPath)
|
||||
|
||||
@@ -49,7 +49,6 @@ Class MachineCommThread
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
End Class
|
||||
|
||||
Public Class ThreadCommand
|
||||
|
||||
@@ -35,14 +35,8 @@ Public Class RWVariableManager
|
||||
|
||||
Friend Sub OnDispose()
|
||||
RemoveHandler m_Tpa.eventProxy.VariableCommandExecuted, m_Proxy_VariableCommandExecutedEventHandler
|
||||
'RemoveHandler m_Tpa.MachManaging.Timer.Tick, AddressOf Timer_Tick
|
||||
End Sub
|
||||
|
||||
'Friend Sub Timer_Tick(sender As Object, e As EventArgs)
|
||||
' ' leggo tutte le variabili
|
||||
' RefreshAllVars()
|
||||
'End Sub
|
||||
|
||||
Friend Shared Function CreateRWVariableManager(Tpa As TPAComm)
|
||||
Dim NewRWVariableManager As New RWVariableManager
|
||||
NewRWVariableManager.m_Tpa = Tpa
|
||||
@@ -63,12 +57,6 @@ Public Class RWVariableManager
|
||||
Return Index
|
||||
End Function
|
||||
|
||||
'Public Shared Function InitVar(nIndex As Integer) As CommVar
|
||||
' Dim Index As Integer = Array.IndexOf(m_ReadingVars, Nothing)
|
||||
' m_ReadingVars(Index) = GetPrivateProfileVariable(S_VARIABLES, nIndex, CurrentMachine.sMachIniFile)
|
||||
' Return m_ReadingVars(Index)
|
||||
'End Function
|
||||
|
||||
Public Shared Function InitVar(Variable As CommVar) As CommVar
|
||||
Dim Index As Integer = Array.IndexOf(m_ReadingVars, Nothing)
|
||||
m_ReadingVars(Index) = Variable
|
||||
@@ -204,7 +192,6 @@ Public Class RWVariableManager
|
||||
If CommandExecutedCorrectly Then
|
||||
Dim Var As CommVar = GetReadVarFromAddress(VarName)
|
||||
If Not IsNothing(Var) Then
|
||||
'Dim bChangedVal As Boolean = ()
|
||||
Var.SetValue(VarValue)
|
||||
' se variabile ripetitiva lancio update variabili ripetitive
|
||||
If Var.nReadType = CommVar.ReadTypes.CONTINUOUS Then
|
||||
|
||||
@@ -14,8 +14,6 @@
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<!--<ComboBox ItemsSource="MachLogTypeList"
|
||||
SelectedItem="SelMachLogType"/>-->
|
||||
<Button Grid.Column="1"
|
||||
Command="{Binding Refresh_Command}"
|
||||
Margin="2.5,0,5,0"
|
||||
@@ -56,7 +54,6 @@
|
||||
<DatePicker SelectedDate="{Binding dtEndDate}"
|
||||
Style="{StaticResource Log_DatePicker}"/>
|
||||
</StackPanel>
|
||||
<!--<TextBox Text="{Binding MaxRowNumber}"/>-->
|
||||
<Button Grid.Column="1"
|
||||
Command="{Binding Refresh_Command}"
|
||||
Margin="2.5,0,5,0"
|
||||
|
||||
@@ -3,7 +3,6 @@ Imports EgtWPFLib5
|
||||
Imports EgtUILib
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports System.Windows.Threading
|
||||
Imports EgtBEAMWALL.DataLayer.DatabaseModels
|
||||
Imports EgtBEAMWALL.Core.MachLog
|
||||
|
||||
Public Class MachineLogPageVM
|
||||
@@ -377,7 +376,6 @@ Public Class MachineLogPageVM
|
||||
End Sub
|
||||
|
||||
Friend Sub UpdateFromDb(bRefresh As Boolean)
|
||||
'm_MachineLogList = New ObservableCollection(Of LogEvent)(DbControllers.m_LogMachineController.GetCoreDesc(DateTime.Now - TimeSpan.FromDays(300), DateTime.Now).Select(Of LogEvent)(Function(x) New LogEvent(x)).ToList())
|
||||
Dim DbList As List(Of LogEvent)
|
||||
Select Case m_SelDayType
|
||||
Case DayTypes.PERIOD
|
||||
|
||||
@@ -0,0 +1,163 @@
|
||||
<UserControl x:Class="OnlyProdMachineLogPageV"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Supervisor"
|
||||
xmlns:EgtBEAMWALLCORE="clr-namespace:EgtBEAMWALL.Core;assembly=EgtBEAMWALL.Core">
|
||||
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="1*"/>
|
||||
</Grid.RowDefinitions>
|
||||
|
||||
<Grid Visibility="Collapsed">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<Button Grid.Column="1"
|
||||
Command="{Binding Refresh_Command}"
|
||||
Margin="2.5,0,5,0"
|
||||
Style="{StaticResource ToolBar_Button}">
|
||||
<Image Source="/Resources/MDIPage/Send.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</Grid>
|
||||
|
||||
<StackPanel Orientation="Horizontal" Height="30">
|
||||
<TextBlock Text="{Binding Entity_Msg}"
|
||||
Style="{StaticResource Log_TextBlock}"/>
|
||||
<ComboBox ItemsSource="{Binding EntityTypeList}"
|
||||
SelectedIndex="{Binding SelEntityType}"
|
||||
Width="70"
|
||||
Margin="0,0,2.5,0"
|
||||
Style="{StaticResource OnlyProdCalcPanel_ComboBox}"/>
|
||||
<TextBlock Text="{Binding Event_Msg}"
|
||||
Style="{StaticResource Log_TextBlock}"/>
|
||||
<ComboBox ItemsSource="{Binding PartEventTypeList}"
|
||||
SelectedIndex="{Binding SelPartEventType}"
|
||||
Width="70"
|
||||
Margin="0,0,2.5,0"
|
||||
Style="{StaticResource OnlyProdCalcPanel_ComboBox}"/>
|
||||
<TextBlock Text="{Binding Date_Msg}"
|
||||
Style="{StaticResource Log_TextBlock}"/>
|
||||
<ComboBox ItemsSource="{Binding DayTypeList}"
|
||||
SelectedIndex="{Binding SelDayType}"
|
||||
Width="70"
|
||||
Margin="0,0,2.5,0"
|
||||
Style="{StaticResource OnlyProdCalcPanel_ComboBox}"/>
|
||||
<StackPanel Orientation="Horizontal" Visibility="{Binding Date_Visibility}">
|
||||
<TextBlock Text="{Binding From_Msg}"
|
||||
Style="{StaticResource Log_TextBlock}"/>
|
||||
<DatePicker SelectedDate="{Binding dtStartDate}"
|
||||
Style="{StaticResource Log_DatePicker}"/>
|
||||
<TextBlock Text="{Binding To_Msg}"
|
||||
Style="{StaticResource Log_TextBlock}"/>
|
||||
<DatePicker SelectedDate="{Binding dtEndDate}"
|
||||
Style="{StaticResource Log_DatePicker}"/>
|
||||
</StackPanel>
|
||||
<!--<TextBox Text="{Binding MaxRowNumber}"/>-->
|
||||
<Button Grid.Column="1"
|
||||
Command="{Binding Refresh_Command}"
|
||||
Margin="2.5,0,5,0"
|
||||
Style="{StaticResource ToolBar_Button}">
|
||||
<Image Source="/Resources/MDIPage/Send.png" Stretch="Uniform"/>
|
||||
</Button>
|
||||
</StackPanel>
|
||||
|
||||
<EgtBEAMWALLCORE:EgtDataGrid ItemsSource="{Binding MachineLogList}"
|
||||
Grid.Row="1"
|
||||
AutoGenerateColumns="False"
|
||||
CanUserDeleteRows="False"
|
||||
CanUserResizeRows="False"
|
||||
SelectionMode="Single"
|
||||
ScrollViewer.CanContentScroll="True"
|
||||
ScrollViewer.VerticalScrollBarVisibility="Auto"
|
||||
ScrollViewer.HorizontalScrollBarVisibility="Auto"
|
||||
Margin="0,5,0,5"
|
||||
BindingColumns="{Binding MachineLogColumns}"
|
||||
AlternatingRowBackground="{StaticResource BeamWall_LinkWater}"
|
||||
AlternationCount="2"
|
||||
ColumnHeaderBackground="{StaticResource BeamWall_Teal}"
|
||||
ColumnHeaderForeground="{StaticResource BeamWall_White}"
|
||||
ColumnHeaderHorizontalContentAlignment="Center"
|
||||
ColumnHeaderFontWeight="Bold"
|
||||
ColumnHeaderFontSize="15"
|
||||
ColumnHeaderPadding="0,2,0,2"
|
||||
Style="{StaticResource DataGrid_OnlyProd}"
|
||||
CellStyle="{StaticResource CellDataGrid_CustomHighLight}"
|
||||
RowStyle="{StaticResource RowDataGrid_CustomHighLight}">
|
||||
<DataGrid.Resources>
|
||||
<!-- Data/ora -->
|
||||
<DataGridTextColumn x:Key="colDATETIME" Binding="{Binding sEventDateTime}"
|
||||
SortMemberPath="sEventTick">
|
||||
<DataGridTextColumn.HeaderTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=DataContext.EventDateTime_Msg,
|
||||
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdMachineLogPageV}}}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTextColumn.HeaderTemplate>
|
||||
</DataGridTextColumn>
|
||||
<!-- Type -->
|
||||
<DataGridTextColumn x:Key="colTYPE" Binding="{Binding sEventType}">
|
||||
<DataGridTextColumn.HeaderTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=DataContext.EventType_Msg,
|
||||
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdMachineLogPageV}}}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTextColumn.HeaderTemplate>
|
||||
</DataGridTextColumn>
|
||||
<!-- Descrizione -->
|
||||
<DataGridTextColumn x:Key="colDESCRIPTION" Binding="{Binding sEventValue}">
|
||||
<DataGridTextColumn.HeaderTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=DataContext.EventValue_Msg,
|
||||
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdMachineLogPageV}}}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTextColumn.HeaderTemplate>
|
||||
</DataGridTextColumn>
|
||||
<!-- SupervisorId -->
|
||||
<DataGridTextColumn x:Key="colSUPERVISORID" Binding="{Binding SupervisorId}">
|
||||
<DataGridTextColumn.HeaderTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=DataContext.SupervisorId_Msg,
|
||||
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdMachineLogPageV}}}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTextColumn.HeaderTemplate>
|
||||
</DataGridTextColumn>
|
||||
<DataGridTextColumn x:Key="colPROD" Binding="{Binding ProdId}">
|
||||
<DataGridTextColumn.HeaderTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=DataContext.ProdId_Msg,
|
||||
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdMachineLogPageV}}}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTextColumn.HeaderTemplate>
|
||||
</DataGridTextColumn>
|
||||
<DataGridTextColumn x:Key="colMACHGROUP" Binding="{Binding MachGroupId}">
|
||||
<DataGridTextColumn.HeaderTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=DataContext.MachGroupId_Msg,
|
||||
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdMachineLogPageV}}}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTextColumn.HeaderTemplate>
|
||||
</DataGridTextColumn>
|
||||
<DataGridTextColumn x:Key="colPART" Binding="{Binding PartId}">
|
||||
<DataGridTextColumn.HeaderTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=DataContext.PartId_Msg,
|
||||
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdMachineLogPageV}}}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTextColumn.HeaderTemplate>
|
||||
</DataGridTextColumn>
|
||||
<DataGridTextColumn x:Key="colSTATUS" Binding="{Binding Status}">
|
||||
<DataGridTextColumn.HeaderTemplate>
|
||||
<DataTemplate>
|
||||
<TextBlock Text="{Binding Path=DataContext.Status_Msg,
|
||||
RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:OnlyProdMachineLogPageV}}}"/>
|
||||
</DataTemplate>
|
||||
</DataGridTextColumn.HeaderTemplate>
|
||||
</DataGridTextColumn>
|
||||
</DataGrid.Resources>
|
||||
</EgtBEAMWALLCORE:EgtDataGrid>
|
||||
</Grid>
|
||||
|
||||
</UserControl>
|
||||
@@ -0,0 +1,3 @@
|
||||
Public Class OnlyProdMachineLogPageV
|
||||
|
||||
End Class
|
||||
@@ -375,350 +375,3 @@ Public Class MachinePanelVM
|
||||
#End Region ' COMMANDS
|
||||
|
||||
End Class
|
||||
|
||||
|
||||
'Imports System.Collections.ObjectModel
|
||||
'Imports System.IO
|
||||
'Imports EgtBEAMWALL.Core
|
||||
'Imports EgtUILib
|
||||
'Imports EgtWPFLib5
|
||||
|
||||
'Public Class MachinePanelVM
|
||||
' Inherits VMBase
|
||||
|
||||
'#Region "FIELDS & PROPERTIES"
|
||||
|
||||
' ' Radice del direttorio delle macchine
|
||||
' Private m_sMachinesRoot As String
|
||||
|
||||
' ' Lista delle macchine disponibili
|
||||
' Private m_MachineList As New ObservableCollection(Of Machine)
|
||||
' Public Property MachineList As ObservableCollection(Of Machine)
|
||||
' Get
|
||||
' Return m_MachineList
|
||||
' End Get
|
||||
' Set(value As ObservableCollection(Of Machine))
|
||||
' m_MachineList = value
|
||||
' End Set
|
||||
' End Property
|
||||
' ' Macchina correntemente selezionata e quindi attiva
|
||||
' Private m_SelectedMachine As Machine = Nothing
|
||||
' Public Property SelectedMachine As MyMachine
|
||||
' Get
|
||||
' Return m_SelectedMachine
|
||||
' End Get
|
||||
' Set(value As MyMachine)
|
||||
' If value IsNot m_SelectedMachine Then
|
||||
' 'EgtSetCurrentContext(Map.refSceneHostVM.MainScene.GetCtx())
|
||||
' 'EgtResetCurrMachGroup()
|
||||
' ' se sono in modalità disegno
|
||||
' m_SelectedMachine = value
|
||||
' ' inizializzo la macchina selezionata come macchina corrente
|
||||
' Dim nMachType As MachineType = DirectCast(m_SelectedMachine, MyMachine).nType
|
||||
' SectionXMaterial.SetType(nMachType)
|
||||
' InitCurrentMachine(Map.refMainWindowVM.MainWindowM.sMachinesRoot, value.Name, nMachType)
|
||||
' End If
|
||||
' End Set
|
||||
' End Property
|
||||
|
||||
' Private m_SetUp_Background As Brush = New BrushConverter().ConvertFrom("#FFDDDDDD")
|
||||
' Public Property SetUp_Background As Brush
|
||||
' Get
|
||||
' Return m_SetUp_Background
|
||||
' End Get
|
||||
' Set(value As Brush)
|
||||
' m_SetUp_Background = value
|
||||
' NotifyPropertyChanged("SetUp_Background")
|
||||
' End Set
|
||||
' End Property
|
||||
|
||||
' Private m_MachPanel_IsEnabled As Boolean = True
|
||||
' Public Property MachPanel_IsEnabled As Boolean
|
||||
' Get
|
||||
' Return m_MachPanel_IsEnabled
|
||||
' End Get
|
||||
' Set(value As Boolean)
|
||||
' m_MachPanel_IsEnabled = value
|
||||
' NotifyPropertyChanged("MachPanel_IsEnabled")
|
||||
' End Set
|
||||
' End Property
|
||||
|
||||
'#Region "Messages"
|
||||
|
||||
' Public ReadOnly Property ToolDBMsg As String
|
||||
' Get
|
||||
' Return EgtMsg(MSG_MACHINEPAGEUC + 6)
|
||||
' End Get
|
||||
' End Property
|
||||
' Public ReadOnly Property MachiningDbMsg As String
|
||||
' Get
|
||||
' Return EgtMsg(MSG_MACHINEPAGEUC + 7)
|
||||
' End Get
|
||||
' End Property
|
||||
' Public ReadOnly Property SetUpMsg As String
|
||||
' Get
|
||||
' Return EgtMsg(MSG_ALARMSPAGEUC + 33)
|
||||
' End Get
|
||||
' End Property
|
||||
|
||||
'#End Region ' Messages
|
||||
|
||||
'#Region "ToolTip"
|
||||
|
||||
' Public ReadOnly Property ToolDBToolTip As String
|
||||
' Get
|
||||
' Return "Tool DB"
|
||||
' End Get
|
||||
' End Property
|
||||
' Public ReadOnly Property MachiningDbToolTip As String
|
||||
' Get
|
||||
' Return "Machining DB"
|
||||
' End Get
|
||||
' End Property
|
||||
' Public ReadOnly Property SetUpToolTip As String
|
||||
' Get
|
||||
' Return "SetUp"
|
||||
' End Get
|
||||
' End Property
|
||||
|
||||
'#End Region ' ToolTip
|
||||
|
||||
' ' Definizione comandi
|
||||
' Private m_cmdToolDb As ICommand
|
||||
' Private m_cmdMachDb As ICommand
|
||||
' Private m_cmdSetUp As ICommand
|
||||
' Private m_cmdMachOptions As ICommand
|
||||
|
||||
'#End Region 'FIELDS & PROPERTIES
|
||||
|
||||
'#Region "CONSTRUCTOR"
|
||||
|
||||
' Sub New()
|
||||
' ' Creo riferimento a questa classe in Map
|
||||
' Map.SetRefMachinePanelVM(Me)
|
||||
' ' recupero cartella radice delle macchine
|
||||
' m_sMachinesRoot = Map.refMainWindowVM.MainWindowM.sMachinesRoot
|
||||
' ' Carica macchine da cartella delle macchine
|
||||
' MyMachine.MachineListInit(m_sMachinesRoot, MachineList)
|
||||
' End Sub
|
||||
|
||||
'#End Region ' CONSTRUCTOR
|
||||
|
||||
'#Region "METHODS"
|
||||
|
||||
' Friend Sub LoadCurrentMachine()
|
||||
' If MachineList.Count = 0 Then Return
|
||||
' Dim CurrMachine As Machine = Nothing
|
||||
' Dim CurrMachineName As String = String.Empty
|
||||
' GetMainPrivateProfileString(S_MACH, K_SUPERVISORMACH, String.Empty, CurrMachineName)
|
||||
' Dim bFound As Boolean = False
|
||||
' If Not String.IsNullOrEmpty(CurrMachineName) Then
|
||||
' For Each Mach In MachineList
|
||||
' If Mach.Name = CurrMachineName Then
|
||||
' bFound = True
|
||||
' CurrMachine = Mach
|
||||
' Exit For
|
||||
' End If
|
||||
' Next
|
||||
' End If
|
||||
' If Not bFound And MachineList.Count > 0 Then
|
||||
' CurrMachine = MachineList(0)
|
||||
' End If
|
||||
' If Not IsNothing(CurrMachine) Then
|
||||
' If EgtSetCurrMachine(CurrMachine.Name) Then
|
||||
' SelectedMachine = CurrMachine
|
||||
' End If
|
||||
' End If
|
||||
' End Sub
|
||||
|
||||
' Friend Sub SaveCurrentMachine()
|
||||
' If IsNothing(m_SelectedMachine) Then Return
|
||||
' WriteMainPrivateProfileString(S_MACH, K_CURRMACH, SelectedMachine.Name)
|
||||
' End Sub
|
||||
|
||||
' Friend Sub UpdateCurrentMachine()
|
||||
' 'EgtSetCurrentContext(IniFile.m_ProjectSceneContext)
|
||||
' Dim sMachName As String = String.Empty
|
||||
' If EgtGetCurrMachineName(sMachName) Then
|
||||
' For Each Mach In MachineList
|
||||
' If Mach.Name = sMachName Then
|
||||
' SelectedMachine = Mach
|
||||
' Exit For
|
||||
' End If
|
||||
' Next
|
||||
' End If
|
||||
' End Sub
|
||||
|
||||
'#End Region
|
||||
|
||||
'#Region "COMMANDS"
|
||||
|
||||
'#Region "ToolDbCommand"
|
||||
|
||||
' ''' <summary>
|
||||
' ''' Returns a command that do Exec.
|
||||
' ''' </summary>
|
||||
' Public ReadOnly Property ToolDbCommand As ICommand
|
||||
' Get
|
||||
' If m_cmdToolDb Is Nothing Then
|
||||
' m_cmdToolDb = New Command(AddressOf ToolDb)
|
||||
' End If
|
||||
' Return m_cmdToolDb
|
||||
' End Get
|
||||
' End Property
|
||||
|
||||
' ''' <summary>
|
||||
' ''' Execute the Exec. This method is invoked by the ExecCommand.
|
||||
' ''' </summary>
|
||||
' Public Sub ToolDb(ByVal param As Object)
|
||||
' If Not VerifyMachinesDir(m_sMachinesRoot) Then Return
|
||||
' ' ricarico il database per intercettare eventuali aggiornamenti fatti da altre istanze del programma (se la cartella Machines è condivisa)
|
||||
' If Not EgtTdbReload() Then
|
||||
' EgtOutLog("Impossible reloading tool Db")
|
||||
' MessageBox.Show(EgtMsg(MSG_TOOLDBERRORS + 30), EgtMsg(MSG_MESSAGEBOX + 1), MessageBoxButton.OK, MessageBoxImage.Error)
|
||||
' Return
|
||||
' End If
|
||||
|
||||
' Dim ToolDbWindowVM As New ToolDbWindowVM(CurrentMachine.sMachDir, CurrentMachine.sMachIniFile, Map.refSceneHostVM.MainScene.GetCtx(), "Beam")
|
||||
' Dim ToolDbWindowV As New ToolDbWindowV(Application.Current.MainWindow, ToolDbWindowVM)
|
||||
' If ToolDbWindowVM.MatType <> 0 Then
|
||||
' ToolDbWindowV.Height = 640
|
||||
' ToolDbWindowV.Width = 1024
|
||||
' ToolDbWindowV.ShowDialog()
|
||||
' Else
|
||||
' Exit Sub
|
||||
' End If
|
||||
|
||||
' If Not SetUpUtility.IsValidToolHeadExitInSetUp() Then
|
||||
' SetUp_Background = Brushes.Red
|
||||
' Else
|
||||
' SetUp_Background = OmagOFFICEDictionary.Button_Static_Background
|
||||
' End If
|
||||
' End Sub
|
||||
|
||||
'#End Region ' ToolDbCommand
|
||||
|
||||
'#Region "MachDbCommand"
|
||||
|
||||
' ''' <summary>
|
||||
' ''' Returns a command that do Exec.
|
||||
' ''' </summary>
|
||||
' Public ReadOnly Property MachDbCommand As ICommand
|
||||
' Get
|
||||
' If m_cmdMachDb Is Nothing Then
|
||||
' m_cmdMachDb = New Command(AddressOf MachDb)
|
||||
' End If
|
||||
' Return m_cmdMachDb
|
||||
' End Get
|
||||
' End Property
|
||||
|
||||
' ''' <summary>
|
||||
' ''' Execute the Exec. This method is invoked by the ExecCommand.
|
||||
' ''' </summary>
|
||||
' Public Sub MachDb(ByVal param As Object)
|
||||
' If Not VerifyMachinesDir(m_sMachinesRoot) Then Return
|
||||
' ' ricarico il database per intercettare eventuali aggiornamenti fatti da altre istanze del programma (se la cartella Machines è condivisa)
|
||||
' If Not EgtMdbReload() Then
|
||||
' EgtOutLog("Impossible reloading machining Db")
|
||||
' MessageBox.Show(EgtMsg(MSG_MACHININGDBERRORS + 8), EgtMsg(MSG_MESSAGEBOX + 1), MessageBoxButton.OK, MessageBoxImage.Error)
|
||||
' Return
|
||||
' End If
|
||||
' Dim MachDbWindowVM As New EgtWPFLib5.MachiningDbWindowVM(CurrentMachine.sMachIniFile, Map.refSceneHostVM.MainScene.GetCtx(), "Stone")
|
||||
' Dim MachDbWindowV As New EgtWPFLib5.MachiningDbWindowV(Application.Current.MainWindow, MachDbWindowVM)
|
||||
|
||||
' If EgtWPFLib5.MachiningTreeViewItem.m_MatType <> 0 Then
|
||||
' MachDbWindowV.Height = 768
|
||||
' MachDbWindowV.Width = 1024
|
||||
' MachDbWindowV.ShowDialog()
|
||||
' Else
|
||||
' Exit Sub
|
||||
' End If
|
||||
|
||||
' End Sub
|
||||
|
||||
'#End Region ' MachDbCommand
|
||||
|
||||
'#Region "SetUpCommand"
|
||||
|
||||
' ''' <summary>
|
||||
' ''' Returns a command that do Exec.
|
||||
' ''' </summary>
|
||||
' Public ReadOnly Property SetUpCommand As ICommand
|
||||
' Get
|
||||
' If m_cmdSetUp Is Nothing Then
|
||||
' m_cmdSetUp = New Command(AddressOf SetUp)
|
||||
' End If
|
||||
' Return m_cmdSetUp
|
||||
' End Get
|
||||
' End Property
|
||||
|
||||
' ''' <summary>
|
||||
' ''' Execute the Exec. This method is invoked by the ExecCommand.
|
||||
' ''' </summary>
|
||||
' Public Sub SetUp(ByVal param As Object)
|
||||
' ' verifico che il file di configurazione attrezzaggio (lua) della macchina esista
|
||||
' If Not File.Exists(CurrentMachine.sMachDir & "\Scripts\" & SETUP_LUA) Then
|
||||
' EgtOutLog("SetUp error: SetUp configuration file doesn't exist ")
|
||||
' MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 7), EgtMsg(MSG_SETUPERRORS + 1), MessageBoxButton.OK, MessageBoxImage.Error)
|
||||
' Return
|
||||
' End If
|
||||
' ' carico Lua che contiene le funzioni per ottenere le posizioni valide dell'utensile selezionato,
|
||||
' ' e testa e uscita dell'utensile attrezzato
|
||||
' EgtLuaExecFile(CurrentMachine.sMachDir & "\Scripts\" & SETUP_LUA)
|
||||
' ' verifico che le teste riportate in configurazione esistano
|
||||
' Dim Index As Integer = 1
|
||||
' Dim nErr As Integer = 0
|
||||
' While nErr = 0
|
||||
' Dim sHead As String = String.Empty
|
||||
' nErr = 999
|
||||
' EgtLuaSetGlobIntVar("STU.INDEX", Index)
|
||||
' EgtLuaCallFunction("STU.GetTcPosHeadGroupFromPos")
|
||||
' ' Leggo variabili
|
||||
' EgtLuaGetGlobStringVar("STU.HEAD", sHead)
|
||||
' EgtLuaGetGlobIntVar("STU.ERR", nErr)
|
||||
' If nErr = 0 Then
|
||||
' If EgtGetHeadExitCount(sHead) = 0 Then
|
||||
' MessageBox.Show(EgtMsg(MSG_SETUPERRORS + 8), EgtMsg(MSG_SETUPERRORS + 1), MessageBoxButton.OK, MessageBoxImage.Error)
|
||||
' Return
|
||||
' End If
|
||||
' End If
|
||||
' Index += 1
|
||||
' End While
|
||||
' ' Reset lua
|
||||
' EgtLuaResetGlobVar("STU")
|
||||
|
||||
' Dim SetUpWindow As New SetUpWindowV(Application.Current.MainWindow, New SetUpWindowVM(CurrentMachine.sMachDir, CurrentMachine.sMachineName))
|
||||
' SetUpWindow.Height = 614
|
||||
' SetUpWindow.Width = 1024
|
||||
' SetUpWindow.ShowDialog()
|
||||
|
||||
' End Sub
|
||||
|
||||
'#End Region ' SetUpCommand
|
||||
|
||||
'#Region "MachOptionsCommand"
|
||||
|
||||
' ''' <summary>
|
||||
' ''' Returns a command that do Exec.
|
||||
' ''' </summary>
|
||||
' Public ReadOnly Property MachOptionsCommand As ICommand
|
||||
' Get
|
||||
' If m_cmdMachOptions Is Nothing Then
|
||||
' m_cmdMachOptions = New Command(AddressOf MachOptions)
|
||||
' End If
|
||||
' Return m_cmdMachOptions
|
||||
' End Get
|
||||
' End Property
|
||||
|
||||
' ''' <summary>
|
||||
' ''' Execute the Exec. This method is invoked by the ExecCommand.
|
||||
' ''' </summary>
|
||||
' Public Sub MachOptions(ByVal param As Object)
|
||||
|
||||
' End Sub
|
||||
|
||||
'#End Region ' MachOptionsCommand
|
||||
|
||||
'#End Region ' COMMANDS
|
||||
|
||||
'End Class
|
||||
|
||||
@@ -108,14 +108,9 @@ Public Class MainMenuVM
|
||||
m_SelPage = Page
|
||||
Select Case m_SelPage
|
||||
Case Pages.SUPERVISOR
|
||||
' Map.refMachGroupPanelVM.SetMachGroupState(False)
|
||||
InitSUPERVISOR()
|
||||
'Map.refTopCommandBarVM.IsEnabled = False
|
||||
Case Pages.CONFIG
|
||||
InitCONFIG()
|
||||
'Map.refMachGroupPanelVM.SetMachGroupState(False)
|
||||
'Map.refCONFIGTabVM.InitCONFIGation()
|
||||
'Map.refTopCommandBarVM.IsEnabled = False
|
||||
Case Pages.INPUTS
|
||||
InitINPUTS()
|
||||
Case Pages.OUTPUTS
|
||||
@@ -228,49 +223,11 @@ Public Class MainMenuVM
|
||||
For Each col In Map.refFeatureInPartInRawPartListVM.FeatureInPartInRawPartColumns
|
||||
col.ColumnVisibility = If(col.Visible, Visibility.Visible, Visibility.Collapsed)
|
||||
Next
|
||||
'' apro progetto proj
|
||||
'If Not IsNothing(Map.refProjManagerVM.CurrProj) Then
|
||||
' If Map.refProjManagerVM.CurrProj.bReloadProject Then
|
||||
' Map.refProjManagerVM.OpenProject(Map.refProjManagerVM.CurrProj)
|
||||
' ' aggiorno le colonne in base al tipo progetto
|
||||
' If Not IsNothing(Map.refProjectVM.BTLStructureVM) Then
|
||||
' Map.refRawPartListVM.UpdateColumns(Map.refProjectVM.BTLStructureVM.nPROJTYPE)
|
||||
' Map.refPartInRawPartListVM.UpdateColumns(Map.refProjectVM.BTLStructureVM.nPROJTYPE)
|
||||
' Else
|
||||
' Map.refRawPartListVM.UpdateColumns(BWType.BEAM)
|
||||
' Map.refPartInRawPartListVM.UpdateColumns(BWType.BEAM)
|
||||
' End If
|
||||
' DbControllers.m_ProjController.LockByProjId(Map.refProjManagerVM.CurrProj.nProjId, True)
|
||||
' ' aggiorno titolo
|
||||
' Map.refMainWindowVM.UpdateTitle()
|
||||
' Map.refProjManagerVM.NotifyPropertyChanged(NameOf(Map.refProjManagerVM.MruFileNames))
|
||||
' Else
|
||||
' ' verifico se il prod di provenienza ha piu' proj
|
||||
' If Not IsNothing(Map.refProdManagerVM.CurrProd) AndAlso Map.refProdManagerVM.CurrProd.nProjIdList.Count > 1 Then
|
||||
' ' se si rigenero BTLStructure
|
||||
' Map.refProjectVM.BTLStructureVM = New BTLStructureVM(BTLStructureM.CreateBTLStructure(Map.refProjManagerVM.CurrProj.nProjId))
|
||||
' End If
|
||||
' ' mostro tutti i pezzi
|
||||
' Map.refShowBeamPanelVM.ShowAll()
|
||||
' Map.refProjManagerVM.CurrProj.SetReloadProject(True)
|
||||
' End If
|
||||
' DbControllers.m_ProjController.LockByProjId(Map.refProjManagerVM.CurrProj.nProjId, True)
|
||||
'Else
|
||||
' Map.refSceneHostVM.MainController.NewProject()
|
||||
' Map.refProjectVM.BTLStructureVM = Nothing
|
||||
' Map.refProjectVM.MachGroupPanelVM = Nothing
|
||||
'End If
|
||||
Map.refMainWindowVM.NotifyPropertyChanged(NameOf(Map.refMainWindowVM.nSelTabPage))
|
||||
Return True
|
||||
End Function
|
||||
|
||||
Private Function ExitSUPERVISOR(bVerifyModification As Boolean) As Boolean
|
||||
' verifico se progetto modificato, e chiedo se salvare
|
||||
'If bVerifyModification Then
|
||||
' If Not ProjFileVM.VerifyProjectModification(Map.refProjManagerVM.CurrProj, ProjectType.PROJ) Then
|
||||
' Return False
|
||||
' End If
|
||||
'End If
|
||||
Map.refProjectVM.SetBottomPanel_Visibility(False)
|
||||
Map.refProjectVM.SetLeftPanel_Visibility(True)
|
||||
Map.refProjectVM.SetPartManager_Visibility(False)
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
Imports System.Threading
|
||||
Imports System.Math
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
Imports EgtBEAMWALL.Core
|
||||
@@ -197,8 +196,6 @@ Public Class MainWindowM
|
||||
#Region "METHODS"
|
||||
|
||||
Private Sub InitializeEgtEnvironment()
|
||||
'' Abilito drag and drop
|
||||
'Me.AllowDrop = True
|
||||
' Impostazione path radice per i dati
|
||||
m_sDataRoot = System.AppDomain.CurrentDomain.BaseDirectory
|
||||
If EgtUILib.GetPrivateProfileString(S_DATA, K_DATAROOT, "", m_sDataRoot, m_sDataRoot & "\" & DAT_FILE_NAME) = 0 Then
|
||||
|
||||
@@ -30,7 +30,6 @@
|
||||
</Style>
|
||||
</TabControl.ItemContainerStyle>
|
||||
<TabItem>
|
||||
<!--<EgtBEAMWALL:ProjectV DataContext="{StaticResource ProjectVM}"/>-->
|
||||
<ContentControl Content="{Binding ProjectContent}"/>
|
||||
</TabItem>
|
||||
<TabItem>
|
||||
@@ -40,7 +39,6 @@
|
||||
<EgtBEAMWALL:OutputsPageV DataContext="{StaticResource OutputsPageVM}"/>
|
||||
</TabItem>
|
||||
<TabItem>
|
||||
<!--<EgtBEAMWALL:ConfigurationPageV DataContext="{StaticResource ConfigurationPageVM}"/>-->
|
||||
<ContentControl Content="{Binding ConfigurationPageContent}"/>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
|
||||
@@ -83,40 +83,9 @@ Public Class MainWindowVM
|
||||
End Sub
|
||||
|
||||
Friend Sub ContentRendered()
|
||||
'' chiamata a caso su Db per inizializzarlo
|
||||
DbControllers.m_ProdController.FindByProdDbId(0)
|
||||
' Verifico che l'inizializzazione di tutte le parti del programma sia andata a buon fine
|
||||
' If Map.EndInit() Then
|
||||
' m_bInitStatus = True
|
||||
' altrimenti chiudo il programma
|
||||
' Else
|
||||
' m_bInitStatus = False
|
||||
' End If
|
||||
' Aggiorno visualizzazione unità di misura
|
||||
' Map.refStatusBarVM.SetMeasureUnit(If(EgtUiUnitsAreMM(), MeasureUnitOpt.MM, MeasureUnitOpt.INCH))
|
||||
' Se istanza oltre la prima, chiedo cosa aprire
|
||||
' If Not m_MainWindowM.bFirstInstance Then
|
||||
' Map.refProjectManagerVM.Open()
|
||||
' ' altrimenti verifico se richiesto ultimo progetto
|
||||
' ElseIf GetMainPrivateProfileInt(S_GENERAL, K_AUTOLOADLASTPROJ, 0) = 1 Then
|
||||
' Dim sLastProjectPath As String = String.Empty
|
||||
' GetMainPrivateProfileString(S_GENERAL, K_LASTPROJ, String.Empty, sLastProjectPath)
|
||||
' If Not String.IsNullOrWhiteSpace(sLastProjectPath) AndAlso File.Exists(sLastProjectPath) Then
|
||||
' Map.refProjectManagerVM.OpenProject(sLastProjectPath)
|
||||
' Else
|
||||
' Map.refProjectManagerVM.NewCmd()
|
||||
' End If
|
||||
' ' altrimenti nuovo progetto
|
||||
' Else
|
||||
' Map.refProjectManagerVM.NewCmd()
|
||||
' End If
|
||||
' apro in modalita' VIEW
|
||||
' Map.refMainMenuVM.SelPage = Pages.VIEW
|
||||
|
||||
' imposto MainWindow per finestra di Loading
|
||||
LoadingWndHelper.SetMainWindow(Application.Current.MainWindow)
|
||||
|
||||
|
||||
' leggo riga di comando
|
||||
Dim nCommandType As Integer = 0
|
||||
Dim nPage As Pages = Nothing
|
||||
@@ -193,10 +162,6 @@ Public Class MainWindowVM
|
||||
' sblocco interfaccia
|
||||
Map.refLeftPanelVM.bRestart = False
|
||||
End If
|
||||
'' se misura attiva, la disattivo
|
||||
'If Map.refInstrumentPanelVM.GetDistIsChecked Then
|
||||
' Map.refInstrumentPanelVM.SetGetDistance_IsChecked(False)
|
||||
'End If
|
||||
' pulisco output
|
||||
Map.refMyStatusBarVM.ClearOutputMessage()
|
||||
End If
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.IO
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtBEAMWALL.Core.ConstBeam
|
||||
Imports EgtUILib
|
||||
|
||||
Public Class OpenProjectFileDialogVM
|
||||
Inherits Core.OpenProjectFileDialogVM
|
||||
|
||||
@@ -1,9 +1,6 @@
|
||||
<DockPanel x:Class="OutputsPageV"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:EgtFloating="clr-namespace:EgtWPFLib5.EgtFloating;assembly=EgtWPFLib5"
|
||||
xmlns:EgtWPFLib5="clr-namespace:EgtWPFLib5;assembly=EgtWPFLib5"
|
||||
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Supervisor"
|
||||
xmlns:EgtBEAMWALLCORE="clr-namespace:EgtBEAMWALL.Core;assembly=EgtBEAMWALL.Core">
|
||||
xmlns:EgtBEAMWALL="clr-namespace:EgtBEAMWALL.Supervisor">
|
||||
<EgtBEAMWALL:VariablesListV DataContext="{Binding OutputVariableListVM}"/>
|
||||
</DockPanel>
|
||||
|
||||
@@ -23,8 +23,6 @@ Public Class OutputsPageVM
|
||||
#Region "Constructor"
|
||||
|
||||
Sub New()
|
||||
'' imposto riferimento in Map
|
||||
'Map.SetRefOutputsPageVM(Me)
|
||||
m_OutputVariableListVM = New VariablesListVM(S_OUTPUTVARIABLES)
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -58,17 +58,17 @@
|
||||
</TabControl.ItemContainerStyle>
|
||||
<TabItem Header="SCENE">
|
||||
<TabItem.Content>
|
||||
<EgtBEAMWALL:SceneHostV Grid.Column="0" Grid.Row="1"/>
|
||||
<EgtBEAMWALL:SceneHostV Grid.Row="1"/>
|
||||
</TabItem.Content>
|
||||
</TabItem>
|
||||
<TabItem Header="MDI">
|
||||
<TabItem.Content>
|
||||
<EgtBEAMWALL:MDIPageV DataContext="{StaticResource MDIPageVM}"/>
|
||||
<EgtBEAMWALL:OnlyProdMDIPageV DataContext="{StaticResource MDIPageVM}"/>
|
||||
</TabItem.Content>
|
||||
</TabItem>
|
||||
<TabItem Header="MACHINELOG">
|
||||
<TabItem.Content>
|
||||
<EgtBEAMWALL:MachineLogPageV DataContext="{StaticResource MachineLogPageVM}"/>
|
||||
<EgtBEAMWALL:OnlyProdMachineLogPageV DataContext="{StaticResource MachineLogPageVM}"/>
|
||||
</TabItem.Content>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
|
||||
@@ -35,11 +35,8 @@
|
||||
Grid.Row="0">
|
||||
<WrapPanel Orientation="Horizontal" Width="{Binding ActualWidth, ElementName=TOPTRAY}">
|
||||
<EgtBEAMWALL:ShowPanelV DataContext="{StaticResource ShowPanelVM}"/>
|
||||
<!--<EgtBEAMWALL:ShowBeamPanelV DataContext="{StaticResource ShowBeamPanelVM}"
|
||||
Visibility="{Binding DataContext.ShowBeamPanel_Visibility, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:ProjectV}}}"/>-->
|
||||
<EgtBEAMWALL:ViewPanelV DataContext="{StaticResource ViewPanelVM}"/>
|
||||
<EgtBEAMWALL:CalcPanelV DataContext="{StaticResource CALCPanelVM}"/>
|
||||
<!--<EgtBEAMWALL:InstrumentPanelV DataContext="{StaticResource InstrumentPanelVM}"/>-->
|
||||
</WrapPanel>
|
||||
</EgtFloating:EgtFloatingTray>
|
||||
|
||||
@@ -80,12 +77,6 @@
|
||||
Width="3"
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Stretch"/>
|
||||
|
||||
<!--<EgtBEAMWALL:BottomPanelV DockPanel.Dock="Bottom"
|
||||
DataContext="{StaticResource BottomPanelVM}"
|
||||
Tag="{Binding DataContext.BTLStructureVM.SelBTLPart, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:ProjectV}}}"
|
||||
Visibility="{Binding DataContext.BottomPanel_Visibility, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:ProjectV}}}"/>-->
|
||||
|
||||
</Grid>
|
||||
|
||||
</EgtFloating:EgtFloatingManager>
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.Threading
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtWPFLib5
|
||||
|
||||
@@ -198,14 +197,11 @@ Public Class ProjectVM
|
||||
#End Region ' CONSTRUCTOR
|
||||
|
||||
Friend Sub ManageIsEnabled(bIsEnabled As Boolean)
|
||||
'Map.refInstrumentPanelVM.SetInstrumentPanelIsEnabled(bIsEnabled)
|
||||
Map.refCALCPanelVM.SetCalcPanelIsEnabled(bIsEnabled)
|
||||
Map.refMainMenuVM.SetMainMenuIsEnabled(bIsEnabled)
|
||||
Map.refLeftPanelVM.SetLeftPanelIsEnabled(bIsEnabled)
|
||||
Map.refSupervisorManagerVM.SetSupervisorManagerIsEnabled(bIsEnabled)
|
||||
' aggiungere gestione colonne editabili delle tabelle
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
Imports System.IO
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtUILib
|
||||
Imports EgtBEAMWALL.Core
|
||||
|
||||
Public Class ProdFileVM
|
||||
Inherits Core.ProdFileVM
|
||||
|
||||
@@ -25,7 +25,6 @@ Public Class MySceneHostVM
|
||||
Private m_vtTotMove As Vector3d
|
||||
Private m_dSnapDist As Double = 0
|
||||
|
||||
|
||||
Private bReducedCut As Boolean = False
|
||||
Private m_bMagnetic As Boolean
|
||||
|
||||
@@ -160,7 +159,6 @@ Public Class MySceneHostVM
|
||||
MainScene.SetGridCursorPos(True)
|
||||
' modo di visualizzazione
|
||||
Dim nShowMode As Integer = GetMainPrivateProfileInt(S_SCENE, K_SHOWMODE, SM.SHADING)
|
||||
' Map.refShowPanelVM.SetShowMode(DirectCast(nShowMode, SM))
|
||||
' visualizzazione avanzata dei triangoli costituenti le superfici
|
||||
Dim bShowTriaAdv As Boolean = (GetMainPrivateProfileInt(S_SCENE, K_SHOWTRIAADV, 1) <> 0)
|
||||
EgtSetShowTriaAdv(bShowTriaAdv)
|
||||
@@ -318,11 +316,9 @@ Public Class MySceneHostVM
|
||||
End Sub
|
||||
|
||||
Private Sub OnCursorPos(ByVal sender As Object, ByVal sCursorPos As String)
|
||||
'Map.refStatusBarVM.SetCurrPos(sCursorPos)
|
||||
End Sub
|
||||
|
||||
Private Sub OnShowDistance(ByVal sender As Object, ByVal sDistance As String)
|
||||
'Map.refMyStatusBarVM.SetOutputMessage(sDistance)
|
||||
End Sub
|
||||
|
||||
Private Sub OnChangedSnapPointType(ByVal sender As Object, ByVal nSpType As SP, ByVal bUser As Boolean)
|
||||
@@ -332,32 +328,6 @@ Public Class MySceneHostVM
|
||||
Else
|
||||
BtnColor = Brushes.Bisque
|
||||
End If
|
||||
'Select Case nSpType
|
||||
' Case SP.PT_SKETCH
|
||||
' Map.refStatusBarVM.SetSnapPointType(EgtMsg(1102), BtnColor) 'Sketch Point
|
||||
' Case SP.PT_GRID
|
||||
' Map.refStatusBarVM.SetSnapPointType(EgtMsg(1104), BtnColor) 'Grid Point
|
||||
' Case SP.PT_END
|
||||
' Map.refStatusBarVM.SetSnapPointType(EgtMsg(1106), BtnColor) 'End Point
|
||||
' Case SP.PT_MID
|
||||
' Map.refStatusBarVM.SetSnapPointType(EgtMsg(1108), BtnColor) 'Mid Point
|
||||
' Case SP.CENTER
|
||||
' Map.refStatusBarVM.SetSnapPointType(EgtMsg(1110), BtnColor) 'Center
|
||||
' Case SP.CENTROID
|
||||
' Map.refStatusBarVM.SetSnapPointType(EgtMsg(1112), BtnColor) 'Centroid
|
||||
' Case SP.PT_NEAR
|
||||
' Map.refStatusBarVM.SetSnapPointType(EgtMsg(1114), BtnColor) 'Near Point
|
||||
' Case SP.PT_INTERS
|
||||
' Map.refStatusBarVM.SetSnapPointType(EgtMsg(1116), BtnColor) 'Inters Point
|
||||
' Case SP.PT_TANGENT
|
||||
' Map.refStatusBarVM.SetSnapPointType(EgtMsg(1118), BtnColor) 'Tang Point
|
||||
' Case SP.PT_PERPENDICULAR
|
||||
' Map.refStatusBarVM.SetSnapPointType(EgtMsg(1120), BtnColor) 'Perp Point
|
||||
' Case SP.PT_MINDIST
|
||||
' Map.refStatusBarVM.SetSnapPointType(EgtMsg(1122), BtnColor) 'MinDist Point
|
||||
' Case Else
|
||||
' Map.refStatusBarVM.SetSnapPointType("---", BtnColor)
|
||||
'End Select
|
||||
End Sub
|
||||
|
||||
#End Region ' EVENTS
|
||||
@@ -375,23 +345,6 @@ Public Class MySceneHostVM
|
||||
While nId <> GDB_ID.NULL
|
||||
' Recupero l'identificativo del pezzo cui appartiene
|
||||
Dim nPartId As Integer = EgtGetParent(EgtGetParent(nId))
|
||||
'Dim WallMachGroup As WallMachGroup = DirectCast(Map.refMachGroupPanelVM.SelectedMachGroup, WallMachGroup)
|
||||
'Dim bPartInTable As Boolean = (EgtGetParent(nPartId) = WallMachGroup.nRawPartId)
|
||||
'If EgtIsPart(nPartId) OrElse EgtIsDuplo(nPartId) OrElse bPartInTable Then
|
||||
' Dim nStat As Integer = GDB_ST.ON_
|
||||
' EgtGetStatus(nPartId, nStat)
|
||||
' ' Se già selezionato
|
||||
' If nStat = GDB_ST.SEL Then
|
||||
' ' Memorizzo Id da deselezionare
|
||||
' m_nIdToDesel = nPartId
|
||||
' Else
|
||||
' ' Memorizzo Id da selezionare
|
||||
' m_nIdToSel = nPartId
|
||||
' End If
|
||||
' ' Drag possibile
|
||||
' m_bDrag = True
|
||||
' Exit While
|
||||
'End If
|
||||
nId = EgtGetNextObjInSelWin()
|
||||
End While
|
||||
' Dati per drag
|
||||
@@ -407,10 +360,6 @@ Public Class MySceneHostVM
|
||||
If Not m_bDrag Or m_bDragging Then Return
|
||||
' Se primo movimento di drag, verifico di aver superato la soglia di movimento in pixel
|
||||
If m_bDragToStart Then
|
||||
'If Math.Abs(e.Location.X - m_locPrev.X) < m_nRestRadius And
|
||||
' Math.Abs(e.Location.Y - m_locPrev.Y) < m_nRestRadius Then
|
||||
' Return
|
||||
'End If
|
||||
m_bDragToStart = False
|
||||
End If
|
||||
' Determino cosa muovere
|
||||
@@ -481,7 +430,6 @@ Public Class MySceneHostVM
|
||||
Else
|
||||
EgtMove(nMoveId, -m_vtTotMove)
|
||||
End If
|
||||
'm_bFromParking = False
|
||||
' altrimenti caso con verifica durante il movimento
|
||||
Else
|
||||
' Basta reset alla fine
|
||||
@@ -498,10 +446,6 @@ Public Class MySceneHostVM
|
||||
m_bDrag = False
|
||||
m_nIdToSel = GDB_ID.NULL
|
||||
m_nIdToDesel = GDB_ID.NULL
|
||||
'' Se nessun pezzo selezionato, reset flag posizione selezionati
|
||||
'If EgtGetSelectedObjCount() = 0 Then
|
||||
' m_nPartPos = PART_POS.NONE_TABLE
|
||||
'End If
|
||||
EgtDraw()
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -234,14 +234,6 @@ Public Class SupervisorManagerVM
|
||||
Map.refMainWindowVM.UpdateTitle()
|
||||
' inizializzo visibilita' bottone done per i Part
|
||||
Map.refLeftPanelVM.NotifyPropertyChanged(NameOf(Map.refLeftPanelVM.DonePart_Visibility))
|
||||
'If Map.refMachGroupPanelVM.InitMachGroupList() Then
|
||||
' m_CurrProd = TempCurrProd
|
||||
' Map.refMainWindowVM.SetTitle(CurrProd.nProdId.ToString("0000") & " - EgtBEAMWALL")
|
||||
'Else
|
||||
'MessageBox.Show("Impossibile aprire gruppi di lavorazione del file!!")
|
||||
'Map.refSceneHostVM.MainController.NewProject()
|
||||
'Map.refMainWindowVM.SetTitle("New - EgtBEAMWALL")
|
||||
'End If
|
||||
Else
|
||||
MessageBox.Show("Impossibile aprire il file!!")
|
||||
Map.refSceneHostVM.MainController.NewProject()
|
||||
@@ -331,8 +323,6 @@ Public Class SupervisorManagerVM
|
||||
''' Execute the Open. This method is invoked by the OpenCommand.
|
||||
''' </summary>
|
||||
Public Sub OpenMruFile(ByVal param As Object)
|
||||
'' verifico se progetto modificato, e chiedo se salvare
|
||||
'If Not ProdFileVM.VerifyProjectModification(CurrProd) Then Return
|
||||
' ricavo l'Id e il progetto associato per l'apertura di quest'ultimo
|
||||
Dim PdId As Integer = 0
|
||||
Dim arrStrPdId As String() = DirectCast(param, String).Split("|")
|
||||
|
||||
@@ -178,10 +178,6 @@ Public Class LogEvent
|
||||
|
||||
Sub New(MachLog As MachLog)
|
||||
Me.New(MachLog.AlarmDateTime, MachLog.ResultType, MachLog.VarAddress, MachLog.VarValue)
|
||||
'm_EventDateTime = MachLog.AlarmDateTime
|
||||
'm_EventType = MachLog.ResultType
|
||||
'm_SupervisorId = MachLog.VarAddress
|
||||
'm_Value = MachLog.VarValue
|
||||
End Sub
|
||||
|
||||
Public Shared Function CreateMachLog(EventType As MachLogTypes, EventDateTime As DateTime, Value As String, SupervisorID As String)
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports EgtUILib
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
Friend Module MachParamIniFile
|
||||
|
||||
@@ -3,8 +3,6 @@
|
||||
Module Map
|
||||
|
||||
Private m_refMainWindowVM As MainWindowVM
|
||||
Private m_refMyStatusBarVM As MyStatusBarVM
|
||||
'Private m_refProjManagerVM As ProjManagerVM
|
||||
Private m_refSupervisorManagerVM As SupervisorManagerVM
|
||||
Private m_refProjectVM As ProjectVM
|
||||
Private m_refMainMenuVM As MainMenuVM
|
||||
@@ -13,17 +11,8 @@ Module Map
|
||||
Private m_refLeftPanelVM As LeftPanelVM
|
||||
Private m_refMachCommandMessagePanelVM As MachCommandMessagePanelVM
|
||||
Private m_refAxesPanelVM As AxesPanelVM
|
||||
'Private m_refBottomPanelVM As BottomPanelVM
|
||||
'Private m_refShowBeamPanelVM As ShowBeamPanelVM
|
||||
Private m_refConfigurationPageVM As ConfigurationPageVM
|
||||
Private m_refRawPartListVM As RawPartListVM
|
||||
'Private m_refWarehouseWndVM As WarehouseWndVM
|
||||
'Private m_refRawPartTabVM As RawPartTabVM
|
||||
'Private m_refNestingTabVM As NestingTabVM
|
||||
'Private m_refMachiningTabVM As MachiningTabVM
|
||||
'Private m_refSplitModeVM As SplitModeVM
|
||||
'Private m_refMoveRawModeVM As MoveRawModeVM
|
||||
'Private m_refSimulTabVM As SimulTabVM
|
||||
Private m_refMachManaging As MachManaging
|
||||
Private m_refCALCPanelVM As CALCPanelVM
|
||||
Private m_refSupervisorMachGroupPanelVM As SupervisorMachGroupPanelVM
|
||||
@@ -46,11 +35,6 @@ Module Map
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'Public ReadOnly Property refProjManagerVM As ProjManagerVM
|
||||
' Get
|
||||
' Return m_refProjManagerVM
|
||||
' End Get
|
||||
'End Property
|
||||
Public ReadOnly Property refSupervisorManagerVM As SupervisorManagerVM
|
||||
Get
|
||||
Return m_refSupervisorManagerVM
|
||||
@@ -123,18 +107,6 @@ Module Map
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'Public ReadOnly Property refBottomPanelVM As BottomPanelVM
|
||||
' Get
|
||||
' Return m_refBottomPanelVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refShowBeamPanelVM As ShowBeamPanelVM
|
||||
' Get
|
||||
' Return m_refShowBeamPanelVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
Public ReadOnly Property refConfigurationPageVM As ConfigurationPageVM
|
||||
Get
|
||||
Return m_refConfigurationPageVM
|
||||
@@ -147,54 +119,6 @@ Module Map
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'Public ReadOnly Property refWarehouseWndVM As WarehouseWndVM
|
||||
' Get
|
||||
' Return m_refWarehouseWndVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refOptionPanelVM As OptionPanelVM
|
||||
' Get
|
||||
' Return m_refOptionPanelVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refRawPartTabVM As RawPartTabVM
|
||||
' Get
|
||||
' Return m_refRawPartTabVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refNestingTabVM As NestingTabVM
|
||||
' Get
|
||||
' Return m_refNestingTabVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refMachiningTabVM As MachiningTabVM
|
||||
' Get
|
||||
' Return m_refMachiningTabVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refSplitModeVM As SplitModeVM
|
||||
' Get
|
||||
' Return m_refSplitModeVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refMoveRawModeVM As MoveRawModeVM
|
||||
' Get
|
||||
' Return m_refMoveRawModeVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
'Public ReadOnly Property refSimulTabVM As SimulTabVM
|
||||
' Get
|
||||
' Return m_refSimulTabVM
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
Public ReadOnly Property refFeatureInPartInRawPartListVM As FeatureInPartInRawPartListVM
|
||||
Get
|
||||
Return m_refFeatureInPartInRawPartListVM
|
||||
@@ -234,11 +158,6 @@ Module Map
|
||||
Return Not IsNothing(LibMap.refStatusBarVM)
|
||||
End Function
|
||||
|
||||
'Friend Function SetRefProjManagerVM(ProjManagerVM As ProjManagerVM) As Boolean
|
||||
' m_refProjManagerVM = ProjManagerVM
|
||||
' Return Not IsNothing(m_refProjManagerVM)
|
||||
'End Function
|
||||
|
||||
Friend Function SetRefSupervisorManagerVM(SupervisorManagerVM As SupervisorManagerVM) As Boolean
|
||||
m_refSupervisorManagerVM = SupervisorManagerVM
|
||||
Return Not IsNothing(m_refSupervisorManagerVM)
|
||||
@@ -299,16 +218,6 @@ Module Map
|
||||
Return Not IsNothing(m_refSupervisorMachGroupPanelVM)
|
||||
End Function
|
||||
|
||||
'Friend Function SetRefBottomPanelVM(BottomPanelVM As BottomPanelVM) As Boolean
|
||||
' m_refBottomPanelVM = BottomPanelVM
|
||||
' Return Not IsNothing(m_refBottomPanelVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefShowBeamPanelVM(ShowBeamPanelVM As ShowBeamPanelVM) As Boolean
|
||||
' m_refShowBeamPanelVM = ShowBeamPanelVM
|
||||
' Return Not IsNothing(m_refShowBeamPanelVM)
|
||||
'End Function
|
||||
|
||||
Friend Function SetRefConfigurationPageVM(ConfigurationPageVM As ConfigurationPageVM) As Boolean
|
||||
m_refConfigurationPageVM = ConfigurationPageVM
|
||||
Return Not IsNothing(m_refConfigurationPageVM)
|
||||
@@ -319,46 +228,6 @@ Module Map
|
||||
Return Not IsNothing(m_refRawPartListVM)
|
||||
End Function
|
||||
|
||||
'Friend Function SetRefWarehouseWndVM(WarehouseWndVM As WarehouseWndVM) As Boolean
|
||||
' m_refWarehouseWndVM = WarehouseWndVM
|
||||
' Return Not IsNothing(m_refWarehouseWndVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefOptionPanelVM(OptionPanelVM As OptionPanelVM) As Boolean
|
||||
' m_refOptionPanelVM = OptionPanelVM
|
||||
' Return Not IsNothing(m_refOptionPanelVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefRawPartTabVM(RawPartTabVM As RawPartTabVM) As Boolean
|
||||
' m_refRawPartTabVM = RawPartTabVM
|
||||
' Return Not IsNothing(m_refRawPartTabVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefNestingTabVM(NestingTabVM As NestingTabVM) As Boolean
|
||||
' m_refNestingTabVM = NestingTabVM
|
||||
' Return Not IsNothing(m_refNestingTabVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefMachiningTabVM(MachiningTabVM As MachiningTabVM) As Boolean
|
||||
' m_refMachiningTabVM = MachiningTabVM
|
||||
' Return Not IsNothing(m_refMachiningTabVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefSplitModeVM(SplitModeVM As SplitModeVM) As Boolean
|
||||
' m_refSplitModeVM = SplitModeVM
|
||||
' Return Not IsNothing(m_refSplitModeVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefMoveRawModeVM(MoveRawModeVM As MoveRawModeVM) As Boolean
|
||||
' m_refMoveRawModeVM = MoveRawModeVM
|
||||
' Return Not IsNothing(m_refMoveRawModeVM)
|
||||
'End Function
|
||||
|
||||
'Friend Function SetRefSimulTabVM(SimulTabVM As SimulTabVM) As Boolean
|
||||
' m_refSimulTabVM = SimulTabVM
|
||||
' Return Not IsNothing(m_refSimulTabVM)
|
||||
'End Function
|
||||
|
||||
Friend Function SetRefMachManaging(MachManaging As MachManaging) As Boolean
|
||||
m_refMachManaging = MachManaging
|
||||
Return Not IsNothing(m_refMachManaging)
|
||||
@@ -394,21 +263,13 @@ Module Map
|
||||
End Function
|
||||
Friend Function EndInit() As Boolean
|
||||
' Verifico se tutti i pezzi necessari sono stati caricati
|
||||
'Return Not IsNothing(m_refMainWindowVM) AndAlso Not IsNothing(m_refProjectVM) AndAlso
|
||||
' Not IsNothing(LibMap.refStatusBarVM) AndAlso Not IsNothing(m_refProjectManagerVM) AndAlso
|
||||
' Not IsNothing(LibMap.refSceneHostVM) AndAlso Not IsNothing(LibMap.refShowPanelVM) AndAlso
|
||||
' Not IsNothing(m_refVeinMatchPanelVM) AndAlso
|
||||
' Not IsNothing(m_refOptionPanelVM) AndAlso Not IsNothing(m_refRawPartTabVM) AndAlso
|
||||
' Not IsNothing(m_refNestingTabVM) AndAlso Not IsNothing(m_refSimulTabVM) AndAlso
|
||||
' Not IsNothing(m_refMachiningTabVM) AndAlso
|
||||
' LibMap.EndInit()
|
||||
Return Not IsNothing(m_refMainWindowVM) AndAlso 'Not IsNothing(m_refMainMenuVM) AndAlso
|
||||
Not IsNothing(LibMap.refStatusBarVM) AndAlso 'Not IsNothing(m_refProjManagerVM) AndAlso Not IsNothing(m_refProdManagerVM) AndAlso
|
||||
Return Not IsNothing(m_refMainWindowVM) AndAlso
|
||||
Not IsNothing(LibMap.refStatusBarVM) AndAlso
|
||||
Not IsNothing(m_refConfigurationPageVM) AndAlso Not IsNothing(m_refFeatureInPartInRawPartListVM) AndAlso
|
||||
Not IsNothing(m_refPartInRawPartListVM) AndAlso Not IsNothing(m_refAxesPanelVM) AndAlso
|
||||
Not IsNothing(LibMap.refSceneHostVM) AndAlso Not IsNothing(LibMap.refShowPanelVM) AndAlso
|
||||
Not IsNothing(m_refMachinePanelVM) AndAlso Not IsNothing(LibMap.refMachGroupPanelVM) AndAlso
|
||||
Not IsNothing(m_refRawPartListVM) AndAlso Not IsNothing(m_refMDIPageVM) AndAlso 'Not IsNothing(m_refWarehouseWndVM) AndAlso Not IsNothing(m_refShowBeamPanelVM) AndAlso
|
||||
Not IsNothing(m_refRawPartListVM) AndAlso Not IsNothing(m_refMDIPageVM) AndAlso
|
||||
Not IsNothing(m_refMachCommandMessagePanelVM) AndAlso Not IsNothing(m_refMachineLogPageVM) AndAlso LibMap.EndInit()
|
||||
End Function
|
||||
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.Windows.Threading
|
||||
Imports EgtWPFLib5
|
||||
Imports EgtBEAMWALL.Core
|
||||
|
||||
|
||||
@@ -1,13 +1,10 @@
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtBEAMWALL.DataLayer.DatabaseModels
|
||||
Imports EgtBEAMWALL.DataLayer.DatabaseModels
|
||||
|
||||
Public Class ViewerOptimizerComm
|
||||
|
||||
Private m_bTickInExecution As Boolean = False
|
||||
|
||||
Sub New()
|
||||
' imposto in Map
|
||||
'Map.SetRefMachManaging(Me)
|
||||
End Sub
|
||||
|
||||
Friend Sub Timer_Tick()
|
||||
|
||||
@@ -66,23 +66,6 @@
|
||||
Height="300"
|
||||
Width="300"
|
||||
Margin="5,0,5,5"/>
|
||||
<!--<StackPanel Orientation="Horizontal"
|
||||
HorizontalAlignment="Center"
|
||||
Grid.Row="2"
|
||||
Margin="0,0,0,5">
|
||||
<TextBlock Text="Face"
|
||||
Style="{StaticResource OptionTextBlock}"/>
|
||||
<ComboBox ItemsSource="{Binding SIDEList}"
|
||||
SelectedItem="{Binding nSelSIDE}"
|
||||
Style="{StaticResource FeatureComboBox}"/>
|
||||
<TextBlock Text="Group"
|
||||
Style="{StaticResource OptionTextBlock}"/>
|
||||
<ComboBox ItemsSource="{Binding GRPList}"
|
||||
SelectedItem="{Binding nSelGRP}"
|
||||
Style="{StaticResource FeatureComboBox}"/>
|
||||
<TextBlock Text="{Binding sName}"
|
||||
Style="{StaticResource OptionTextBlock}"/>
|
||||
</StackPanel>-->
|
||||
<Grid Grid.Row="2" Margin="0,0,0,5">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
|
||||
@@ -17,7 +17,6 @@
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<RowDefinition Height="Auto"/>
|
||||
<!--<RowDefinition Height="Auto"/>-->
|
||||
</Grid.RowDefinitions>
|
||||
|
||||
<Grid HorizontalAlignment="Center"
|
||||
|
||||
@@ -79,24 +79,16 @@
|
||||
Style="{StaticResource Dimension_TextBox}"/>
|
||||
</Grid>
|
||||
|
||||
<Grid Grid.Row="3"
|
||||
Margin="0,0,0,5">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<Button Grid.Column="1"
|
||||
Content="Ok"
|
||||
<UniformGrid Grid.Row="3"
|
||||
Columns="2"
|
||||
Margin="0,5,0,5">
|
||||
<Button Content="Ok"
|
||||
Command="{Binding Ok_Command}"
|
||||
IsDefault="True"
|
||||
Style="{StaticResource OnlyProdEgtWPFLib5_InputButton}"/>
|
||||
<Button Grid.Column="3"
|
||||
Content="Cancel"
|
||||
<Button Content="Cancel"
|
||||
IsCancel="True"
|
||||
Style="{StaticResource OnlyProdEgtWPFLib5_InputButton}"/>
|
||||
</Grid>
|
||||
</UniformGrid>
|
||||
</Grid>
|
||||
</EgtWPFLib5:EgtCustomWindow>
|
||||
|
||||
@@ -41,32 +41,6 @@
|
||||
</DataTemplate>
|
||||
</ItemsControl.ItemTemplate>
|
||||
</ItemsControl>
|
||||
<!--<Grid Margin="0,0,0,5">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
|
||||
<TextBlock Text="Lunghezza"
|
||||
Style="{StaticResource OptionTextBlock}"/>
|
||||
<EgtWPFLib5:EgtTextBox Text="{Binding sL}"
|
||||
Grid.Column="1"
|
||||
Width="65"/>
|
||||
</Grid>
|
||||
<Grid Margin="0,0,0,5"
|
||||
Grid.Row="1">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="1*"/>
|
||||
<ColumnDefinition Width="Auto"/>
|
||||
</Grid.ColumnDefinitions>
|
||||
<TextBlock Text="Ritaglio iniziale"
|
||||
Grid.Row="1"
|
||||
Style="{StaticResource OptionTextBlock}"/>
|
||||
<EgtWPFLib5:EgtTextBox Text="{Binding sPOSX}"
|
||||
Grid.Column="1"
|
||||
Grid.Row="1"
|
||||
Width="65"/>
|
||||
</Grid>-->
|
||||
<Grid Grid.Row="2"
|
||||
Margin="0,0,0,5">
|
||||
<Grid.ColumnDefinitions>
|
||||
|
||||
@@ -166,12 +166,6 @@ Public Class AddRawPartWndVM
|
||||
Next
|
||||
' se non ci sono problemi esco restituendo vero
|
||||
RaiseEvent m_CloseWindow(True)
|
||||
'If Not IsNothing(m_dL) AndAlso m_dL > 0 AndAlso
|
||||
' Not IsNothing(m_dPOSX) AndAlso m_dPOSX >= 0 Then
|
||||
' RaiseEvent m_CloseWindow(True)
|
||||
'Else
|
||||
' MessageBox.Show("Errore! Impossibile creare una barra con questi parametri", "Errore")
|
||||
'End If
|
||||
End Sub
|
||||
|
||||
#End Region ' Ok
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.IO
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
Imports EgtBEAMWALL.Core
|
||||
|
||||
@@ -165,14 +165,7 @@ Public Class BTLDataWndVM
|
||||
End Property
|
||||
|
||||
Public Sub Ok()
|
||||
''verifico che tutti i campi contengano un valore valido
|
||||
'If Not IsNothing(m_dL) AndAlso m_dL > 0 AndAlso
|
||||
' Not IsNothing(m_dW) AndAlso m_dW >= 0 AndAlso
|
||||
' Not IsNothing(m_dH) AndAlso m_dH >= 0 Then
|
||||
RaiseEvent m_CloseWindow(True)
|
||||
'Else
|
||||
' MessageBox.Show("Errore! Impossibile creare una feature con questi parametri", "Errore")
|
||||
'End If
|
||||
End Sub
|
||||
|
||||
#End Region ' Ok
|
||||
|
||||
@@ -189,7 +189,6 @@ Public Class BTLPartManagerVM
|
||||
|
||||
Public Sub NewRawPart(bLast As Boolean)
|
||||
If IsNothing(ProjectManagerVM.CurrProd) Then Return
|
||||
'Dim SelPart As BTLPartVM = Map.refProjectVM.BTLStructureVM.SelBTLPart
|
||||
Dim SelParts As List(Of BTLPartVM) = Map.refProjectVM.BTLStructureVM.SelBTLParts.ToList()
|
||||
If IsNothing(SelParts) OrElse SelParts.Count <= 0 Then Return
|
||||
' verifico che abbiano tutti la stessa sezione
|
||||
@@ -968,8 +967,6 @@ Public Class BTLPartManagerVM
|
||||
EgtBeamSetPartBox(AddPartWndVM.dL, AddPartWndVM.dH, AddPartWndVM.dW)
|
||||
' se progetto pareti e vista ruotata
|
||||
If nType = BWType.WALL AndAlso (CurrentMachine.ViewDir = VT.ISO_NW OrElse CurrentMachine.ViewDir = VT.ISO_NE) Then
|
||||
'' ruoto le pareti di 180 per raddrizzarle rispetto alla vista
|
||||
'NewPart.Rotation(True, Map.refProjectVM.BTLStructureVM.nPROJTYPE, 180, False)
|
||||
' recupero il box del pezzo
|
||||
Dim nBoxLayerId As Integer = EgtGetFirstNameInGroup(nNewPartId, "Box")
|
||||
Dim b3Solid As New BBox3d
|
||||
@@ -1021,8 +1018,6 @@ Public Class BTLPartManagerVM
|
||||
Dim CurrSelBTLParts As List(Of BTLPartVM) = Map.refProjectVM.BTLStructureVM.SelBTLParts.ToList()
|
||||
For RemoveIndex = CurrSelBTLParts.Count - 1 To 0 Step -1
|
||||
RemovePart(CurrSelBTLParts(RemoveIndex), RemoveIndex = 0)
|
||||
' imposto vista tutti i pezzi
|
||||
'Map.refShowBeamPanelVM.ShowAll(RemoveIndex = 0)
|
||||
Next
|
||||
End If
|
||||
End Sub
|
||||
|
||||
@@ -164,8 +164,6 @@ Public Class BTLFeatureVM
|
||||
ResetCalcFeature()
|
||||
' se in View
|
||||
If Map.refMainMenuVM.SelPage = Pages.VIEW OrElse (Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE AndAlso Not IsNothing(m_BTLPartM)) Then
|
||||
' imposto modificato per copie
|
||||
'Dim cc = Map.refMachGroupPanelVM.MachGroupVMList
|
||||
MyMachGroupPanelM.SetDuploModified(m_BTLPartM.nPartId)
|
||||
End If
|
||||
NotifyPropertyChanged(NameOf(bDO))
|
||||
@@ -484,12 +482,6 @@ Public Class BTLFeatureVM
|
||||
Case FreeContourManagerVM.FreeContourTypes.ONEWITHANGLES
|
||||
Case FreeContourManagerVM.FreeContourTypes.TWO
|
||||
End Select
|
||||
'm_PBTLParamVMList(0).sName
|
||||
'm_PBTLParamVMList(0).dValue
|
||||
'm_QBTLParamVMList(0).sName
|
||||
'm_QBTLParamVMList(0).dValue
|
||||
'Map.refFreeContourManagerVM.nNewPathId
|
||||
'Map.refFreeContourManagerVM.nNewSecondPathId
|
||||
' disattivo modalita' contorno libero
|
||||
Map.refFreeContourManagerVM.Close(True)
|
||||
End Sub
|
||||
@@ -614,7 +606,6 @@ Public Class MenuItemVm
|
||||
' imposto modalita' update multiplo
|
||||
BTLFeatureVM.bDO_MultipleUpdate = True
|
||||
' aggiorno tutte le feature del pezzo
|
||||
'For FeatureVMIndex = 0 To Map.refProjectVM.BTLStructureVM.SelBTLPart.BTLFeatureVMList.Count - 1
|
||||
Dim SameProcFeatureList As List(Of BTLFeatureVM) = Map.refProjectVM.BTLStructureVM.SelBTLPart.BTLFeatureVMList.Where(Function(x) x.nPRC = ParentFeature.nPRC AndAlso x.GRPList.Contains(ParentFeature.nSelGRP)).ToList()
|
||||
For FeatureVMIndex = 0 To SameProcFeatureList.Count - 1
|
||||
If FeatureVMIndex = SameProcFeatureList.Count - 1 Then
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports EgtUILib
|
||||
Imports EgtWPFLib5
|
||||
|
||||
@@ -267,26 +266,6 @@ Public Class BTLParamVM
|
||||
m_BTLFeatureM = Nothing
|
||||
End Sub
|
||||
|
||||
'' new per double e length
|
||||
'Sub New(ParentFeature As BTLFeatureVM, IsP As Boolean, nType As BTLParamType, sParamName As String, dMin As Double, dMax As Double, dDefault As Double, sDescription As String)
|
||||
' MyBase.New(ParentFeature, IsP, nType, sParamName, dMin, dMax, dDefault, sDescription)
|
||||
'End Sub
|
||||
|
||||
'' new per stringhe
|
||||
'Sub New(ParentFeature As BTLFeatureVM, IsP As Boolean, nType As BTLParamType, sParamName As String, sDescription As String)
|
||||
' MyBase.New(ParentFeature, IsP, nType, sParamName, sDescription)
|
||||
'End Sub
|
||||
|
||||
'' new per combobox
|
||||
'Sub New(ParentFeature As BTLFeatureVM, IsP As Boolean, nType As BTLParamType, sParamName As String, nMin As Integer, nMax As Integer, nDefault As Integer, sDescription As String, ValueList As List(Of String))
|
||||
' MyBase.New(ParentFeature, IsP, nType, sParamName, nMin, nMax, nDefault, sDescription, ValueList)
|
||||
'End Sub
|
||||
|
||||
'' new per parametro vuoto
|
||||
'Sub New(IsP As Boolean, nType As BTLParamType, sParamName As String)
|
||||
' MyBase.New(IsP, nType, sParamName)
|
||||
'End Sub
|
||||
|
||||
#End Region ' CONSTRUCTOR
|
||||
|
||||
Friend Sub UpdateParamValue(dNewValue As Double, sNewValue As String, Optional bDraw As Boolean = True)
|
||||
@@ -352,7 +331,6 @@ Public Class BTLParamVM
|
||||
|
||||
If bShowSolid Then Map.refProjectVM.BTLStructureVM.ShowSolid(GDB_ID.NULL, True, False)
|
||||
If bDraw Then EgtDraw()
|
||||
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
|
||||
@@ -4,7 +4,6 @@ Imports EgtUILib
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports System.Collections.Specialized
|
||||
Imports System.ComponentModel
|
||||
Imports System.Windows.Threading
|
||||
|
||||
Public Class BTLPartVM
|
||||
Inherits VMBase
|
||||
@@ -19,22 +18,6 @@ Public Class BTLPartVM
|
||||
End Property
|
||||
Private m_BTLStructureM As BTLStructureM
|
||||
|
||||
'Private m_IsSelected As Boolean
|
||||
'Public Property IsSelected As Boolean
|
||||
' Get
|
||||
' Return m_IsSelected
|
||||
' End Get
|
||||
' Set(value As Boolean)
|
||||
' m_IsSelected = value
|
||||
' Map.refProjectVM.BTLStructureVM.UpdateSelBTLParts()
|
||||
' End Set
|
||||
'End Property
|
||||
'Friend Sub SetIsSelected(value As Boolean, Optional bByOptim As Boolean = False)
|
||||
' m_IsSelected = value
|
||||
' Map.refProjectVM.BTLStructureVM.UpdateSelBTLParts(False, bByOptim)
|
||||
' NotifyPropertyChanged(NameOf(IsSelected))
|
||||
'End Sub
|
||||
|
||||
Public ReadOnly Property nPartId As Integer
|
||||
Get
|
||||
Return m_BTLPartM.nPartId
|
||||
@@ -161,7 +144,7 @@ Public Class BTLPartVM
|
||||
' elimino pezzo copia
|
||||
EgtRemovePartFromRawPart(nDuploId)
|
||||
EgtErase(nDuploId)
|
||||
'' recupero gruppo di lavorazione e trave dell'interfaccia
|
||||
' recupero gruppo di lavorazione e trave dell'interfaccia
|
||||
Dim BeamMachGroup As MyMachGroupVM = Map.refMachGroupPanelVM.MachGroupVMList.FirstOrDefault(Function(x) x.Id = nMachGroupId)
|
||||
If Not IsNothing(BeamMachGroup) Then
|
||||
Dim Beam As PartVM = BeamMachGroup.PartVMList.FirstOrDefault(Function(x) x.nPartId = nDuploId)
|
||||
@@ -974,20 +957,6 @@ Public Class BTLPartVM
|
||||
End Set
|
||||
End Property
|
||||
|
||||
'Protected m_sUSERATTRIBUTE As String
|
||||
'Public Property sUSERATTRIBUTE As String
|
||||
' Get
|
||||
' Return m_sUSERATTRIBUTE
|
||||
' End Get
|
||||
' Set(value As String)
|
||||
' If EgtSetInfo(m_nPartId, BTL_PRT_USERATTRIBUTE, value) Then
|
||||
' m_sUSERATTRIBUTE = value
|
||||
' Else
|
||||
' NotifyPropertyChanged("sUSERATTRIBUTE")
|
||||
' End If
|
||||
' End Set
|
||||
'End Property
|
||||
|
||||
Public Property sCOMMENT As String
|
||||
Get
|
||||
Return m_BTLPartM.sCOMMENT
|
||||
@@ -1961,11 +1930,6 @@ Public Class BTLPartVM
|
||||
NotifyPropertyChanged(NameOf(sADDED))
|
||||
End Sub
|
||||
|
||||
'Friend Sub AddPartToProd(Optional PartQty As Integer = 1)
|
||||
' m_BTLPartM.nINPROD += PartQty
|
||||
' NotifyPropertyChanged(NameOf(sADDED))
|
||||
'End Sub
|
||||
|
||||
Friend Sub RefreshPartInProd()
|
||||
NotifyPropertyChanged(NameOf(nINPROD))
|
||||
NotifyPropertyChanged(NameOf(Foreground))
|
||||
@@ -2162,9 +2126,8 @@ Public Class BTLPartVM
|
||||
Dim PartColor As New Color3d(192, 192, 192)
|
||||
' Eseguo modifica con dialogo
|
||||
If SelectColor(m_BTLPartM.colCOLOR, PartColor) Then
|
||||
'm_colCOLOR = PartColor
|
||||
sCOLRGB = PartColor.ToString
|
||||
NotifyPropertyChanged("PartColour")
|
||||
NotifyPropertyChanged(NameOf(PartColour))
|
||||
End If
|
||||
End Sub
|
||||
|
||||
@@ -2239,7 +2202,6 @@ Public Class BTLPartVM
|
||||
Case NameOf(sender.bDO), NameOf(sender.sPriority)
|
||||
NotifyPropertyChanged(NameOf(bDOALL))
|
||||
' setto pezzo da ricalcolare
|
||||
'ResetCalcTotalPart()
|
||||
CalcGlobalUpdate(True)
|
||||
End Select
|
||||
End Sub
|
||||
|
||||
@@ -97,7 +97,6 @@ Public Class BTLStructureVM
|
||||
EgtResetMark(BTLPart.nPartId)
|
||||
Next
|
||||
' mostro barra di gestione pezzo
|
||||
'Map.refProjectVM.NotifyPropertyChanged(NameOf(Map.refProjectVM.PartManager_Visibility))
|
||||
Map.refProjectVM.NotifyPropertyChanged(NameOf(Map.refProdProjManagerVM.PartManager_Visibility))
|
||||
Case SelectionTypes.HIGHLIGHT
|
||||
' imposto modalita' nulla su vista feature
|
||||
@@ -122,16 +121,12 @@ Public Class BTLStructureVM
|
||||
' se attivata opzione, li assemblo
|
||||
Map.refProjectVM.BTLStructureVM.ShowBuilding(If(Map.refMainMenuVM.SelPage = Pages.VIEW OrElse Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE, Map.refShowBeamPanelVM.ShowBuilding_IsChecked, False), False)
|
||||
' nascondo barra di gestione pezzo
|
||||
'Map.refProjectVM.NotifyPropertyChanged(NameOf(Map.refProjectVM.PartManager_Visibility))
|
||||
Map.refProjectVM.NotifyPropertyChanged(NameOf(Map.refProdProjManagerVM.PartManager_Visibility))
|
||||
End Select
|
||||
' aggiornamento grafica
|
||||
'Map.refLeftPanelVM.PartShowAllChanged()
|
||||
Configuration.UpdateGraphics()
|
||||
'Map.refLeftPanelVM.FeatureSelectionChanged()
|
||||
If Not IsNothing(Map.refFeatureListManagerVM) Then Map.refFeatureListManagerVM.FeatureSelectionChanged()
|
||||
Map.refCALCPanelVM.SetIsEnabledForSelPart()
|
||||
'Map.refProjectVM.NotifyPropertyChanged(NameOf(Map.refProjectVM.PartManager_Visibility))
|
||||
Map.refProjectVM.NotifyPropertyChanged(NameOf(Map.refProdProjManagerVM.PartManager_Visibility))
|
||||
End Sub
|
||||
|
||||
@@ -149,41 +144,6 @@ Public Class BTLStructureVM
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'Friend Sub UpdateSelBTLParts(Optional bFromSelPart As Boolean = False, Optional bByOptim As Boolean = False)
|
||||
' Dim nOldSelCount As Integer = m_SelBTLPartsCnt
|
||||
' Dim nSelCount As Integer = BTLPartVMList.LongCount(Function(x) x.IsSelected)
|
||||
' m_SelBTLPartsCnt = nSelCount
|
||||
' If Not bByOptim AndAlso (nOldSelCount <> nSelCount AndAlso (nOldSelCount = 1 OrElse nSelCount = 1)) OrElse bFromSelPart Then
|
||||
' 'Map.refLeftPanelVM.PartShowAllChanged()
|
||||
' If Not IsNothing(Map.refFeatureListManagerVM) Then Map.refFeatureListManagerVM.PartShowAllChanged()
|
||||
' If Not IsNothing(Map.refBTLPartManagerVM) Then Map.refBTLPartManagerVM.PartShowAllChanged()
|
||||
' Map.refFeatureListManagerVM.FeatureSelectionChanged()
|
||||
' 'Map.refLeftPanelVM.FeatureSelectionChanged()
|
||||
' Map.refCALCPanelVM.SetIsEnabledForSelPart()
|
||||
' Map.refProjectVM.NotifyPropertyChanged(NameOf(Map.refProjectVM.PartManager_Visibility))
|
||||
' End If
|
||||
' If nSelCount = 1 Then
|
||||
' If bByOptim Then
|
||||
' m_SelBTLPart = BTLPartVMList.FirstOrDefault(Function(x) x.IsSelected)
|
||||
' Else
|
||||
' SelBTLPart = BTLPartVMList.FirstOrDefault(Function(x) x.IsSelected)
|
||||
' End If
|
||||
' Else
|
||||
' If bByOptim Then
|
||||
' m_SelBTLPart = Nothing
|
||||
' Else
|
||||
' SelBTLPart = Nothing
|
||||
' ' mostro in parte bassa dati BTL
|
||||
' Map.refBottomPanelVM.SetSelPartFeatureTab(BottomPanelVM.PartFeatureTab.STRUCTURE_)
|
||||
' ' mostro pezzi selezionati
|
||||
' Map.refProjectVM.BTLStructureVM.ShowAll(False, True)
|
||||
' Core.ViewPanelVM.BWSetView(VT.ISO_SW, False)
|
||||
' EgtZoom(ZM.ALL)
|
||||
' End If
|
||||
' NotifyPropertyChanged(NameOf(SelBTLPart))
|
||||
' End If
|
||||
'End Sub
|
||||
|
||||
Private Sub SelBTLParts_CollectionChanged(sender As Object, e As NotifyCollectionChangedEventArgs)
|
||||
If m_bOnlySelectItem Then Return
|
||||
Select Case e.Action
|
||||
@@ -324,16 +284,9 @@ Public Class BTLStructureVM
|
||||
' deevidenzio MachGroup e Duplo di questo pezzo
|
||||
Configuration.ResetSearchPiece(BtlPart.nPartId)
|
||||
' seleziono pagina BottomPanel
|
||||
'Map.refBottomPanelVM.SetSelPartFeatureTab(BottomPanelVM.PartFeatureTab.NULL)
|
||||
If bDraw Then EgtDraw()
|
||||
End Sub
|
||||
|
||||
'Friend ReadOnly Property SelBTLPartList As List(Of BTLPartVM)
|
||||
' Get
|
||||
' Return m_BTLPartVMList.Where(Function(x) x.IsSelected).ToList()
|
||||
' End Get
|
||||
'End Property
|
||||
|
||||
Private m_SelBTLPart As BTLPartVM = Nothing
|
||||
Public Property SelBTLPart As BTLPartVM
|
||||
Get
|
||||
@@ -386,7 +339,6 @@ Public Class BTLStructureVM
|
||||
End Set
|
||||
End Property
|
||||
|
||||
|
||||
Friend Sub SetSelBTLPart(SelBTLPart As BTLPartVM, Optional bByOptim As Boolean = False, Optional bSingleHighlight As Boolean = False)
|
||||
If bByOptim Then
|
||||
' annullo evidenziazione MachGroup e Duplo
|
||||
@@ -638,15 +590,7 @@ Public Class BTLStructureVM
|
||||
Case Else
|
||||
Return BWType.NULL
|
||||
End Select
|
||||
'Return m_BTLStructureM.m_nPROJTYPE
|
||||
End Get
|
||||
'Set(value As BWType)
|
||||
' If EgtSetInfo(m_BTLStructureM.nBTLInfoId, BTL_GEN_PROJTYPE, value) Then
|
||||
' m_BTLStructureM.m_nPROJTYPE = value
|
||||
' Else
|
||||
' NotifyPropertyChanged(NameOf(nPROJTYPE))
|
||||
' End If
|
||||
'End Set
|
||||
End Property
|
||||
|
||||
Public Property sLISTNAME As String
|
||||
@@ -1062,13 +1006,9 @@ Public Class BTLStructureVM
|
||||
If Not IsNothing(SelBTLPart) Then
|
||||
' se pezzo solido, lo riporto normale
|
||||
Configuration.DeselectSolid()
|
||||
'If Map.refShowBeamPanelVM.ShowSolid_IsChecked Then
|
||||
' Map.refShowBeamPanelVM.SetShowSolid(False)
|
||||
'End If
|
||||
' tolgo pezzo selezionato
|
||||
SelBTLPart.SelBTLFeatureVM = Nothing
|
||||
End If
|
||||
'If Not bOnlySelected Then SetSelBTLPart(Nothing)
|
||||
' mostro tutti i pezzi
|
||||
' creo lista id presenti
|
||||
Dim BTLPartIdList As List(Of Integer) = (From Part In BTLPartVMList
|
||||
@@ -1077,7 +1017,6 @@ Public Class BTLStructureVM
|
||||
Dim nGeomPartId As Integer = EgtGetFirstPart()
|
||||
While nGeomPartId <> GDB_ID.NULL
|
||||
Dim CurrPart As BTLPartVM = BTLPartVMList.FirstOrDefault(Function(x) x.nPartId = nGeomPartId)
|
||||
' If Not IsNothing(CurrPart) AndAlso (Not bOnlySelected OrElse (bOnlySelected AndAlso CurrPart.IsSelected)) Then
|
||||
If Not IsNothing(CurrPart) AndAlso Not bOnlySelected Then
|
||||
Dim nMode As Integer
|
||||
EgtGetMode(CurrPart.nPartId, nMode)
|
||||
@@ -1117,13 +1056,6 @@ Public Class BTLStructureVM
|
||||
End If
|
||||
nPartId = EgtGetNextPart(nPartId)
|
||||
End While
|
||||
'For Each Part As BTLPartVM In BTLPartVMList
|
||||
' Dim nMode As Integer
|
||||
' EgtGetMode(Part.nPartId, nMode)
|
||||
' If nMode <> GDB_MD.HIDDEN Then
|
||||
' EgtSetMode(Part.nPartId, GDB_MD.HIDDEN)
|
||||
' End If
|
||||
'Next
|
||||
' ripristino precedente impostazione modificato
|
||||
DisableMgr.ReEnable()
|
||||
Core.ViewPanelVM.BWSetView(VT.ISO_SW, False)
|
||||
@@ -1283,7 +1215,6 @@ Public Class BTLStructureVM
|
||||
|
||||
Friend Sub UpdateSection(NewPartSection As SectionXMaterial, OldPartSection As SectionXMaterial)
|
||||
If IsNothing(BTLPartVMList) Then Return
|
||||
'If Map.refProjectVM.BTLStructureVM.nPROJTYPE = MachineType.BEAM Then
|
||||
' verifico se era unico con vecchia sezione
|
||||
If Not m_BTLPartVMList.Any(Function(x) x.Section = OldPartSection) Then
|
||||
' nel caso seleziono filtro generico
|
||||
@@ -1296,9 +1227,6 @@ Public Class BTLStructureVM
|
||||
If Not m_SectionList.Any(Function(x) x = NewPartSection) Then
|
||||
m_SectionList.Add(NewPartSection)
|
||||
End If
|
||||
'ElseIf Map.refProjectVM.BTLStructureVM.nPROJTYPE = MachineType.WALL Then
|
||||
' ' se ruoto o inverto parete, la sezione non cambia
|
||||
'End If
|
||||
End Sub
|
||||
|
||||
' funzione che aggiorna totale tempi a fine calcolo
|
||||
@@ -1379,11 +1307,6 @@ Public Class BTLStructureVM
|
||||
GroupList.Add(sender.sMATERIAL)
|
||||
End If
|
||||
Case NameOf(sender.sW), NameOf(sender.sH), NameOf(sender.sL)
|
||||
'If Not SectionList.Contains(sender.Section) Then
|
||||
' SectionList.Add(sender.Section)
|
||||
'End If
|
||||
'Case NameOf(sender.sROTATED)
|
||||
' UpdateSection(CType(sender, BTLPartVM).BTLPartM)
|
||||
Case NameOf(sender.nDONE)
|
||||
NotifyPropertyChanged(NameOf(sBTLDoneTime))
|
||||
NotifyPropertyChanged(NameOf(sBTLRemainingTime))
|
||||
|
||||
@@ -84,8 +84,6 @@ Public Class BlockedWndVM
|
||||
EgtOpenFile(sCurrFilePath)
|
||||
' aggiungo a lista nuovo MachGroup
|
||||
Map.refProjectVM.MachGroupPanelVM.AddMachGroupToList(SupervisorCommThread.m_AddedMachGroupId)
|
||||
'' seleziono ultimo gruppo
|
||||
'Map.refProjectVM.MachGroupPanelVM.SelLastMachGroup()
|
||||
End If
|
||||
Map.refMainWindowVM.m_ManagingSupervisorStop = False
|
||||
RaiseEvent m_CloseWindow(True)
|
||||
@@ -101,15 +99,6 @@ Public Class BlockedWndVM
|
||||
NotifyPropertyChanged(NameOf(Msg_Text))
|
||||
' mando messaggio di blocco avvenuto
|
||||
DbControllers.m_StatusMapController.UpdateAction("", ProjectManagerVM.CurrProd.nProdId, ProjectManagerVM.CurrProd.nProdId, StatusMapItemType.Comm, StatusMapOpType.ViewOptimStoped, "")
|
||||
'ElseIf m_nIndex > 17 Then
|
||||
' 'If m_Waiting_Timer.IsEnabled Then m_Waiting_Timer.Stop()
|
||||
' If Not SupervisorCommThread.bViewerOptimizerBlocked Then
|
||||
' ' ricarico progetto
|
||||
' Dim sCurrFilePath As String = ""
|
||||
' EgtGetCurrFilePath(sCurrFilePath)
|
||||
' EgtOpenFile(sCurrFilePath)
|
||||
' RaiseEvent m_CloseWindow(True)
|
||||
' End If
|
||||
End If
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -6,7 +6,6 @@
|
||||
Height="350"
|
||||
Visibility="{Binding BottomPanel_Visibility}">
|
||||
|
||||
<!--<EgtWPFLib5:EgtScrollViewer Focusable="False">-->
|
||||
<TabControl SelectedIndex="{Binding SelPartFeatureTab}"
|
||||
TabStripPlacement="Right"
|
||||
Margin="5">
|
||||
@@ -85,24 +84,10 @@
|
||||
</TabItem.Content>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<!--<TabControl Grid.Column="1"
|
||||
Grid.Row="1"
|
||||
TabStripPlacement="Bottom"
|
||||
Margin="2.5,5,5,5">
|
||||
<TabControl.ItemContainerStyle>
|
||||
<Style TargetType="{x:Type TabItem}">
|
||||
<Setter Property="Visibility" Value="Collapsed"/>
|
||||
</Style>
|
||||
</TabControl.ItemContainerStyle>
|
||||
<TabItem Header="Parameter">
|
||||
<TabItem.Content>-->
|
||||
<Image Grid.Column="1"
|
||||
Grid.Row="1"
|
||||
Source="{Binding sCurrDraw}"
|
||||
Margin="5"/>
|
||||
<!--</TabItem.Content>
|
||||
</TabItem>
|
||||
</TabControl>-->
|
||||
<TextBlock Grid.Row="2" Grid.ColumnSpan="2"
|
||||
Text="{Binding Tag.SelBTLPart.SelBTLFeatureVM.sCALC_MSG, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BottomPanelV}}}"
|
||||
Foreground="{Binding Tag.SelBTLPart.SelBTLFeatureVM.Calc_Background, RelativeSource={RelativeSource AncestorType={x:Type EgtBEAMWALL:BottomPanelV}}}"
|
||||
@@ -118,5 +103,4 @@
|
||||
</TabItem.Content>
|
||||
</TabItem>
|
||||
</TabControl>
|
||||
<!--</EgtWPFLib5:EgtScrollViewer>-->
|
||||
</Grid>
|
||||
|
||||
@@ -4,7 +4,6 @@ Imports EgtWPFLib5
|
||||
Imports EgtBEAMWALL.Core
|
||||
Imports System.Collections.ObjectModel
|
||||
Imports System.Windows.Threading
|
||||
Imports System.Data.Entity.Core.Metadata.Edm
|
||||
|
||||
Public Class CALCPanelVM
|
||||
Inherits VMBase
|
||||
@@ -359,9 +358,6 @@ Public Class CALCPanelVM
|
||||
Dim nVal As Integer? = GetVal(line, "TIME")
|
||||
nTotTime = (If(Not IsNothing(nVal), nVal.Value, 0))
|
||||
ProcessResultList.Add(ProcessResult.CreateTimeResult(cutId, nTotTime))
|
||||
'If Bar.nBarType = ProjectType.PROJ AndAlso Not IsNothing(currBTLPart) Then
|
||||
' EgtSetInfo(currBTLPart.nPartId, If(Bar.nBarType = ProjectType.PROJ, ITG_PROJ_TIME, ITG_PROD_TIME), nTotTime, True)
|
||||
'End If
|
||||
ElseIf Not String.IsNullOrWhiteSpace(line) AndAlso line <> "---" Then
|
||||
sMsg = line
|
||||
End If
|
||||
@@ -806,10 +802,6 @@ Public Class CALCPanelVM
|
||||
(Map.refMainMenuVM.SelPage = Pages.ONLYPRODPAGE AndAlso (IsNothing(ProjectManagerVM.CurrProj) OrElse IsNothing(Map.refProjectVM.BTLStructureVM)) AndAlso (IsNothing(ProjectManagerVM.CurrProd) OrElse IsNothing(Map.refProjectVM.MachGroupPanelVM))) Then Return
|
||||
' se modalita' assemblato
|
||||
Configuration.AssembledMode(Map.refShowBeamPanelVM.ShowBuilding_IsChecked)
|
||||
'If Map.refShowBeamPanelVM.ShowBuilding_IsChecked AndAlso Map.refShowBeamPanelVM.bShowAll Then
|
||||
' ' devo smontarlo prima di calcolare le travi, altrimenti non trova i pezzi
|
||||
' Map.refProjectVM.BTLStructureVM.ShowBuilding(False, False)
|
||||
'End If
|
||||
Dim BarList() As EgtBEAMWALL.Core.Bar = Nothing
|
||||
Dim ProjType As BWType
|
||||
If Map.refMainMenuVM.SelPage = Pages.VIEW Then
|
||||
@@ -929,11 +921,6 @@ Public Class CALCPanelVM
|
||||
End If
|
||||
Next
|
||||
ElseIf Map.refProjectVM.BTLStructureVM.SelBTLPartsCnt > 1 Then
|
||||
'For Each SelPart In Map.refProjectVM.BTLStructureVM.SelBTLPartList
|
||||
' If Not IsNothing(SelPart) AndAlso SelPart.nGlobalState <> CalcStates.NOTCALCULATED Then
|
||||
' SelPart.ResetCalcTotalPart()
|
||||
' End If
|
||||
'Next
|
||||
Else
|
||||
Dim SelPart As BTLPartVM = Map.refProjectVM.BTLStructureVM.SelBTLPart
|
||||
If IsNothing(SelPart) Then Return
|
||||
|
||||
@@ -231,8 +231,4 @@ Public Class Parameters
|
||||
If IsCheckBox Then m_BTLParamM.SetType(BTLParamType.CHECKBOX)
|
||||
End Sub
|
||||
|
||||
'Shared Operator =(ByVal S1 As Parameters, ByVal S2 As BTLParam) As Boolean
|
||||
' Return (S1.m_dH <> S2.m_dH OrElse S1.m_dW <> S2.m_dW)
|
||||
'End Operator
|
||||
|
||||
End Class
|
||||
@@ -79,14 +79,5 @@
|
||||
</TabItem>
|
||||
|
||||
</TabControl>
|
||||
|
||||
<!--<Button Command="{Binding SaveCommand}"
|
||||
ToolTip="{Binding SaveToolTip}"
|
||||
Grid.Row="1"
|
||||
Grid.Column="1"
|
||||
Style="{StaticResource OptionPanel_Button}">
|
||||
<Image Source="/Resources/ProjectManager/Save.png" Stretch="Uniform"/>
|
||||
</Button>-->
|
||||
|
||||
</Grid>
|
||||
</DockPanel>
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user