<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://communities.bentley.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>VBA - accessing linkages</title><link>https://communities.bentley.com/products/geospatial/desktop/f/bentley-map-forum/68529/vba---accessing-linkages</link><description>Hi, 
 I&amp;#39;ve got a problem accessing by VBA user attributes stored in Linkages in a dgn file. 
 Could somebody please have a look on below code and advice. The TransferBlock procedure for sure works fine because I tried it in different macro which shows</description><dc:language>en-US</dc:language><generator>Telligent Community 12</generator><item><title>Re: VBA - accessing linkages</title><link>https://communities.bentley.com/thread/177817?ContentTypeID=1</link><pubDate>Wed, 13 Jul 2011 20:32:13 GMT</pubDate><guid isPermaLink="false">6dad98f5-dbc9-4c4d-a9ba-e9da8dc6aa8e:00729867-2a45-4759-a2db-b4582a12bcbc</guid><dc:creator>Jeff Bielefeld</dc:creator><description>&lt;p&gt;...okay very good, thank you for that update. I would also recommend that&amp;nbsp;before calling the .GetSubFeature(0) method, your code performs a check to ensure that the .SubFeatureCount property has a value greater than 0.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>Re: VBA - accessing linkages</title><link>https://communities.bentley.com/thread/177797?ContentTypeID=1</link><pubDate>Wed, 13 Jul 2011 19:00:34 GMT</pubDate><guid isPermaLink="false">6dad98f5-dbc9-4c4d-a9ba-e9da8dc6aa8e:b5c075e9-f39c-4e65-9b8e-3cf6290b472e</guid><dc:creator>kolkiewicza</dc:creator><description>&lt;p&gt;I have managed to make in run. I just added to the code those lines:&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Set Subfeature = oFeature.GetSubFeature(0)&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Set oElement = Subfeature.Geometry&lt;/p&gt;
&lt;p&gt;Thanks for the suggestion.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>Re: VBA - accessing linkages</title><link>https://communities.bentley.com/thread/177733?ContentTypeID=1</link><pubDate>Wed, 13 Jul 2011 11:27:17 GMT</pubDate><guid isPermaLink="false">6dad98f5-dbc9-4c4d-a9ba-e9da8dc6aa8e:193bc22d-2ba4-4c10-91ca-8f7594296a7b</guid><dc:creator>kolkiewicza</dc:creator><description>&lt;p&gt;Thanks Jeff, &lt;/p&gt;
&lt;p&gt;Please find the macro attached. It works on selected elements. &lt;/p&gt;
&lt;p&gt;BTW, I use Bentley PowerMap v8i and if I check element information I can see linkages and the one I&amp;#39;m interested in is Type 0x379.&lt;/p&gt;
&lt;p&gt;I&amp;#39;m going to try calling the subfeature method.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description><enclosure url="https://communities.bentley.com/cfs-file/__key/telligent-evolution-components-attachments/00-5924-01-00-00-17-77-33/idgl_5F00_read.mvba" length="18432" type="application/octet-stream" /></item><item><title>Re: VBA - accessing linkages</title><link>https://communities.bentley.com/thread/177639?ContentTypeID=1</link><pubDate>Tue, 12 Jul 2011 20:31:10 GMT</pubDate><guid isPermaLink="false">6dad98f5-dbc9-4c4d-a9ba-e9da8dc6aa8e:e415dbe7-dca1-4f3d-9d1b-910d26e80295</guid><dc:creator>Jeff Bielefeld</dc:creator><description>&lt;p&gt;After&amp;nbsp;looking at the provided budynki_shape2.dgn file, it is at first not apparent which elements contain your user attribute data. Using pure MicroStation scanning and elements (e.g. no XFT constructs) it seemed that .GetUserAttributeData(lIDGL) always returned a zero sized array. Can you please provide the .mvba that you previously referred to (e.g.&amp;nbsp;tried it in different macro which shows the id of selected element) for review.&lt;/p&gt;
&lt;p&gt;Also please be aware that your Budynki feature class is a collection so while the business properties are on the root feature, the geometries will be contained in sub-features so you will need to check the .SubFeatureCount property of the root feature, then call the .GetSubFeature(index) method to get the sub-feature instance.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>Re: VBA - accessing linkages</title><link>https://communities.bentley.com/thread/177627?ContentTypeID=1</link><pubDate>Tue, 12 Jul 2011 19:08:33 GMT</pubDate><guid isPermaLink="false">6dad98f5-dbc9-4c4d-a9ba-e9da8dc6aa8e:1c2c2d89-b677-4c05-8998-4a2b0be79c63</guid><dc:creator>kolkiewicza</dc:creator><description>&lt;p&gt;The mvba attached&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description><enclosure url="https://communities.bentley.com/cfs-file/__key/telligent-evolution-components-attachments/00-5924-01-00-00-17-76-27/text2xfm.mvba" length="64000" type="application/octet-stream" /></item></channel></rss>