ESRI.ArcGIS.ADF.IMS
Draw(Envelope) Method
See Also  Example
ESRI.ArcGIS.ADF.IMS.Carto Namespace > View Class > Draw Method : Draw(Envelope) Method




newExtent
Extent at which the Map will be redrawn.
Redraws the map with the specified map Extent.

Syntax

Visual Basic (Declaration) 
Public Overloads Overridable Function Draw( _
   ByVal newExtent As Envelope _
) As CartoImage
Visual Basic (Usage)Copy Code
Dim instance As View
Dim newExtent As Envelope
Dim value As CartoImage
 
value = instance.Draw(newExtent)
C# 
public virtual CartoImage Draw( 
   Envelope newExtent
)

Parameters

newExtent
Extent at which the Map will be redrawn.

Return Value

New map image with input extent, in the form of a CartoImage object. Use CartoImage.Url to retrieve the image's URL.

Example

This example defines a new envelope and uses it in drawing the map.
C#Copy Code
Envelope newExtent = new Envelope(10, 30, 30, 50); 

CartoImage resultImage = mapView.Draw(newExtent); 

imgMap.ImageUrl = resultImage.Url; 

    
Visual BasicCopy Code
Dim newExtent As New Envelope(10, 30, 30, 50)

Dim resultImage As CartoImage = mapView.Draw(newExtent)

imgMap.ImageUrl = resultImage.Url

Remarks

This method draws the map with the envelope specified. The exact envelope drawn may be modified to fit the aspect ratio of the map image pixel size.

Any Zoom, Pan, CenterAt or Draw method which changes the map extent also changes the map extent for the MapView.

See Also

© 2010 All Rights Reserved.