Click here to Skip to main content
15,921,905 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
Here is the example of what I want to do :
I have a control namespace:example
C++
example^ a = gcnew example;
this->picturebox1->Controls->Add(a);

when I click on other button,the control appears and I want to add a click event function to do other thing.
What's the code I need to write?
Posted
Updated 2-Jun-12 18:59pm
v2
Comments
Sergey Alexandrovich Kryukov 3-Jun-12 1:18am    
Add event to the code (event object), or an event handler to the invocation list of an event object? Or both? Or do you need to know how to read documentation? Is your MSDN copy broken?
--SA
XRay2 3-Jun-12 1:25am    
I have a custom control. I want to add a click event. the control appears when the application run. It don't appear when I design the form.Do I need to add codes in the custom control or in the main form?

1 solution

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900