Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 185
  • Last Modified:

Handling events for controls within a programmatically added User Control

Hi Experts,

I have a user control that has a combobox in it called cbxClientLIst.

The user control is added to a group box on a form programmatically. (see Below).

I want to fill a cell in a datagridview with the details of the selected value once a user leaves the user control combobox... essentially manage an action.

How do I write a handler that fires when the user tabs off the combobox? ..so when they tab off I can take the contents of the combobox and add it to another control....

Kind Regards
Simon
Me.grpInvoiceDetail.Controls.Add(thisUserControl)
        thisUserControl.Location = New Point(339, 16)
        thisUserControl.TabIndex = 0
        thisUserControl.cbxClientList.Focus()

Open in new window

0
si2030
Asked:
si2030
1 Solution
 
bhmahlerCommented:
you can use AddHandler to handle events from a control
http://msdn.microsoft.com/en-us/library/7taxzxka(VS.80).aspx
0
 
si2030Author Commented:
Thanks.. now have that working.
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now