473,385 Members | 1,337 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

What does Prerender() do?

mickey0
142 100+
Hello,
I read this
http://www.c-sharpcorner.com/UploadF...LifeCycle.aspx
and 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 can't imagine it; can you show me few lines?
thanks
Jul 15 '10 #1
2 6722
shaahin
11
Hi
MSDN :
Raised after the Page object has created all controls that are required in order to render the page, including child controls of composite controls. (To do this, the Page object calls EnsureChildControls for each control and for the page.)

The Page object raises the PreRender event on the Page object, and then recursively does the same for each child control. The PreRender event of individual controls occurs after the PreRender event of the page.

Use the event to make final changes to the contents of the page or its controls before the rendering stage begins.
http://msdn.microsoft.com/en-us/libr...prerender.aspx
Jul 19 '10 #2
Frinavale
9,735 Expert Mod 8TB
The PreRender event is the last stage in the ASP.NET Life Cycle that you have access to the controls on your page (or within your user control). At point all of the control event code has been executed so you can check the states of all of your controls and do things accordingly.


I use the PreRender event quite often...it's very useful.

Please note, though, that the PreRender event for a control/user-control is only called if the control is being rendered. If the control's Visible property is set to False, the event is not called.

-Frinny
Jul 19 '10 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Derek Fountain | last post by:
The documentation says session_destroy() "destroys all of the data associated with the current session". Um, like what? The docs further say that you should remove all information in the _SESSION...
70
by: Roy Yao | last post by:
Does it mean "(sizeof(int))* (p)" or "sizeof( (int)(*p) )" ? According to my analysis, operator sizeof, (type) and * have the same precedence, and they combine from right to left. Then this...
2
by: Steve Richter | last post by:
What does the "." mean in the following sql script stmts? use GO if exists (select * from dbo.sysobjects where id = object_id(N'.') and OBJECTPROPERTY(id,N'IsUserTable') = 1) drop table ....
2
by: Tom | last post by:
I'm getting this error when I try to pass a structure to a dll. An unhandled exception of type 'System.ArgumentException' occured in Test1.exe Additional Information: Type could not be marshaled...
0
arunmib
by: arunmib | last post by:
Hi all, I have doubt, as what does __declspec (dllimport) or __declspec(dllexport) does? If add these only the functions of a dll are exported or imported right? So what exactly does...
9
by: JoeC | last post by:
m_iWidth = (int)pBitmapInfo->bmiHeader.biWidth; m_iHeight = (int)pBitmapInfo->bmiHeader.biHeight; What does this mean? I have seen v=&var->member.thing; but what does it mean when you...
92
by: Heinrich Pumpernickel | last post by:
what does this warning mean ? #include <stdio.h> int main() { long l = 100; printf("l is %li\n", l * 10L);
9
by: James Dow Allen | last post by:
How about this idea? Post fragments of C code which seem fun, interesting or instructive. Puzzles can be posed in various ways. (What does this do? Can you see the bug? How to code this for...
2
by: Lambda | last post by:
The code is simple: // Token.h #ifndef TOKEN_H #define TOKEN_H #include <vector> #include <string> class Token
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.