Dundas Chart for ASP.NET
Add(MapAreaShape,String,Single[]) Method
See Also  Send comments on this topic.
Dundas.Charting.WebControl Namespace > MapAreasCollection Class > Add Method : Add(MapAreaShape,String,Single[]) Method


shape
Area shape.
Area shape.
href
Jump URL.
Jump URL.
coord
Array of coordinates. For a description see the Remarks section below.
Array of coordinates

Appends a custom MapArea object to the end of the MapAreasCollection. Takes a shape, hyperlink and coordinates as parameters.


Add new map area item into the collection.

Syntax

Visual Basic (Declaration)  
Public Overloads Function Add( _
   ByVal shape As MapAreaShape, _
   ByVal href As String, _
   ByVal coord() As Single _
) As Integer
Visual Basic (Usage) Copy Code
Dim instance As MapAreasCollection
Dim shape As MapAreaShape
Dim href As String
Dim coord() As Single
Dim value As Integer
 
value = instance.Add(shape, href, coord)
C#  
public int Add( 
   MapAreaShape shape,
   string href,
   float[] coord
)

Parameters

shape
Area shape.
Area shape.
href
Jump URL.
Jump URL.
coord
Array of coordinates. For a description see the Remarks section below.
Array of coordinates

Return Value

An integer that represents the index where the item was inserted into the collection (0-based).


Index of the newly added item.

Remarks

The coord array parameter determines the coordinates of the map area shape, and is dependent on the shape being used:

  • Circle. Three coordinates must be provided: "x1,y1,r". "x1" and "y1" determine the center of the circle, and "r" is the radius of the circle.
  • Rectangle. Four coordinates must be provided: "x1,y1,x2,y2". "x1,y1" are the coordinates of the upper-left corner of the rectangle, and "x2,y2" are the coordinates of the lower-right corner of the rectangle.
  • Polygon. Two or more x,y pairs must be provided: "x1,y1,x2,y2...xn,yn".  Each x,y pair determines the coordinates of one vertex of the polygon.

Requirements

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family

See Also

Copyright © 2001 - 2009 Dundas Data Visualization, Inc. and others.