Prerender(): what is it?
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4

Thread: Prerender(): what is it?

  1. #1
    Join Date
    Jul 2007
    Posts
    273

    Prerender(): what is it?

    Hello,
    I was wondering if there's anyone that can explain to me what Prerender should do, for example for a button or a calendar component. I suppose Render must create the table and fills its contents; but Prerender()?
    I can't imagine it; can you show me few lines?
    thanks

  2. #2
    Join Date
    Feb 2005
    Location
    Denmark
    Posts
    742

    Re: Prerender(): what is it?

    I'm not sure if you're talking about the page event PreRender or a specific control?

    But generally in ASP.NET PreRender is the last event run before actually transmitting the page to the client (well, one of the last, which the coder himself can access) aka the page/controls being actually rendered.
    It is often used if having a lot of dynamically created controls, due to the page life-cycle of PageLoad -> Event -> PreRender

  3. #3
    Join Date
    Jul 2007
    Posts
    273

    Re: Prerender(): what is it?

    Quote Originally Posted by Alsvha View Post
    I'm not sure if you're talking about the page event PreRender or a specific control?

    But generally in ASP.NET PreRender is the last event run before actually transmitting the page to the client (well, one of the last, which the coder himself can access) aka the page/controls being actually rendered.
    It is often used if having a lot of dynamically created controls, due to the page life-cycle of PageLoad -> Event -> PreRender
    yes, the event Prereder() but can you give me an example code of "what it can do" for example for a componenet Calendar? thanks

  4. #4
    Join Date
    Feb 2005
    Location
    Denmark
    Posts
    742

    Re: Prerender(): what is it?

    No I can't give code because you put normal code into that event, when you for example have to deal with dynamically loaded controls which needs to have values set but which then can't be set in for example the page load.
    It's just an event run at a specific time in the life cycle of the page.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center