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

Here's a small iLogic Rule that will change the color of Faces as you select them.

 

SyntaxEditor Code Snippet

Public Sub Main()

Dim oFace As Face

'Copy the asset from the library to this document
Dim localAsset As Asset = ThisApplication.AssetLibraries.Item("Autodesk Appearance Library").AppearanceAssets.Item("Bamboo").CopyTo(ThisDoc.Document, True)

'Keep Selecting Faces, Hit Esc to finish
Do
    oFace = ThisApplication.CommandManager.Pick(SelectionFilterEnum.kAllPlanarEntities, "Pick a feature")
    If Not oFace Is Nothing Then 
        oFace.Appearance = localAsset
    End If
Loop While Not oFace Is Nothing

End Sub