G
Greg Phillips
I have written a usercontrol which I drop onto aspx pages in my project,
this usercontrol performs changes on the content of various aspx controls on
the page.
So I have a datagrid on the page, which I want to change the column headings
before the page is rendered. The page headings are stored in a database.
I do a recursive call through all the controls on the page.
I can get this to work, all well. The problem I have is that if I want the
column headings to be changed before the page is rendered I have to place
the rendering of the controls in the INIT event. This will then
successfully change the column names. The problem is that I loose all events
that the datagrid receives.
If I place the rendering in the page load of the usercontrol, the events get
passed back, but the headings are not changed.
Now I have has a look at the page model on MSDN,
http://msdn.microsoft.com/library/d.../en-us/dnaspp/html/aspnet-pageobjectmodel.asp
Which shows different events and methods that can be overwritten, I have
tried each one of them, and the only one that allows me to render the
datagrid columns is the init event but it also makes the events to
disappear.
Does anyone know how to get around this problem?
this usercontrol performs changes on the content of various aspx controls on
the page.
So I have a datagrid on the page, which I want to change the column headings
before the page is rendered. The page headings are stored in a database.
I do a recursive call through all the controls on the page.
I can get this to work, all well. The problem I have is that if I want the
column headings to be changed before the page is rendered I have to place
the rendering of the controls in the INIT event. This will then
successfully change the column names. The problem is that I loose all events
that the datagrid receives.
If I place the rendering in the page load of the usercontrol, the events get
passed back, but the headings are not changed.
Now I have has a look at the page model on MSDN,
http://msdn.microsoft.com/library/d.../en-us/dnaspp/html/aspnet-pageobjectmodel.asp
Which shows different events and methods that can be overwritten, I have
tried each one of them, and the only one that allows me to render the
datagrid columns is the init event but it also makes the events to
disappear.
Does anyone know how to get around this problem?