MultiptFVB - sindizzy/DSW GitHub Wiki

Sample code that demonstrates how to create a Multi Point Feature

Imports DotSpatial.Data
Imports DotSpatial.Geometries

Private Sub button1_Click(sender As Object, e As EventArgs)
	Dim c As Coordinate() = New Coordinate(35) {}
	Dim rnd As New Random()
	For i As Integer = 0 To 35
		c(i) = New Coordinate((rnd.[Next](Next)(50) + 360) - 180, (rnd.NextDouble() * 180) - 90)
	Next
	Dim Mps As New MultiPoint(c)
	Dim f As New Feature(Mps)
	Dim fs As New FeatureSet(f.FeatureType)
	fs.Features.Add(f)
	fs.SaveAs("C:\Temp\test.shp", True)
End Sub