| View previous topic :: View next topic |
| Author |
Message |
NINTENDO Grandmaster Cheater Supreme
Reputation: 0
Joined: 02 Nov 2007 Posts: 1371
|
Posted: Sat Jan 19, 2008 7:15 am Post subject: c# - auto hide/show buttons. |
|
|
| Code: | private void form1_mousemove(object sender, MouseEventArgs e)
{
if (Cursor.Position.X >190 && Cursor.Position.Y >510 )
{
button1.Visible = true;
}else{
button1.Visible = false;
}
}
} |
_________________
Intel over amd yes. |
|
| Back to top |
|
 |
Symbol I'm a spammer
Reputation: 0
Joined: 18 Apr 2007 Posts: 5094 Location: Israel.
|
Posted: Sat Jan 19, 2008 7:54 am Post subject: |
|
|
Only if the mouse is over the form it gets to the MouseMove event, if its outside the form it never gets there, unlike delphi, even when the form isn't focused or even if its minimized it works.
google C# Mouse Hook or something, you will probably find something that will work in a thread or something...
Also C# is case sensetive.
|
|
| Back to top |
|
 |
NINTENDO Grandmaster Cheater Supreme
Reputation: 0
Joined: 02 Nov 2007 Posts: 1371
|
Posted: Sat Jan 19, 2008 8:35 am Post subject: |
|
|
| Symbol wrote: | Only if the mouse is over the form it gets to the MouseMove event, if its outside the form it never gets there, unlike delphi, even when the form isn't focused or even if its minimized it works.
google C# Mouse Hook or something, you will probably find something that will work in a thread or something...
Also C# is case sensetive. |
ok i'll use a timer then -.-
_________________
Intel over amd yes. |
|
| Back to top |
|
 |
|