dcsimg


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 3 of 3

Thread: How to fire the textchanged event programmatically

  1. #1
    Join Date
    Feb 2006
    Posts
    19

    How to fire the textchanged event programmatically

    I have a textchanged method with some code within

    protected void tbQty_TextChanged(object sender, EventArgs e){

    some code

    }

    I want to call this method from within another method

    protected void cbSelectItem_CheckedChanged(object sender, EventArgs e){

    tbQty_TextChanged();

    }

    How can i do this.

    Thanks!

    Alex

  2. #2
    Join Date
    Dec 2004
    Posts
    163
    Alex,

    One way is to put the code that you want to call in its own function. Then call that function from the text_changed event and from any other code that needs that functionality.

    Kerry Moorman

  3. #3
    Join Date
    Dec 2005
    Location
    South of Nowhere, Maine
    Posts
    309
    I second Kerry's method. Much more logical and pretty simple to implement.

Similar Threads

  1. How long before the next version??
    By _CAG in forum .NET
    Replies: 146
    Last Post: 08-12-2002, 10:40 PM
  2. Re: App Object (fixes)
    By Rob Teixeira in forum .NET
    Replies: 129
    Last Post: 06-06-2002, 05:23 AM
  3. Replies: 0
    Last Post: 12-14-2001, 12:45 PM
  4. Validate event doesn't fire
    By Paolo in forum VB Classic
    Replies: 2
    Last Post: 12-14-2001, 09:04 AM
  5. ReadProperties event won't fire
    By Sebastian Flyte in forum VB Classic
    Replies: 0
    Last Post: 04-18-2001, 02:59 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center