<?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: code sample for splitting a line feature into two lines at a specified point. in ArcObjects SDK Questions</title>
    <link>https://community.esri.com/t5/arcobjects-sdk-questions/code-sample-for-splitting-a-line-feature-into-two/m-p/186033#M4843</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;It's a little old (and not in C#), but here's an &lt;/SPAN&gt;&lt;A href="http://edndoc.esri.com/arcobjects/9.0/componenthelp/esrigeometry/IPolycurve2_SplitAtPoints_Example.htm"&gt;example&lt;/A&gt;&lt;SPAN&gt; of splitting a line with points&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 07 May 2012 20:49:50 GMT</pubDate>
    <dc:creator>KenBuja</dc:creator>
    <dc:date>2012-05-07T20:49:50Z</dc:date>
    <item>
      <title>code sample for splitting a line feature into two lines at a specified point.</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/code-sample-for-splitting-a-line-feature-into-two/m-p/186032#M4842</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi All,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Could you point me to any C# code samples for splitting a polyline (IPolyline) into two at a specified point (with an IPoint reference)?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks in advance!&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;George S.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 May 2012 19:20:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/code-sample-for-splitting-a-line-feature-into-two/m-p/186032#M4842</guid>
      <dc:creator>GeorgeShi</dc:creator>
      <dc:date>2012-05-07T19:20:08Z</dc:date>
    </item>
    <item>
      <title>Re: code sample for splitting a line feature into two lines at a specified point.</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/code-sample-for-splitting-a-line-feature-into-two/m-p/186033#M4843</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;It's a little old (and not in C#), but here's an &lt;/SPAN&gt;&lt;A href="http://edndoc.esri.com/arcobjects/9.0/componenthelp/esrigeometry/IPolycurve2_SplitAtPoints_Example.htm"&gt;example&lt;/A&gt;&lt;SPAN&gt; of splitting a line with points&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 May 2012 20:49:50 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/code-sample-for-splitting-a-line-feature-into-two/m-p/186033#M4843</guid>
      <dc:creator>KenBuja</dc:creator>
      <dc:date>2012-05-07T20:49:50Z</dc:date>
    </item>
    <item>
      <title>Re: code sample for splitting a line feature into two lines at a specified point.</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/code-sample-for-splitting-a-line-feature-into-two/m-p/186034#M4844</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;For a simple line and point you can just use &lt;/SPAN&gt;&lt;A href="http://help.arcgis.com/en/sdk/10.0/arcobjects_net/componenthelp/index.html#/SplitWithUpdate_Method/0025000002zt000000/" rel="nofollow noopener noreferrer" target="_blank"&gt;IFeatureEdit2.SplitWithUpdate&lt;/A&gt;&lt;SPAN&gt; to split the line and update the attributes.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;IFeatureEdit2 featureEdit = lineFeature as IFeatureEdit2;
featureEdit.SplitWithUpdate(splitPoint);&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Alternatively you can keep the returned ISet to do something useful, like keep all the lines selected in this example.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;IFeatureEdit2 featureEdit = lineFeature as IFeatureEdit2;
//select features after split
featSelection.Add(lineFeature);
ISet newSet = featureEdit.SplitWithUpdate(splitPoint);
newSet.Reset();
IFeature newFeat = newSet.Next() as IFeature;
featSelection.Add(newFeat);&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 09:25:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/code-sample-for-splitting-a-line-feature-into-two/m-p/186034#M4844</guid>
      <dc:creator>Anonymous User</dc:creator>
      <dc:date>2021-12-11T09:25:24Z</dc:date>
    </item>
    <item>
      <title>Re: code sample for splitting a line feature into two lines at a specified point.</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/code-sample-for-splitting-a-line-feature-into-two/m-p/186035#M4845</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;thank you both!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 08 May 2012 12:24:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/code-sample-for-splitting-a-line-feature-into-two/m-p/186035#M4845</guid>
      <dc:creator>GeorgeShi</dc:creator>
      <dc:date>2012-05-08T12:24:02Z</dc:date>
    </item>
  </channel>
</rss>

