FindAttribute Method (Component Object)

Scope: Schematic editor

Object: Component Object

Prerequisites: None

Searches all component attributes for one matching Name.

Usage

Component.FindAttribute(ByVal AttributeString As String) As IVdAttr

Arguments

AttributeString

This is the attribute name for which the search is executed.

Return Values

As IVdAttr. The Attribute Object.

Description

This method only finds attributes attached to the component. It does not find attributes that are only on the underlying symbol.

Examples

This example locates an attribute named MODEL.

Set Attr = Comp.FindAttribute("MODEL") 
If Attr Is Nothing Then 
    MsgBox "No MODEL atribute found" 
Else 
    MsgBox "MODEL=" & Attr.Value 
End If