Generates only the tiles that cover the features of the specified layer.


Namespace: AspMap.Web
Assembly: AspMapNET (in AspMapNET.dll)

Syntax

Visual Basic (Declaration)
Public Sub GenerateTiles( _ 
   ByVal scale As Double,  _ 
   ByVal layer As Layer,  _ 
   ByVal cacheDirectory As String _ 
)
C#
public void GenerateTiles(
   double scale,
   Layer layer,
   string cacheDirectory
)
C++
public:
 void GenerateTiles(
   double scale,
   Layer layer,
   String cacheDirectory
) sealed 
J#
public void GenerateTiles(
   double scale,
   Layer layer,
   string cacheDirectory
)
JScript
public  function GenerateTiles(
   scale : double,
   layer : Layer,
   cacheDirectory : String
)

Parameters

scale
Specifies a map scale.
layer
A Layer object. Only the tiles that cover the layer will be generated. If the coordinate system of the layer differs from the coordinate system of the TileLayer, it must be set to the CoordinateSystem property of the layer.
cacheDirectory
Specifies an absolute path to a directory to store the tiles.

Exceptions

Exception TypeCondition
ExceptionThrown if an error occurs.

Remarks

The time needed to generate tiles depends on the scale you have chosen and the density of information in the map. Even using a powerful computer, this process can sometimes take days or weeks.
You should set the coordinate system of your map to the CoordinateSystem property before you call the GenerateTiles method. The coordinate systems of each layer in the TileLayer must be set explicitly or implicitly (via a .prj file).

See Also