L
lagay
I have a class library that is called from a form that adds controls to the
form at runtime. I am currently working on creating a PictureBox control at
runtime and am having problems trying to hook up code to the click event of
the PictureBox. The form will contain the code for the click event and I
need to add this event to the PictureBox control at runtime from the class
library.
myPictureBox.Click += new EventHandler(event_name);
I know I need to use Reflection; but there are many methods that have been
removed from the compactframework that I just can't figure out how to
accomplish what I need to do. Has anyone done this before?
Thanks,
Lisa
form at runtime. I am currently working on creating a PictureBox control at
runtime and am having problems trying to hook up code to the click event of
the PictureBox. The form will contain the code for the click event and I
need to add this event to the PictureBox control at runtime from the class
library.
myPictureBox.Click += new EventHandler(event_name);
I know I need to use Reflection; but there are many methods that have been
removed from the compactframework that I just can't figure out how to
accomplish what I need to do. Has anyone done this before?
Thanks,
Lisa