Code: Select all
_cadParams = New CADIterate
_cadParams.matrix = New CADMatrix
_cadParams.matrix.data(0, 0) = 1
_cadParams.matrix.data(1, 1) = 1
_cadParams.matrix.data(2, 2) = 1
_cadImage.Converter.AutoInsert = True
_cadImage.Converter.Iterate(New CADEntityProc(AddressOf Me.ReadCADEntitiesParamsToPDF), Nothing, _cadParams)
in "ReadCADEntitiesParamsToPDF" i'm using
Code: Select all
CADConst.DoScale2D((_cadParams))
Dim layer As CADLayer = CADConst.EntLayer(entity, _cadParams.insert)
If Not IsNothing(layer) AndAlso Not layer.Visible Then
Exit Sub
End If
Before doing this i want to be able to hide some layer/blocks and recalculate new extensions without hidden objects...
But when i get here
Dim layer As CADLayer = CADConst.EntLayer(entity, _cadParams.insert)
My layer that should be hidden by "HideLayers" procedure is still visible.
What is wrong ?

PS: also doing
Code: Select all
_cadImage.DrawMode = CADDrawMode.Black
_cadImage.BackgroundColor = Color.White
Code: Select all
Public Sub HideLayers(ByVal LayerList As String)
If LayerList <> "" Then
Dim Elenco() As String = LayerList.Split(";"c)
For Each Nome As String In Elenco
If Nome.Trim <> "" Then
Dim Lay As CADLayer = _cadImage.Converter.LayerByName(Nome)
Lay.Visibility = False
Lay.Visible = False
Lay.Loaded(_cadImage.Converter)
_cadImage.Converter.Loads(Lay)
End If
Next
End If
_cadImage.GetExtents()
End Sub