<?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 Rotation Renderer using Expression in ArcObjects SDK Questions</title>
    <link>https://community.esri.com/t5/arcobjects-sdk-questions/rotation-renderer-using-expression/m-p/182257#M4731</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I am trying to symbolize some points based on a field using an expression.&amp;nbsp; I am using the IRotationRenderer2 interface to do this as it has the capability to use an expression.&amp;nbsp; I have successfully symbolized these points without the expression just using a field value, using IRotationRenderer.&amp;nbsp; But I just can't get the expression to work.&amp;nbsp; Any suggestions?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here's the code I'm using:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;IRotationRenderer2 rotationRenderer = (IRotationRenderer2)pRender;
rotationRenderer.SetSymbolRotation3DExpressions("", "", "Direction + 180");
rotationRenderer.SymbolRotation3DRotationTypeZ = esriSymbolRotationType.esriRotateSymbolGeographic;&lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The data source is a File Geodatabase feature class, that has a "Direction" field of type double.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;When I run the code, the layer does not rotate at all.&amp;nbsp; When I open the rotation settings in ArcMap the expression is loaded correctly, and if I just close the dialog again from there (without changing a thing) it works fine.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I read in the help that I should use the Z rotation since this is a 2D feature class.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Any help would be appreciated.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;jeremy&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 22 Jun 2012 18:35:44 GMT</pubDate>
    <dc:creator>JeremyFontenault</dc:creator>
    <dc:date>2012-06-22T18:35:44Z</dc:date>
    <item>
      <title>Rotation Renderer using Expression</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/rotation-renderer-using-expression/m-p/182257#M4731</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I am trying to symbolize some points based on a field using an expression.&amp;nbsp; I am using the IRotationRenderer2 interface to do this as it has the capability to use an expression.&amp;nbsp; I have successfully symbolized these points without the expression just using a field value, using IRotationRenderer.&amp;nbsp; But I just can't get the expression to work.&amp;nbsp; Any suggestions?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Here's the code I'm using:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;IRotationRenderer2 rotationRenderer = (IRotationRenderer2)pRender;
rotationRenderer.SetSymbolRotation3DExpressions("", "", "Direction + 180");
rotationRenderer.SymbolRotation3DRotationTypeZ = esriSymbolRotationType.esriRotateSymbolGeographic;&lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The data source is a File Geodatabase feature class, that has a "Direction" field of type double.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;When I run the code, the layer does not rotate at all.&amp;nbsp; When I open the rotation settings in ArcMap the expression is loaded correctly, and if I just close the dialog again from there (without changing a thing) it works fine.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I read in the help that I should use the Z rotation since this is a 2D feature class.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Any help would be appreciated.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;jeremy&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 22 Jun 2012 18:35:44 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/rotation-renderer-using-expression/m-p/182257#M4731</guid>
      <dc:creator>JeremyFontenault</dc:creator>
      <dc:date>2012-06-22T18:35:44Z</dc:date>
    </item>
    <item>
      <title>Re: Rotation Renderer using Expression</title>
      <link>https://community.esri.com/t5/arcobjects-sdk-questions/rotation-renderer-using-expression/m-p/182258#M4732</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Jeremy&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;If its not too late, try adding the following line&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;pRotationRenderer.SetSymbolRotation3DFlags(esriSymbolRotation3DFlags.esriSymbolRotation3DNone, esriSymbolRotation3DFlags.esriSymbolRotation3DNone, esriSymbolRotation3DFlags.esriSymbolRotation3DUseExpressionZ);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;that is&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;IRotationRenderer2 rotationRenderer = (IRotationRenderer2)pRender;
rotationRenderer.SetSymbolRotation3DExpressions("", "", "Direction + 180");
pRotationRenderer.SetSymbolRotation3DFlags(esriSymbolRotation3DFlags.esriSymbolRotation3DNone, esriSymbolRotation3DFlags.esriSymbolRotation3DNone, esriSymbolRotation3DFlags.esriSymbolRotation3DUseExpressionZ);
rotationRenderer.SymbolRotation3DRotationTypeZ = esriSymbolRotationType.esriRotateSymbolGeographic;&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;I am trying to symbolize some points based on a field using an expression.&amp;nbsp; I am using the IRotationRenderer2 interface to do this as it has the capability to use an expression.&amp;nbsp; I have successfully symbolized these points without the expression just using a field value, using IRotationRenderer.&amp;nbsp; But I just can't get the expression to work.&amp;nbsp; Any suggestions?&lt;BR /&gt;&lt;BR /&gt;Here's the code I'm using:&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;IRotationRenderer2 rotationRenderer = (IRotationRenderer2)pRender;
rotationRenderer.SetSymbolRotation3DExpressions("", "", "Direction + 180");
rotationRenderer.SymbolRotation3DRotationTypeZ = esriSymbolRotationType.esriRotateSymbolGeographic;&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;The data source is a File Geodatabase feature class, that has a "Direction" field of type double.&lt;BR /&gt;&lt;BR /&gt;When I run the code, the layer does not rotate at all.&amp;nbsp; When I open the rotation settings in ArcMap the expression is loaded correctly, and if I just close the dialog again from there (without changing a thing) it works fine.&lt;BR /&gt;&lt;BR /&gt;I read in the help that I should use the Z rotation since this is a 2D feature class.&lt;BR /&gt;&lt;BR /&gt;Any help would be appreciated.&lt;BR /&gt;jeremy&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 09:18:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcobjects-sdk-questions/rotation-renderer-using-expression/m-p/182258#M4732</guid>
      <dc:creator>RobertDriessen</dc:creator>
      <dc:date>2021-12-11T09:18:10Z</dc:date>
    </item>
  </channel>
</rss>

