We help IT Professionals succeed at work.

how do i insert a shape in toolbox for vb-bet 2003

In VB 6 the shape to draw square rectangle...is  in the default toolbox , but I cannot find it in VB-NET 2003?
Watch Question

There is no shape control in .net, no. You can draw in your form paint event, or use the border prop of your controls on your form (perhaps add a panel or something?).

Here's a free shapecontrol (i havent tried it, but I guess its pretty simple).

If you like to draw it by yourself (a rectangle on the form):

Private Sub Form1_Paint(ByVal sender As Object, ByVal e As System.Windows.Forms.PaintEventArgs) Handles Me.Paint
 Dim myPen As New System.Drawing.Pen(System.Drawing.Color.Black)
 Dim formGraphics As System.Drawing.Graphics
 formGraphics = Me.CreateGraphics()
 formGraphics.DrawRectangle(myPen, 5, 5, formGraphics.VisibleClipBounds.Width - 10, formGraphics.VisibleClipBounds.Height - 10)
End Sub

Open in new window

Éric MoreauSenior .Net Consultant
Top Expert 2016

if you were using VB2005, I would have said to use the VB power packs (http://msdn2.microsoft.com/en-us/vbasic/bb735936.aspx)

Explore More ContentExplore courses, solutions, and other research materials related to this topic.