Hi,
I've overriden the WndProc of the ComboBox and I am drawing my own combo box, a code snippet is below:
Protected Overrides Sub WndProc(ByRef m As Message)
MyBase.WndProc(m)
Select Case m.Msg
Case &HF
Dim g As Graphics = Me.CreateGraphics
If ComboBoxRenderer.IsSupported Then
Dim pTextBoxRect As New Rectangle(Me.ClientRectangle.X, Me.ClientRectangle.Y, Me.ClientRectangle.Width, Me.ClientRectangle.Height)
ComboBoxRenderer.DrawTextBox(g, pTextBoxRect, _tbState)
' .... and so on
End Select
End Sub
Though the old control is still being painted as my drawn combo box is just overlapping the old drawing. Is there a way to stop it drawing the default combo box?
Thanks, Rob