<?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 Locator problem in ArcObjects SDK Questions</title>
    <link>https://community.esri.com/t5/arcobjects-sdk-questions/locator-problem/m-p/263013#M6752</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I have program that takes a Shapefile centerline layer and will break FROM/TO data ranges of the line segments into "100 block" ranges.&amp;nbsp; The program geocodes the start of each 100 block range as it runs.&amp;nbsp; When I run the program with one shapefile which contains around 5500 line segments and produces 20,000 block ranges, things run fine.&amp;nbsp; I have another shapefile that only contains about 1500 line segments and I am having problems with it.&amp;nbsp; At various points during the program run, it generates an exception error.&amp;nbsp; The address that causes the exception is not consistent.&amp;nbsp; The first time, it might be 4200 MAIN ST and the next time 5000 MAIN ST.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If I use the Locator within ArcMap, it consistently finds the addresses.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The exception is listed below and is taking place on the last line of this code that I have included (ws is an active IWorkspace that is being passed to the processing function):&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Exception:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;System.Runtime.InteropServices.COMException was unhandled&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; Message=Error HRESULT E_FAIL has been returned from a call to a COM component.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; Source=ESRI.ArcGIS.Location&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; ErrorCode=-2147467259&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Code:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;if (locatorManager == null)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[INDENT][INDENT]locatorManager = new LocatorManagerClass();&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;locatorWorkspace = (ILocatorWorkspace)locatorManager.GetLocatorWorkspace(ws);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;if (locatorWorkspace == null)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[INDENT]return;[/INDENT][/INDENT][/INDENT]}&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;IPropertySet addressProperties = new PropertySetClass();&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;addressProperties.SetProperty("Street", Addr);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;addressProperties.SetProperty("City", City);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;IAddressGeocoding addressGeocoding = (IAddressGeocoding)locatorWorkspace.GetLocator(LocatorName);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;if (addressGeocoding == null)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[INDENT]return;[/INDENT]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;IPropertySet matchProperties = addressGeocoding.MatchAddress(addressProperties);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Any ideas?&amp;nbsp; Thanks.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 30 Apr 2011 15:23:56 GMT</pubDate>
    <dc:creator>MarkParr</dc:creator>
    <dc:date>2011-04-30T15:23:56Z</dc:date>
    <item>
      <title>Locator problem</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/locator-problem/m-p/263013#M6752</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I have program that takes a Shapefile centerline layer and will break FROM/TO data ranges of the line segments into "100 block" ranges.&amp;nbsp; The program geocodes the start of each 100 block range as it runs.&amp;nbsp; When I run the program with one shapefile which contains around 5500 line segments and produces 20,000 block ranges, things run fine.&amp;nbsp; I have another shapefile that only contains about 1500 line segments and I am having problems with it.&amp;nbsp; At various points during the program run, it generates an exception error.&amp;nbsp; The address that causes the exception is not consistent.&amp;nbsp; The first time, it might be 4200 MAIN ST and the next time 5000 MAIN ST.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If I use the Locator within ArcMap, it consistently finds the addresses.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The exception is listed below and is taking place on the last line of this code that I have included (ws is an active IWorkspace that is being passed to the processing function):&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Exception:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;System.Runtime.InteropServices.COMException was unhandled&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; Message=Error HRESULT E_FAIL has been returned from a call to a COM component.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; Source=ESRI.ArcGIS.Location&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp; ErrorCode=-2147467259&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Code:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;if (locatorManager == null)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[INDENT][INDENT]locatorManager = new LocatorManagerClass();&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;locatorWorkspace = (ILocatorWorkspace)locatorManager.GetLocatorWorkspace(ws);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;if (locatorWorkspace == null)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[INDENT]return;[/INDENT][/INDENT][/INDENT]}&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;IPropertySet addressProperties = new PropertySetClass();&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;addressProperties.SetProperty("Street", Addr);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;addressProperties.SetProperty("City", City);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;IAddressGeocoding addressGeocoding = (IAddressGeocoding)locatorWorkspace.GetLocator(LocatorName);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;if (addressGeocoding == null)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[INDENT]return;[/INDENT]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;IPropertySet matchProperties = addressGeocoding.MatchAddress(addressProperties);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Any ideas?&amp;nbsp; Thanks.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 30 Apr 2011 15:23:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/locator-problem/m-p/263013#M6752</guid>
      <dc:creator>MarkParr</dc:creator>
      <dc:date>2011-04-30T15:23:56Z</dc:date>
    </item>
    <item>
      <title>Re: Locator problem</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/locator-problem/m-p/263014#M6753</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Found the problem.&amp;nbsp; The program had introduced some bad block ranges to be searching and the exception was due to those addresses not existing afterall.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 01 May 2011 22:38:11 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/locator-problem/m-p/263014#M6753</guid>
      <dc:creator>MarkParr</dc:creator>
      <dc:date>2011-05-01T22:38:11Z</dc:date>
    </item>
  </channel>
</rss>

