locked
Viewstate information RRS feed

  • Question

  • Hi all ,

    My question is what's the earliest event in which all viewstate information has been stored ?

    1. Init.
    2. Preload.
    3. Load.
    4. Render.

    Wednesday, July 7, 2010 6:45 PM

Answers

  • Hi Spiroff,

       Welcome to MSDN forums! I'm glad to see your active participation and discussion in MSDN forums. 

       Before rendering, view state is saved for the page and all controls

      Hope this will help you!  

       If you still have any doubt and concern about this issue, please let me know. If I misunderstood you, please kindly elaborate your question.


    Please Mark as Answered If this is helpful Or Un-Mark as Answered if it is not helpful.

    Best Regards,
    Yan Jun
    Microsoft Online Community Support

    • Proposed as answer by Paras Sanghani Friday, July 9, 2010 7:37 AM
    • Marked as answer by Spiroff Friday, July 9, 2010 3:31 PM
    Friday, July 9, 2010 3:35 AM
    Moderator
  • Hello,

         Kindly, find the details of all the events along with required information,

    1. Init Event :

    This event fires after each control has been initialized. You can use  this event to change initialization values for control. No viewstate information available in this event.

    2. Init Complete:

    Raised  once all the initializations of the page and its controls have been completed.

    3. PreLoad:

    This event fires before viewstate has been loaded for the page and its controls and before Post Back processing. This event is useful when you need to write code after the page is initialized but before the view state has been wired backup to the controls.

    4. Load :

    The page is stable at this time;it has been initialized and its state has been reconstructed. Code inside  the page load event typically checks for PostBack and then sets control properties appropriately.

    5. PreRender:

    Allow final changes to the page or its control. This event takes place after all regular PostBack events have taken place. This event takes place before saving View State, so any changes made here  are saved 

    6. Render:

     This is a method of the Page object and its controls. At this point, Asp.Net calls this method on each of the page's controls to  get its output.

    This method generates the client side HTML, Dynamic Hypertext Markup Language(DHTML) and scripts necessary to properly display a control at the browser.

     

    Kindly, let me know if your have any further queries.

    Thanks,

    Paras Sanghani

    Mark As Answer if it helped you.

    • Proposed as answer by Paras Sanghani Friday, July 9, 2010 7:37 AM
    • Marked as answer by Spiroff Friday, July 9, 2010 3:31 PM
    Friday, July 9, 2010 7:26 AM

All replies

  • It Preload event.

     

    Check this http://msdn.microsoft.com/en-us/library/ms178472.aspx

    it has all the information.

     


    Please mark the response as answers if it solves your question or vote as helpful if you find it helpful. My Blog: http://ashishkhandelwal.arkutil.com
    Wednesday, July 7, 2010 6:55 PM
  • I think we are here to simplify the work to each other I'll not go to the ASP.NET apress book , or wrox ...  to find the answer .

    thanks Ashish 


    Regards Y.Nazm
    Wednesday, July 7, 2010 7:04 PM
  • Hi Spiroff,

       Welcome to MSDN forums! I'm glad to see your active participation and discussion in MSDN forums. 

       Before rendering, view state is saved for the page and all controls

      Hope this will help you!  

       If you still have any doubt and concern about this issue, please let me know. If I misunderstood you, please kindly elaborate your question.


    Please Mark as Answered If this is helpful Or Un-Mark as Answered if it is not helpful.

    Best Regards,
    Yan Jun
    Microsoft Online Community Support

    • Proposed as answer by Paras Sanghani Friday, July 9, 2010 7:37 AM
    • Marked as answer by Spiroff Friday, July 9, 2010 3:31 PM
    Friday, July 9, 2010 3:35 AM
    Moderator
  • Hello,

         Kindly, find the details of all the events along with required information,

    1. Init Event :

    This event fires after each control has been initialized. You can use  this event to change initialization values for control. No viewstate information available in this event.

    2. Init Complete:

    Raised  once all the initializations of the page and its controls have been completed.

    3. PreLoad:

    This event fires before viewstate has been loaded for the page and its controls and before Post Back processing. This event is useful when you need to write code after the page is initialized but before the view state has been wired backup to the controls.

    4. Load :

    The page is stable at this time;it has been initialized and its state has been reconstructed. Code inside  the page load event typically checks for PostBack and then sets control properties appropriately.

    5. PreRender:

    Allow final changes to the page or its control. This event takes place after all regular PostBack events have taken place. This event takes place before saving View State, so any changes made here  are saved 

    6. Render:

     This is a method of the Page object and its controls. At this point, Asp.Net calls this method on each of the page's controls to  get its output.

    This method generates the client side HTML, Dynamic Hypertext Markup Language(DHTML) and scripts necessary to properly display a control at the browser.

     

    Kindly, let me know if your have any further queries.

    Thanks,

    Paras Sanghani

    Mark As Answer if it helped you.

    • Proposed as answer by Paras Sanghani Friday, July 9, 2010 7:37 AM
    • Marked as answer by Spiroff Friday, July 9, 2010 3:31 PM
    Friday, July 9, 2010 7:26 AM