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

I really appreciate helping out. However, it's still not working. I attached the assembly and files.

 

Doing it exactly how you shown I get:

Error on Line 11 : 'oSubOccurrence1' is not declared. It may be inaccessible due to its protection level.

 

So if i try to declare it with the following code:

oCompDef = ThisDoc.Document.ComponentDefinition
oAssyOccurrences  = ThisDoc.Document.ComponentDefinition.Occurrences

iLogicVb.RunRule("DescriptionEditor")

Dim oSubOccurrence1 As ComponentOccurrence
Dim oOccurrence As ComponentOccurrence

For Each oOccurrence In oAssyOccurrences
    If oSubOccurrence1.DefinitionDocumentType = DocumentTypeEnum.kAssemblyDocumentObject Then
          iLogicVb.RunExternalRule("DescriptionEditor")
    End If
Next

i still get:

RunRule: Cannot find a rule with the name: "DescriptionEditor".

 

Did everything you said:

image.png

 

image.png