Announcements
Attention for Customers without Multi-Factor Authentication or Single Sign-On - OTP Verification rolls out April 2025. Read all about it here.

Hi @Alexrose1942 . Please try this code. You need to write down your keywords in line 3 (example: {"Ground", "abc", "qwert"}).

Dim oDDoc As DrawingDocument = TryCast(ThisDoc.Document, DrawingDocument)
If oDDoc Is Nothing Then Exit Sub
Dim sList() As String = {"Ground"}
For Each oSheet As Sheet In oDDoc.Sheets
	For Each oView As DrawingView In oSheet.DrawingViews 
		Dim oRefDoc As Document = oView.ReferencedDocumentDescriptor.ReferencedDocument
		For Each oPlane As WorkPlane In oRefDoc.ComponentDefinition.WorkPlanes
			For i As Integer = 0 To sList.Length - 1
				If Not oPlane.Name.Contains(sList(i)) Then Continue For
				Try : oView.SetIncludeStatus(oPlane, True) : Catch : End Try
			Next i
		Next
	Next
Next

 

Andrii Humeniuk - CAD Coordinator, Autodesk Certified Instructor

LinkedIn | My free Inventor Addin | My Repositories

Did you find this reply helpful ? If so please use the Accept as Solution/Like.

EESignature