wierd event behaviour (VB)

  • Thread starter Thread starter Ivan D
  • Start date Start date
I

Ivan D

Other than buttons, most controls in VB.NET have their
MouseDown event run slow (and I believe this also happened
in VB 6.0). The MouseUp event can keep up with the rate at
which a mouse button is let up, while the MouseDown event
runs about twice per second, max... this also impacts the
Click event (since it works with mouse down), so it also
runs at about twice per second max. This doesn't happen
for button controls, but with other controls like
labels/panels/Pictureboxes/Form surface/UserControls
this "lag" occurs. Since I am trying to make a custom
button with a user control this is going to be a problem.
Is there a way to fix this? Is anyone else getting this
lag?

I check if this happens in C# but it does not. I figure
it's the way the mouse down event is executed by VB. If
this can't be fixed I'll just switch over to C#, no biggy.

Thanks
 
Hi Ivan,

There is a possibility you have some errors in your code, because C# and
VB.net should make the same ILS code from it.

If you did not do it, set option strict on in your VB.net programma, you
have maybe some late bindings in your own build VB.net controls and that
makes it than slow.

Just an idea

Cor
 
Hi,

I think the speed that these events fire has something to
do with the speed you have your mouse double click set in
control panel..
Might be worth having a look at this..

Cheers
 
Back
Top