Bekijk de onderstaande video om te zien hoe je onze site als een web app op je startscherm installeert.
Opmerking: Deze functie is mogelijk niet beschikbaar in sommige browsers.
Public Class Form1
Private Sub Form1_Paint(ByVal sender As Object, ByVal e As PaintEventArgs) Handles MyBase.Paint
Dim g As Graphics = e.Graphics
Dim pen As New Pen(Color.Red, 2.0)
For Each ctr As Control In Me.Controls
If TypeOf ctr Is TextBox Then
g.DrawRectangle(pen, New _
Rectangle(ctr.Location, ctr.Size))
End If
Next
pen.Dispose()
End Sub
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
TextBox1.BorderStyle = BorderStyle.None
End Sub
End Class
Daar is geen propery voor de ENIGE manier is om deze zelf te tekenen om de textboxxen
Code:Public Class Form1 Private Sub Form1_Paint(ByVal sender As Object, ByVal e As PaintEventArgs) Handles MyBase.Paint Dim g As Graphics = e.Graphics Dim pen As New Pen(Color.Red, 2.0) For Each ctr As Control In Me.Controls If TypeOf ctr Is TextBox Then g.DrawRectangle(pen, New _ Rectangle(ctr.Location, ctr.Size)) End If Next pen.Dispose() End Sub Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load TextBox1.BorderStyle = BorderStyle.None End Sub End Class
Dim g as Graphics = Me.CreateGraphics 'Als de tekstbox in bijv een panel zit, moet je "Me" veranderen in bijv "Panel1"
We gebruiken essentiële cookies om deze site te laten werken, en optionele cookies om de ervaring te verbeteren.