locked
to create a textbox for drawing RRS feed

  • Question

  • how to create a text to draw such paint
    Wednesday, March 14, 2007 5:43 AM

Answers

  • Public Class UDtextbox
    Inherits TextBox

    Sub New()
    MyBase.New()
    Me.SetStyle(ControlStyles.UserPaint, True)
    End Sub

    Protected Overrides Sub OnPaint(ByVal e As
    System.Windows.Forms.PaintEventArgs)
    MyBase.OnPaint(e)
    Dim g As Graphics = e.Graphics
    g.DrawLine(Pens.Red, 0, 3, Me.Width, 3)
    g.Dispose()
    End Sub

    End Class

    is the code for ur question

    and this code is copy right by Seth Rowe

    Wednesday, March 14, 2007 5:54 AM