MGMap.createLayer   Go to object model Go to parent topic Go to previous topic Go to next topic

Syntax

MGMapLayer createLayer(String type, String name)

Description

Creates and adds a layer of the specified type to the map.

At this time, only redline layers can be added to the map. For more information on redline layers, refer to "Applications" in the Autodesk MapGuide Developer's Guide.

Parameters

type - The layer type; currently redline is the only supported type.

name - The layer name.

Returns

MGMapLayer - An MGMapLayer object if successful, null otherwise.

Error Codes

-1 (busy)

-3 (illegal argument)

-5 (security violation)