<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: &amp;quot;Highlight&amp;quot; polyline in block references in .NET Forum</title>
    <link>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158950#M17182</link>
    <description>&lt;P&gt;Visibility state is dynamic block's property. You said dynamic block would not be your desired solution, that is why I proposed TransientGraphics solution.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If Visibility State meets your need, it is just a simple task to design the block with a thicker polyline with desired highlight color being hidden in normal use; and turn the Visibility State on when highlight is needed. By code, you do not need to identify the "highlight polyline" that can be turned off/on, the code only needs to loop through all dynamic properties by property name, when found, change the property value accordingly. Of course user can also manually flip the Visibility state.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you only want the highlight shown during certain process (of your code), Transient graphics might be better choice, because you do not want user accidently turn on the undesired highlight and forgot to turn it off.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You might want to explain why/when/how you want part of a blockrefernce be highlighted. In the meanwhile, I might see if I have time to put together some code to demonstrate TransientGraphics for highlighting partial of BlockReference&lt;/P&gt;</description>
    <pubDate>Mon, 15 Mar 2021 22:17:50 GMT</pubDate>
    <dc:creator>norman.yuan</dc:creator>
    <dc:date>2021-03-15T22:17:50Z</dc:date>
    <item>
      <title>"Highlight" polyline in block references</title>
      <link>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158463#M17174</link>
      <description>&lt;P&gt;I don't think this is possible but I'll ask anyway.&lt;/P&gt;&lt;P&gt;By "highlighting" I mean changing the width of polylines within a block.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;At the moment I am doing this by setting the polylines lineweight set to "ByBlock" and changing the BlockReferences lineweight. This isn't ideal as I need to turn on&amp;nbsp;LWDISPLAY which thinkens all lines in the drawing that have lineweights.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is it possible to change the ConstantWidth property of polylines within specific BlockReferences?&lt;/P&gt;&lt;P&gt;I'm guessing that you can only modify the BlockTableRecord which would change the thicknesses of all BlockReferences under the&amp;nbsp;BlockTableRecord.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Mar 2021 18:52:29 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158463#M17174</guid>
      <dc:creator>SRSDS</dc:creator>
      <dc:date>2021-03-15T18:52:29Z</dc:date>
    </item>
    <item>
      <title>Re: "Highlight" polyline in block references</title>
      <link>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158477#M17175</link>
      <description>&lt;P&gt;You could probably do it with a dynamic block and visibility states&lt;/P&gt;</description>
      <pubDate>Mon, 15 Mar 2021 18:57:05 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158477#M17175</guid>
      <dc:creator>GeeHaa</dc:creator>
      <dc:date>2021-03-15T18:57:05Z</dc:date>
    </item>
    <item>
      <title>Re: "Highlight" polyline in block references</title>
      <link>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158513#M17176</link>
      <description>&lt;P&gt;Thanks for the super fast reply. Great idea, if it weren't for my situation I think.&lt;/P&gt;&lt;P&gt;I have many very complicated blocks using many geometric and dimensional constraints.&amp;nbsp;&lt;/P&gt;&lt;P&gt;I'd need to duplicate all the polylines, reconstrain them, then constrain them against the existing polylines.&lt;/P&gt;&lt;P&gt;Which would be hard.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Mar 2021 19:13:06 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158513#M17176</guid>
      <dc:creator>SRSDS</dc:creator>
      <dc:date>2021-03-15T19:13:06Z</dc:date>
    </item>
    <item>
      <title>Re: "Highlight" polyline in block references</title>
      <link>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158538#M17177</link>
      <description>&lt;P&gt;Sorry.. Copying and pasting isn't hard and doesn't remove constraints.&lt;/P&gt;&lt;P&gt;I'd just need to constrain points from the old to the new. Maybe that is the answer!&lt;/P&gt;</description>
      <pubDate>Mon, 15 Mar 2021 19:19:33 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158538#M17177</guid>
      <dc:creator>SRSDS</dc:creator>
      <dc:date>2021-03-15T19:19:33Z</dc:date>
    </item>
    <item>
      <title>Re: "Highlight" polyline in block references</title>
      <link>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158551#M17178</link>
      <description>&lt;P&gt;Well, in most cases "highlight" is used as temporary visual hint for CAD user. So, depending on when/how long you want the entity be highlighted, you can consider to use TransientGraphics to draw the polyline with certain global width on top the polyline seen in the block reference, and remove it for unhighlight. That is:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;1. identify the polyline in the blocktablerecord;&lt;/P&gt;
