Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Windows Forms / WinForm General / July 2006

Tip: Looking for answers? Try searching our database.

How to raise an event of button (click event) from textbox's onkeydown event?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
ABC - 25 Jul 2006 09:42 GMT
How to raise an event of button (click event) from textbox's onkeydown
event?

I have a button which have or not a click event and a textbox which have
onkeydown event.
I want add some feature on textbox such process input '*' character will
raise click event of a button.

which function or statement in c# will raise an event of button from
textbox?
Kevin Spencer - 25 Jul 2006 10:57 GMT
Why do you want to raise the Click event of a button? If you want the
KeyDown event handler for a TextBox to execute the same code as the Click
event handler for a button, put the code into a method, and call the same
method from both event handlers.

Signature

HTH,

Kevin Spencer
Microsoft MVP
Professional Chicken Salad Alchemist

Sequence, Selection, Iteration.

> How to raise an event of button (click event) from textbox's onkeydown
> event?
[quoted text clipped - 6 lines]
> which function or statement in c# will raise an event of button from
> textbox?
Herfried K. Wagner [MVP] - 25 Jul 2006 11:19 GMT
"ABC" <abc@abc.com> schrieb:
> How to raise an event of button (click event) from textbox's onkeydown
> event?
[quoted text clipped - 3 lines]
> I want add some feature on textbox such process input '*' character will
> raise click event of a button.

Call the button's 'PerformClick' method.

Signature

M S   Herfried K. Wagner
M V P  <URL:http://dotnet.mvps.org/>
V B   <URL:http://classicvb.org/petition/>


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.