label backgrond flicking on a WinForms user control has background image enabled
- by slowlycooked
I am working on a windows form project and having some problem with UserControl Double Buffering.
I created a usercontrol and has a background image, then on top of it I have few radio buttons and labels. Radio buttons and labels are all having transparent background as color.
However, when I show and hide the User control, I can see the flickering on those labels and radio buttons that has transparent background.
And I tried
Me.SetStyle(ControlStyles.DoubleBuffer _
Or ControlStyles.AllPaintingInWmPaint _
Or ControlStyles.UserPaint _
Or ControlStyles.SupportsTransparentBackColor, _
True)
After initializeComponent() to enable double buffer on this user control, but it doesn’t seem to work.