&lt;P&gt;2. clone the identified polyline;&lt;/P&gt;
&lt;P&gt;3. transform the cloned polyline with the blockreference's transform;&lt;/P&gt;
&lt;P&gt;4. use the cloned polyline as drawable to draw transient graphics;&lt;/P&gt;
&lt;P&gt;5. when its time to unhighlight, erase the transient graphics;&lt;/P&gt;
&lt;P&gt;6. dispose the cloned polyline.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Mar 2021 19:25:08 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158551#M17178</guid>
      <dc:creator>norman.yuan</dc:creator>
      <dc:date>2021-03-15T19:25:08Z</dc:date>
    </item>
    <item>
      <title>Re: "Highlight" polyline in block references</title>
      <link>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158723#M17179</link>
      <description>&lt;P&gt;Hi Norman.&lt;/P&gt;&lt;P&gt;After years I appear to know very little.&lt;/P&gt;&lt;P&gt;The block has visibility states. How do I identify visible polylines.&lt;/P&gt;&lt;P&gt;Sadly I don’t know where to go without asking for code examples of all your steps.&lt;/P&gt;</description>
      <pubDate>Mon, 15 Mar 2021 20:32:28 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158723#M17179</guid>
      <dc:creator>SRSDS</dc:creator>
      <dc:date>2021-03-15T20:32:28Z</dc:date>
    </item>
    <item>
      <title>Re: "Highlight" polyline in block references</title>
      <link>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158900#M17180</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/786488"&gt;@SRSDS&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Any Entity (and Polyline also) has property &lt;STRONG&gt;Visible&lt;/STRONG&gt;. If Polyline in this visibility state of BlockReference is invisible - so it's property Visible is false in correspondent BlockTableRecord.&lt;/P&gt;</description>
      <pubDate>Mon, 15 Mar 2021 21:55:32 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158900#M17180</guid>
      <dc:creator>Alexander.Rivilis</dc:creator>
      <dc:date>2021-03-15T21:55:32Z</dc:date>
    </item>
    <item>
      <title>Re: "Highlight" polyline in block references</title>
      <link>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158910#M17181</link>
      <description>&lt;P&gt;Other way is: &lt;A href="https://adndevblog.typepad.com/autocad/2012/05/accessing-visible-entities-in-a-dynamic-block.html" target="_blank"&gt;https://adndevblog.typepad.com/autocad/2012/05/accessing-visible-entities-in-a-dynamic-block.html&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Mar 2021 21:58:33 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158910#M17181</guid>
      <dc:creator>Alexander.Rivilis</dc:creator>
      <dc:date>2021-03-15T21:58:33Z</dc:date>
    </item>
    <item>
      <title>Re: "Highlight" polyline in block references</title>
      <link>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158950#M17182</link>
      <description>&lt;P&gt;Visibility state is dynamic block's property. You said dynamic block would not be your desired solution, that is why I proposed TransientGraphics solution.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If Visibility State meets your need, it is just a simple task to design the block with a thicker polyline with desired highlight color being hidden in normal use; and turn the Visibility State on when highlight is needed. By code, you do not need to identify the "highlight polyline" that can be turned off/on, the code only needs to loop through all dynamic properties by property name, when found, change the property value accordingly. Of course user can also manually flip the Visibility state.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you only want the highlight shown during certain process (of your code), Transient graphics might be better choice, because you do not want user accidently turn on the undesired highlight and forgot to turn it off.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You might want to explain why/when/how you want part of a blockrefernce be highlighted. In the meanwhile, I might see if I have time to put together some code to demonstrate TransientGraphics for highlighting partial of BlockReference&lt;/P&gt;</description>
      <pubDate>Mon, 15 Mar 2021 22:17:50 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10158950#M17182</guid>
      <dc:creator>norman.yuan</dc:creator>
      <dc:date>2021-03-15T22:17:50Z</dc:date>
    </item>
    <item>
      <title>Re: "Highlight" polyline in block references</title>
      <link>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10159166#M17183</link>
      <description>&lt;P&gt;OK, I went ahead to write some code for this. As usual, for better readability/presentation, I publish it in my blog here:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="https://drive-cad-with-code.blogspot.com/2021/03/highlight-entity-in-block.html" target="_self"&gt;https://drive-cad-with-code.blogspot.com/2021/03/highlight-entity-in-block.html&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;No sure whether it is you are looking for, but at least it is an idea to your request.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 16 Mar 2021 00:06:56 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10159166#M17183</guid>
      <dc:creator>norman.yuan</dc:creator>
      <dc:date>2021-03-16T00:06:56Z</dc:date>
    </item>
    <item>
      <title>Re: "Highlight" polyline in block references</title>
      <link>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10159208#M17184</link>
      <description>&lt;P&gt;Linetype and color I can handle.&amp;nbsp;&lt;SPAN style="font-family: inherit;"&gt;The line thickness is what I think stands out as a highlight.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;See attached. Is this possible?&lt;/P&gt;</description>
      <pubDate>Tue, 16 Mar 2021 00:26:02 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10159208#M17184</guid>
      <dc:creator>SRSDS</dc:creator>
      <dc:date>2021-03-16T00:26:02Z</dc:date>
    </item>
    <item>
      <title>Re: "Highlight" polyline in block references</title>
      <link>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10159219#M17185</link>
      <description>&lt;P&gt;Sorry.. It probably is.&lt;/P&gt;&lt;P&gt;Not thinking and time to go to sleep.&lt;/P&gt;&lt;P&gt;Thank you so much.&lt;/P&gt;</description>
      <pubDate>Tue, 16 Mar 2021 00:31:40 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10159219#M17185</guid>
      <dc:creator>SRSDS</dc:creator>
      <dc:date>2021-03-16T00:31:40Z</dc:date>
    </item>
    <item>
      <title>Re: "Highlight" polyline in block references</title>
      <link>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10171415#M17186</link>
      <description>&lt;P&gt;Norman,&lt;/P&gt;&lt;P&gt;I really need to learn C#. Just gotten around to implementing this.&lt;/P&gt;&lt;P&gt;I copied the code from your blog to&amp;nbsp;&lt;A href="https://converter.telerik.com/" target="_blank"&gt;https://converter.telerik.com/&lt;/A&gt;&amp;nbsp;and it doesn't like it.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any chance you could help me understand what the problem might be?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 19 Mar 2021 22:11:50 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10171415#M17186</guid>
      <dc:creator>SRSDS</dc:creator>
      <dc:date>2021-03-19T22:11:50Z</dc:date>
    </item>
    <item>
      <title>Re: "Highlight" polyline in block references</title>
      <link>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10171584#M17187</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/786488"&gt;@SRSDS&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;I updated my article with the same code of VB.NET version, which I also used Terelik's online converter, which could not recognize the IDisposable.Dispose() implementing: that is the only thing you need to manually fix it (you can see the code in my article).&lt;/P&gt;
&lt;P&gt;HTH.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 20 Mar 2021 00:51:33 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/quot-highlight-quot-polyline-in-block-references/m-p/10171584#M17187</guid>
      <dc:creator>norman.yuan</dc:creator>
      <dc:date>2021-03-20T00:51:33Z</dc:date>
    </item>
  </channel>
</rss>

