ESRI.ArcGIS.ADF.Web
ToGraphicsLayer(DataTable,Color,Color) Method
See Also 
ESRI.ArcGIS.ADF.Web Namespace > Converter Class > ToGraphicsLayer Method : ToGraphicsLayer(DataTable,Color,Color) Method




dt
DataTable to convert to a graphics layer.
symbolColor
Color with which to render the features in the graphics layer.
selectedSymbolColor
Color with which to render features that may be selected in the graphics layer.
Converts a System.Data.DataTable to an ESRI Web ADF graphics layer.

Syntax

Visual Basic (Declaration) 
Public Overloads Shared Function ToGraphicsLayer( _
   ByVal dt As DataTable, _
   ByVal symbolColor As Color, _
   ByVal selectedSymbolColor As Color _
) As GraphicsLayer
Visual Basic (Usage)Copy Code
Dim dt As DataTable
Dim symbolColor As Color
Dim selectedSymbolColor As Color
Dim value As GraphicsLayer
 
value = Converter.ToGraphicsLayer(dt, symbolColor, selectedSymbolColor)
C# 
public static GraphicsLayer ToGraphicsLayer( 
   DataTable dt,
   Color symbolColor,
   Color selectedSymbolColor
)

Parameters

dt
DataTable to convert to a graphics layer.
symbolColor
Color with which to render the features in the graphics layer.
selectedSymbolColor
Color with which to render features that may be selected in the graphics layer.

Return Value

ESRI Web ADF graphics layer.

Remarks

In order for conversion to a graphics layer to occur properly, the DataTable must contain a graphics column. If this column is of type ESRI.ArcGIS.ADF.Web.Geometry.Geometry and all rows contain the same geometry type (point, line or polygon), then the output layer will be a feature graphics layer (ESRI.ArcGIS.ADF.Web.Display.Graphics.FeatureGraphicsLayer). Otherwise, the output layer will be an element graphics layer (ESRI.ArcGIS.ADF.Web.Display.Graphics.ElementGraphicsLayer).

See Also

© 2010 All Rights Reserved.