AnsweredAssumed Answered

DXD Linked Output (AppendOutput) in Hierachical Designs

Question asked by michael.weber on Feb 14, 2018
Latest reply on Aug 12, 2018 by michael.weber

Hi All,

 

I "crashed", when trying add Hyperlinked Output with hierachical nets/comps, etc.

AppendOutput "Constraints", "vdraw: Error 0: " & SchemaPath & " net " & NetName & ": have no NetClass"

works well for Topblock. But, when adding hierarical Links, it does not work.

For Components i.e. I get following:

View help for this messageStatus 14: Visit message location01_Block\07_SwitchingPowerSupply com SwitchingPowerS4\$1I2335 Part C609 Status=Versuch/Muster

 

This link will not work.

 

oComp.GetName(FULL_PATH_FROM_BLOCK) get "SwitchingPowerS4\$1I2335" for the component.

Did someone will have a good idea to get working it? Or is it impossible to getting links working in hierachical Designs?

 

BR Michi

 

Set dxapp = GetObject (,"ViewDraw.Application")

Set dxView = dxapp.Activeview

 

design_name = dxapp.GetProjectData.GetiCDBDesignRootBlock(dxapp.GetActiveDesign())

Set new_dictPaths = CreateObject("Scripting.Dictionary")

new_dictPaths.Add "", design_name

For Each objComp In dxapp.DesignComponents("", design_name, "-1", "STD", True)

    If objComp.SymbolBlock.SymbolType = VDB_COMPOSITE Then

        sPath = objComp.GetName(0)

        sSchematic = objComp.SymbolBlock.GetName(2)

        sSheet = objComp.SymbolBlock.SheetNum

        new_dictPaths.Add sPath, sSchematic

    End If

Next  

sLsheetN = 1

  

For Each sPath In new_dictPaths.Keys

 

    sSchematic = new_dictPaths(sPath)

    dxapp.StatusBarText = "Setting SAP Status invisible: " & sSchematic

  

    For Each sSheet In dxapp.SchematicSheetDocuments.GetAvailableSheets(sSchematic)

      

        dxapp.PushPath design_name, sPath, sSheet ' Uncomment this to push all sheets

        For Each oComp In ActiveView.Query(VDM_COMP, VD_ALL)

            If oComp.SymbolBlock.SymbolType = VDB_MODULE Then

                'dxapp.StatusBarText = "Setting " & oComp.RefDes & "..."

                For Each oCompAttr in oComp.Attributes

                    If oCompAttr.name = "Status" Then

                        oCompAttr.Visible = VDVALUEVISIBLE    'VDVALUEVISIBLE

                        If Len(oCompAttr.Value) > 0 Then      

                                    If (sPath = "") Then

                                    AppendOutput "SAP", "vdraw: Status 14: " & sSchematic & " com " & oComp.UID & " : Part " & oComp.RefDes & " Status=" & oCompAttr.Value  

                                Else

                                    AppendOutput "SAP", "vdraw: Status 14: " & design_name & "\" & sSchematic & " com " & oComp.GetName(FULL_PATH_FROM_BLOCK) & " : Part " & oComp.RefDes & " Status=" & oCompAttr.Value

                                End If

                        End If

                        Exit For

                    End If

                Next

            End If

        Next

        sLsheetN = sLsheetN + 1          

        'SchematicSheetDocuments.Close

    Next

Next

Outcomes