How to set vertical unit on the feature class

237
0
06-15-2018 02:51 PM
SuzanChau
New Contributor II

I have created a PolylineZ feature class, but I don't know how to set the Z unit.

I added this PolylineZ feature class to my map, and when I look at the layer's properties, the source has "vertical units" of "foot_us."  How do I set this attribute when I create the feature class?


I had tried setting the layer's Z unit programmatically when I create the layer from this feature class, but it didn't seem to do anything.  Here's the code I have:

var layerProps = newLayer.GetDefinition().Layer3DProperties;
if (layerProps != null)
{

   Unit verticalUnit = ...// retrieve the Z unit (will be feet)
   if (verticalUnit != null)
   {
       layerProps.VerticalUnit = verticalUnit;
       newLayer.GetDefinition().Layer3DProperties = layerProps;
   }
}

0 Kudos
0 Replies