<?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 [C#] Distance Units of a Layer in ArcObjects SDK Questions</title>
    <link>https://community.esri.com/t5/arcobjects-sdk-questions/c-distance-units-of-a-layer/m-p/89515#M2358</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I am developing an ArcGIS desktop addin. I am attempting to get the distance units (ft, mm, km, etc.) from a layer in my .mxd and display it on a windows form. How can I do this? I can access the distance units of a map by using IMap.DistanceUnits, but I have had trouble accessing the distance units of an individual layer.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 07 Apr 2013 22:33:09 GMT</pubDate>
    <dc:creator>ConorBarber1</dc:creator>
    <dc:date>2013-04-07T22:33:09Z</dc:date>
    <item>
      <title>[C#] Distance Units of a Layer</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/c-distance-units-of-a-layer/m-p/89515#M2358</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I am developing an ArcGIS desktop addin. I am attempting to get the distance units (ft, mm, km, etc.) from a layer in my .mxd and display it on a windows form. How can I do this? I can access the distance units of a map by using IMap.DistanceUnits, but I have had trouble accessing the distance units of an individual layer.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 07 Apr 2013 22:33:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/c-distance-units-of-a-layer/m-p/89515#M2358</guid>
      <dc:creator>ConorBarber1</dc:creator>
      <dc:date>2013-04-07T22:33:09Z</dc:date>
    </item>
    <item>
      <title>Re: [C#] Distance Units of a Layer</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/c-distance-units-of-a-layer/m-p/89516#M2359</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Someone answered this for me on another forum. The solution they provided is to use IProjectedCoordinateSystem.CoordinateUnit. I was working with an ILayer, which uses ILayer.AreaOfInterest.SpatialReference. IProjectedCoordinateSystem inherits from SpatialReference, and can be accessed through casting:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt; ESRI.ArcGIS.Geometry.IProjectedCoordinateSystem lyrCoordSystem = (IProjectedCoordinateSystem)pLayer.AreaOfInterest.SpatialReference;&amp;nbsp; lblSpatialReference.Text = lyrCoordSystem.CoordinateUnit.Name;&amp;nbsp; &lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Apr 2013 02:57:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/c-distance-units-of-a-layer/m-p/89516#M2359</guid>
      <dc:creator>ConorBarber1</dc:creator>
      <dc:date>2013-04-08T02:57:06Z</dc:date>
    </item>
  </channel>
</rss>

