HorizontalLinesCount: Number;
The HorizontalLinesCount property determines the number of horizontal grid lines.
Property value can be set from JSON or using the setHorizontalLinesCount method.
The property is relevant if the value of the MapGrid.HorizontalLinesStepType property is PP.MapGridStepType.StepsCount.
To execute the example the HTML page must contain the MapChart component named map (see Map Layout on HTML Page). Create a grid that consists of three horizontal and five vertical lines, and add it to the map:
var mapGrid = new PP.MapGrid({
Chart: map,
Color: PP.Color.getColor("#0033FF"), // Line color
Width: map.getWidth(), // Grid width
Height: map.getHeight(), // Grid height
Thickness: 1, // Grid lines width
HorizontalLinesCount: 5, // Number of horizontal grid lines
VerticalLinesCount: 3, // Number of vertical grid lines
// Create a grid using specified number of lines
HorizontalLinesStepType: PP.MapGridStepType.StepsCount,
VerticalLinesStepType: PP.MapGridStepType.StepsCount
});
if (!mapGrid.getIsDrawed()) {
// Draw a grid
mapGrid.draw();
};
After executing the example a grid that consists of three horizontal and five vertical blue lines is added to the map:

See also: