Partial Public Class Form1
Inherits Form
Public Sub New()
InitializeComponent()
MenuStrip1.Renderer = New MyRenderer()
End Sub
End Class
Public Class MyRenderer
Inherits ToolStripProfessionalRenderer
Protected Overloads Overrides Sub OnRenderMenuItemBackground(ByVal e As ToolStripItemRenderEventArgs)
Dim rc As New Rectangle(Point.Empty, e.Item.Size)
Dim c As Color = IIf(e.Item.Selected, Color.Azure, Color.Beige)
Using brush As New SolidBrush(c)
e.Graphics.FillRectangle(brush, rc)
End Using
End Sub
End Class