Datagrid render column headings. ASPX Page Model. Events

Discussion in 'ASP .Net Datagrid Control' started by Greg Phillips, Oct 11, 2004.

  1. 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?
     
    Greg Phillips, Oct 11, 2004
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Lau Lei Cheong

    Page.Render do not render complete page

    Lau Lei Cheong, May 15, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    2,120
    Lau Lei Cheong
    May 15, 2004
  2. Seth Williams

    freeze column headings

    Seth Williams, Oct 17, 2008, in forum: ASP .Net
    Replies:
    2
    Views:
    454
  3. S. Hussain Akbar

    Repeating column headings

    S. Hussain Akbar, Jan 5, 2004, in forum: ASP .Net Datagrid Control
    Replies:
    0
    Views:
    120
    S. Hussain Akbar
    Jan 5, 2004
  4. Steven Van Dyke

    HOwTO: Set column headings based on dynamic DataView?

    Steven Van Dyke, Nov 12, 2003, in forum: ASP .Net Mobile
    Replies:
    1
    Views:
    195
    Steven Van Dyke
    Nov 12, 2003
  5. carmen

    Sorting column headings

    carmen, Jul 21, 2004, in forum: ASP General
    Replies:
    2
    Views:
    163
    dlbjr
    Jul 21, 2004
Loading...

Share This Page