How to Generate events from strings
-
Is there is any way to generate the events form string values such as I have string s = "Paint" is there any code that if the control have paint event it is generated and a particular method is called Thanks and Regards Amar Chaudhary
It is Good to be Important but! it is more Important to be Good
-
Is there is any way to generate the events form string values such as I have string s = "Paint" is there any code that if the control have paint event it is generated and a particular method is called Thanks and Regards Amar Chaudhary
It is Good to be Important but! it is more Important to be Good
Try using reflection: Reflect the Paint event on the object and invoke it.
-^-^-^-^-^- no risk no funk ................... please vote ------>
-
Is there is any way to generate the events form string values such as I have string s = "Paint" is there any code that if the control have paint event it is generated and a particular method is called Thanks and Regards Amar Chaudhary
It is Good to be Important but! it is more Important to be Good
use this type of approach In the method
void Method() { PaintTemp_Paint+=new new System.Windows.Forms.PaintEventHandler(this.PaintTemp_Paint); }
Ravi