Message 1 of 5
Not applicable
01-20-2015
01:28 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I am running into something, and I can't seem to figure it out. I have a subroutine to change the layer of an attribute, but it does not seem to work, and I can't find much on it online, so here i am! I will do my best to format it here, as my insert code button is not showing up in IE 11 or chrome... Private Sub ToZeroLayer(acadAttribute As String) Dim AttRef As AcadAttributeReference Dim Block As Object For Each Block In ThisDrawing.PaperSpace If Block.EntityName = "AcDbBlockReference" Then If Block.HasAttributes Then Array1 = Block.GetAttributes For i = LBound(Array1) To UBound(Array1) If (Array1(i).EntityName) = acadAttribute Then Set AttRef = (Array1(i)) AttRef.Layer = "0" End If Next End If End If Next End Sub It runs through the code without error, but it appears to do nothing.... Any help would be much appreciated! --Thanks as always!
Solved! Go to Solution.