Looks like there is no Load event for usercontrol on the CF.
I’m used to loading data on the Load EventHandler.
What is the other alternative to achieve this for CF?
So far looks like I have no choice but to do so in the Contructor of the usercontrol…
I deleted my previous answer as it was absolute rubbish. You’re 100% correct, there’s no Load event for the CF. Turns out I discovered this myself when I wrote my UserControl. I looked for the load event on an old project, in which all my user controls are inheriting from my own base class… called UserControlBase.
I appear to have implemented my own Load functionality within my base class. This is a cut down version of my base class:
Now, in your actual user control, do the following:
This is from a very old project. In later projects I tend to just have a
.Load()method on user controls that is called in theForm_Load.