Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the difference between a click and mouseclick?

Tags:

c#

winforms

What is the difference between a click and mouseclick?

like image 598
RoR Avatar asked Oct 04 '10 02:10

RoR


People also ask

What is the difference between one click and Doubleclick?

Typically, a single click initiates a user interface action and a double-click extends the action. For example, one click usually selects an item, and a double-click edits the selected item.

How do you check if a button is clicked twice C#?

When it is clicked the first time, isClicked is false so the if (isClicked) expression will be false and the statement it sets up wont run. Then you set isClicked to true . Now the second time a user clicks the button, the if (isClicked) expression will be true and the statement will run.


2 Answers

Assuming you're referring to WinForm Control events, from the MSDN documentation for Control.Click:

The Click event passes an EventArgs to its event handler, so it only indicates that a click has occurred. If you need more specific mouse information (button, number of clicks, wheel rotation, or location), use the MouseClick event. However, the MouseClick event will not be raised if the click is caused by action other than that of the mouse, such as pressing the ENTER key.

like image 65
Michael Petrotta Avatar answered Oct 05 '22 09:10

Michael Petrotta


A click can be caused by not only a mouse click, but also some events like a pressed key, etc. For more information, see Control.Click Event.

like image 27
Ruel Avatar answered Oct 05 '22 08:10

Ruel