ESRI.ArcGIS.ADF.IMS
NorthArrow Class
Members  Example  See Also 
ESRI.ArcGIS.ADF.IMS.Display.AcetateElement Namespace : NorthArrow Class




A specific type of AcetateElement that displays north arrows.

Object Model


Syntax

Visual Basic (Declaration) 
<SerializableAttribute()>
Public Class NorthArrow 
   Inherits AcetateElement
Visual Basic (Usage)Copy Code
Dim instance As NorthArrow
C# 
[SerializableAttribute()]
public class NorthArrow : AcetateElement 

Example

This example creates a NorthArrow, sets some of its properties, adds it to a new AcetateLayer and adds the AcetateLayer to the map.
Visual BasicCopy Code
' Create NorthArrow and set its properties

Dim arrowLocation As New Point(30, imgMap.Height.Value - 30)

Dim northArrow As New NorthArrow(AcetateUnits.Pixel)

northArrow.Location = arrowLocation

northArrow.AllowLabelOverlap = False

northArrow.Angle = 0

northArrow.Antialiasing = True

northArrow.OutlineColor = Drawing.Color.Red

northArrow.ShadowColor = Drawing.Color.WhiteSmoke

northArrow.Size = 24

northArrow.Style = NorthArrowStyle.Style4

northArrow.Transparency = 30



' Add NorthArrow to acetate layer and add to map

Dim acetateLayer As New AcetateLayer("mapGraphics")

acetateLayer.AcetateElements.Add(northArrow)



mapView.Layers.Add(acetateLayer)

C#Copy Code
// Create NorthArrow and set its properties 

Point arrowLocation = new Point(30, imgMap.Height.Value - 30); 

NorthArrow northArrow = new NorthArrow(AcetateUnits.Pixel); 

northArrow.Location = arrowLocation; 

northArrow.AllowLabelOverlap = False; 

northArrow.Angle = 0; 

northArrow.Antialiasing = True; 

northArrow.OutlineColor = Drawing.Color.Red; 

northArrow.ShadowColor = Drawing.Color.WhiteSmoke; 

northArrow.Size = 24; 

northArrow.Style = NorthArrowStyle.Style4; 

northArrow.Transparency = 30; 

  

// Add NorthArrow to acetate layer and add to map 

AcetateLayer acetateLayer = new AcetateLayer("mapGraphics"); 

acetateLayer.AcetateElements.Add(northArrow); 

  

mapView.Layers.Add(acetateLayer); 

    

Remarks

Some properties of NorthArrow are ignored by ArcMap Server image services. See individual properties for details.

Inheritance Hierarchy

System.Object
   ESRI.ArcGIS.ADF.IMS.Display.AcetateElement.AcetateElement
      ESRI.ArcGIS.ADF.IMS.Display.AcetateElement.NorthArrow

See Also

© 2010 All Rights Reserved.