<?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: Network flow trace with measures / distance in ArcObjects SDK Questions</title>
    <link>https://community.esri.com/t5/arcobjects-sdk-questions/network-flow-trace-with-measures-distance/m-p/614290#M16490</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Duncan,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks for the response. This IMSegmentation3&amp;nbsp; is almost fine, but... . If the trace result, say upstream, consist of several patsh that split (say in a form of Y letter) then the measures would go up one branch, (say up to upper left left point of Y letter). Then M values would continue from the middle of Y letter up to the right upper point. The more splits there are the less consistent/reliable M values become. In general this would work OK only for a single path without splits. Correct me if im wrong please !&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Szymon&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 15 Jun 2012 10:42:58 GMT</pubDate>
    <dc:creator>SzymonPiskula</dc:creator>
    <dc:date>2012-06-15T10:42:58Z</dc:date>
    <item>
      <title>Network flow trace with measures / distance</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/network-flow-trace-with-measures-distance/m-p/614288#M16488</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I wrote a tool that finds upstream and downstream trace in a river network from a start point X. This is based on a network flag for the point X. The network has defined flow direction/sinks. Now there is a requirement to find the distance of objects laying along the network (trace result in particular) to the point X. Is it possible for the network solver to add M Values to the resulting geometries? For example it would be enough if all the M Values would indicate how far a given FromPoint or ToPoint of the returned edge is from the end (last sink) of the whole 'branch'&amp;nbsp; of the river.&amp;nbsp; I''ve programmatically added&amp;nbsp; weights to the solver:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;
INetSchema netSchema = m_geometricNetwork.Network as INetSchema;
INetSolverWeightsGEN netSolverWeights = m_traceFlowSolver as INetSolverWeightsGEN;

INetWeight netWeight = netSchema.get_WeightByName("Distance");
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
netSolverWeights.FromToEdgeFilterWeight = netWeight;
netSolverWeights.ToFromEdgeFilterWeight = netWeight;
&lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;but the results have no measures.&amp;nbsp; Any suggestions?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Szymon&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 14 Jun 2012 08:40:22 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/network-flow-trace-with-measures-distance/m-p/614288#M16488</guid>
      <dc:creator>SzymonPiskula</dc:creator>
      <dc:date>2012-06-14T08:40:22Z</dc:date>
    </item>
    <item>
      <title>Re: Network flow trace with measures / distance</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/network-flow-trace-with-measures-distance/m-p/614289#M16489</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Szymon,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;It's been a long time time I've programmed a geometric network so I may be wrong here but I don't think you can mix M values with a geometric network, thats a linear referencing thing?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If your trace is returning a valid solution you can then enumerate the results using the Interface IEnumNetEID and build a polyline. You could then use the IMSegmentation3 Interface (once you made the polyline MAware) to calibrate M values to it. Then using the QueryPointAndDistance on the IPolyline interface you could "snap" your points to your measured trace polyline.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Duncan&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 Jun 2012 08:22:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/network-flow-trace-with-measures-distance/m-p/614289#M16489</guid>
      <dc:creator>DuncanHornby</dc:creator>
      <dc:date>2012-06-15T08:22:34Z</dc:date>
    </item>
    <item>
      <title>Re: Network flow trace with measures / distance</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/network-flow-trace-with-measures-distance/m-p/614290#M16490</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Duncan,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks for the response. This IMSegmentation3&amp;nbsp; is almost fine, but... . If the trace result, say upstream, consist of several patsh that split (say in a form of Y letter) then the measures would go up one branch, (say up to upper left left point of Y letter). Then M values would continue from the middle of Y letter up to the right upper point. The more splits there are the less consistent/reliable M values become. In general this would work OK only for a single path without splits. Correct me if im wrong please !&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Szymon&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 15 Jun 2012 10:42:58 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/network-flow-trace-with-measures-distance/m-p/614290#M16490</guid>
      <dc:creator>SzymonPiskula</dc:creator>
      <dc:date>2012-06-15T10:42:58Z</dc:date>
    </item>
  </channel>
</rss>

