Computer Hope

Software => Computer programming => Topic started by: zaryk on April 18, 2008, 10:17:23 AM

Title: c# sharpdevelop keydown event/ drag window
Post by: zaryk on April 18, 2008, 10:17:23 AM
Im creating a search bar that doesnt have a button.  So im figuring i need a keydown event to take whats in the search.  How would I go about creating:

Code: [Select]
if(enter is pressed)
{

}

I can do the other stuff after that.

Also, I am wanting to be able to drag the window from a panel at the top of the window, and not from the windows title, and controlbox.

how can this be done?  Thanks.
Title: Re: c# sharpdevelop keydown event/ drag window
Post by: Sidewinder on April 18, 2008, 12:24:02 PM
I'm guessing your search bar is a control you put on the form. Microsoft (http://msdn2.microsoft.com/en-us/library/system.windows.forms.control.keydown.aspx) can explain this better than me. Well maybe not better, but with more authority.

 8)
Title: Re: c# sharpdevelop keydown event/ drag window
Post by: zaryk on April 20, 2008, 01:02:26 PM
cool, thanks.