MapWinGIS:AxMap DrawingKey
From MapWindow GIS
DrawingKey
The drawing key may be used by the programmer to store any data desired in string format for any drawing layer specified by the drawing handle.
VB.NET Usage
Property set_DrawingKey(DrawHandle As Integer, param0 As String)
Parameters
|
DrawHandle | The drawing handle for the drawing layer for which the drawing key is to be set. |
| param0 | The drawing key string for the specified drawing layer. |
Property get_DrawingKey(DrawHandle As Integer) As String
Parameters
|
DrawHandle | The drawing handle for the drawing layer for which the drawing key is required. |
| ReturnValue | The drawing key string for the specified drawing layer. |
Sample Code
Private Sub DrawingKey()
Dim draw_hndl As Integer
Dim draw_key As String
'Create new drawing layer on map
draw_hndl = Map1.NewDrawing(MapWinGIS.tkDrawReferenceList.dlScreenReferencedList)
'Draw filled red circle at x = 100, y = 100, with radius 50
Map1.DrawCircle(100, 100, 50, System.Convert.ToUInt32(RGB(255, 0, 0)), True)
'Set the drawing key for the drawing layer
Map1.set_DrawingKey(draw_hndl, "Red Circle")
'Get the drawing key for the drawing layer
draw_key = Map1.get_DrawingKey(draw_hndl)
End Sub
VB 6 Usage
Property DrawingKey(DrawHandle As Long) As String
Parameters
|
DrawHandle | The drawing handle for the drawing layer for which the drawing key is required. |
| ReturnValue | The drawing key string for the specified drawing layer. |
Sample Code
Private Sub DrawingKey()
Dim draw_hndl As Long
Dim draw_key As String
'Create new drawing layer on map
draw_hndl = Map1.NewDrawing(dlScreenReferencedList)
'Draw filled red circle at x = 100, y = 100, with radius 50
Map1.DrawCircle 100, 100, 50, RGB(255, 0, 0), True
'Set the drawing key for the drawing layer
Map1.DrawingKey(draw_hndl) = "Red Circle"
'Get the drawing key for the drawing layer
draw_key = Map1.DrawingKey(draw_hndl)
End Sub
















