152 | Chapter 9 Enhanced Layer Functionality API Additions
Accessing the Enhanced Layer Functionality
API
The enhanced layer functionality API is only available to layers that use a
spatial data provider (SDP) or OLE database data source. To protect data
sources against unwanted changes, map authors must provide passkey access
for a layer before you can access the API for enhanced layer functionality.
Map authors set up access to the API via the Map Layer Properties dialog box
in Autodesk MapGuide Author.
For more information about providing access to the enhanced layer func-
tionality API from a layer, see “Providing Access to the Enhanced Layer Func-
tionality API” on page 37 of Chapter 4, “Enhanced Layer Functionality.”
If the map author has provided passkey access, you must set the passkey via
the existing Autodesk MapGuide API. If you do not set the passkey, you will
get a -5 (Security Violation) error.
For more information about setting a passkey using the API, see “Accessing
Secure Data” in the Autodesk MapGuide Developer’s Guide, which you can open
by clicking Autodesk MapGuide 6.5 ➤ Documentation ➤ Autodesk
MapGuide Developer’s Guide on the Program menu.