Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations cowski on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Tag - name of an attribute in a block (VBA)

Status
Not open for further replies.

bdrouck

Computer
Joined
Nov 27, 2002
Messages
2
Location
BE
Does anyone know how to get the tag-information of the attrubutes of a block in visual basic?
I have made a blockreference, and i can get the attribute-values, but not the name of the attribute (tag)
 
Dear bdrouck,
1. You should get a block-reference object using object selection methods or any other method.
2. Attributes contained in a block reference can be accessed by the "GetAttributes" method as a variant.
Dim VA As Variant
VA=BlockRefObj.GetAttributes
3. Now the VA is an array including the attributes information in each element. To determining the number of elements (no. of attributes), you can use the functions LBOUND and UBOUND. The tag for each attribute is accessible using the "TagString" property.
VA(2).TagString

:)
Farzad
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top