-
July 15th, 2010, 05:30 PM
#1
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
-
July 16th, 2010, 05:06 AM
#2
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
-
July 16th, 2010, 02:04 PM
#3
Re: Prerender(): what is it?
Originally Posted by Alsvha
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
-
July 19th, 2010, 05:38 AM
#4
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
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|