long createLabelAtLocation(string ck, string fc, string label, string x, string y)
This method places text given by label in the TextAPI's associated view at the location given by the x and y. The latter must be relative to the Exchange Coordinate System, unless the map is of type NRMR (See Map Types). After creation, the text feature has CARIS Key ck and Feature Code fc.
The text feature is created with the current default values for font, color, size, rotation, and placement relative to the given location. The text feature can also be restricted to the map's cover or not. These defaults can be set via the following methods:
This method returns 0 upon success, and returns error codes under the following conditions:
- The given coordinates are invalid
- Feature placement is restricted and the coordinates are outside the map's cover
- The SDM cannot create a valid font object
- The SDM cannot create a valid label object
- The SDM cannot create a valid text object
The latter three problems should normally not occur and may indicate a corrupted map dataset.