<?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: Artifacts From INewLineFeedback in ArcObjects SDK Questions</title>
    <link>https://community.esri.com/t5/arcobjects-sdk-questions/artifacts-from-inewlinefeedback/m-p/366862#M9656</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Firstly, thank you. Your code helped.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The ITool.Refresh implementation was the key. Note that some ESRI samples using INewLineFeedback omit this implementation and are broken to a degree. e.g. SelectionCOMSample . Hence my lack of knowledge.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;It looks like you use VS2008, but I've posted the solution in VS2010 for anyone else who comes across this thread.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 10 Aug 2011 21:42:42 GMT</pubDate>
    <dc:creator>ChanceYohman1</dc:creator>
    <dc:date>2011-08-10T21:42:42Z</dc:date>
    <item>
      <title>Artifacts From INewLineFeedback</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/artifacts-from-inewlinefeedback/m-p/366860#M9654</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;1) Compile in Visual Studio 2010 (I can throw it together in vs08, if someone is interested.)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;2) Run.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;3) Enable My Extension from the Extensions menu item.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;4) From the Customize Menu accessed by right-clicking on the toolbar area, add the NewLineFeedback Tool from the NewLineFeedback category.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;5) Click on the tool.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;6) You'll notice a line that starts at (0,0) and follows the cursor around.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Previously if I zoomed to full extent, fixed zoom out, fixed zoom in, went to previous extent, went to next extent, or refreshed it left an artifact. I fixed that by using IActiveViewEvents in the extension with the AfterDraw event. See NewLineFeedbackExtension.cs for details. The issue I did not fix is if the user minimizes ArcMap, maximizes ArcMap, switches to a different app, or hovers on an item in the taskbar in Windows 7 to pop-up that particular item, then an artifact is left when ArcMap is refocused and the tool is moved around.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I've tried moving code all around, using IDisplayEvents, IDocumentEvents, and ITransformEvents. The artifact persists. I can get rid of it if I refresh (F5 or the tool). My guess is an old IScreenDisplay used by INewLineFeedback is left on the screen or the old INewLineFeedback object isn't released properly when I create a new one in AfterDraw. I've tried manually releasing the object too.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Any help would be appreciated. Thanks for your time.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Aug 2011 21:19:41 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/artifacts-from-inewlinefeedback/m-p/366860#M9654</guid>
      <dc:creator>ChanceYohman1</dc:creator>
      <dc:date>2011-08-09T21:19:41Z</dc:date>
    </item>
    <item>
      <title>Re: Artifacts From INewLineFeedback</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/artifacts-from-inewlinefeedback/m-p/366861#M9655</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I don't have time right now to run your code but you shouldn't need any events outside of the ITool implementation.&amp;nbsp; I'm attaching a sample sketch tool I created for a blog entry a few years back.&amp;nbsp; You may find something in the code that will help you solve your problem.&amp;nbsp; This tool uses a custom symbol rather than using the default symbol provided by the feedback object.&amp;nbsp; One thing to note is the symbol settings in the method that creates the custom symbol object.&amp;nbsp; There is also code in the ITool.Refresh implementation to refresh the feedback object.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 Aug 2011 13:13:52 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/artifacts-from-inewlinefeedback/m-p/366861#M9655</guid>
      <dc:creator>NeilClemmons</dc:creator>
      <dc:date>2011-08-10T13:13:52Z</dc:date>
    </item>
    <item>
      <title>Re: Artifacts From INewLineFeedback</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/artifacts-from-inewlinefeedback/m-p/366862#M9656</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Firstly, thank you. Your code helped.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The ITool.Refresh implementation was the key. Note that some ESRI samples using INewLineFeedback omit this implementation and are broken to a degree. e.g. SelectionCOMSample . Hence my lack of knowledge.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;It looks like you use VS2008, but I've posted the solution in VS2010 for anyone else who comes across this thread.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 Aug 2011 21:42:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/artifacts-from-inewlinefeedback/m-p/366862#M9656</guid>
      <dc:creator>ChanceYohman1</dc:creator>
      <dc:date>2011-08-10T21:42:42Z</dc:date>
    </item>
  </channel>
</rss>

