VB.NET 2005 - Dragging window over app leaves "trails"

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Greetings all,

I'm at a loss for fixing this problem, so I'm hoping someone out there has
seen this and has a solution. Basically, I'm working on an app written in
VB.NET 2005 which uses a mixture of native and custom controls. The app
works fine and everything displays correctly until I drag another window
over it. When I do that, there are trails left behind the window until I
stop dragging it, then the window behind redraws correctly. The strange
thing is that it only effects certain controls and they vary depending on
which combination of controls are covered.

The only suggestion I've found was to add the following line to the custom
control's New() subroutine:

Me.SetStyle(ControlStyles.UserPaint Or ControlStyles.OptimizedDoubleBuffer
Or ControlStyles.AllPaintingInWmPaint, True)

This didn't help.


Any suggestions are greatly appreciated.


Thanks!
 
Back
Top