Public Class Form1 Dim san As New sankaku Private Sub Form1_Paint(ByVal sender As Object, ByVal e As System.Windows.Forms.PaintEventArgs) Handles Me.Paint For i As Integer = 0 To 5 san.hyuji(e.Graphics, 50 + i * 30, 50 + i * 30) Next End Sub End Class Public Class sankaku Sub hyuji(ByVal g As Graphics, ByVal x%, ByVal y%) g.SmoothingMode = Drawing2D.SmoothingMode.AntiAlias Dim points(2) As Point points(0) = New Point(x, y) points(1) = New Point(x - 30, y + 30) points(2) = New Point(x + 30, y + 30) g.DrawPolygon(Pens.Red, points) End Sub End Class