Ian wrote:
Though if you're using an n-tier approach, making it more generic also has the disadvantage that the controls have to call the BL routines they need, which thus should be working without knowledge of the page the control is on.
Sorry to be picky but I'm just interested in this stuff.
What do you mean by make it more generic?
With generic I mean: it can function without relying on the logic in the page. So you just drop it on the page, and data it needs will be read by the control itself. Somewhat what you had in mind.
How does a control calling a BL routine imply that a control has knowledge of the page its on?
I meant the opposite: if the component reads data by itself, it calls a BL routine to do that: it calls a BL method and that method returns with the data. If the page has more of these controls, this means that the page can't share a connection object for example, as the components communicate with the BL individually, without the page.
If you don't want that, you have to fetch the data in the page and pass it on to the control.