Difference between AutoPostBack=True and AutoPostBack=False?

后端 未结 10 1902
广开言路
广开言路 2020-12-01 09:07

What\'s the difference between AutoPostBack=True and AutoPostBack=False?

相关标签:
10条回答
  • 2020-12-01 09:47

    AutopostBack :

    AutopostBack is a property of the controls which enables the post back on the changes of the web control.

    Difference between AutopostBack=True and AutoPostBack=False:

    If the AutopostBack property is set to true, a post back is sent immediately to the server

    If the AutopostBack property is set to false, then no post back occurs.

    0 讨论(0)
  • 2020-12-01 09:48

    AutoPostBack = true permits control to post back to the server. It is associated with an Event.

    Example:

    <asp:DropDownList id="id" runat="server" AutoPostBack="true" OnSelectIndexChanged="..."/>
    

    The aspx page with the above drop down list does not need an asp:button to do the post back. When you change an option in the drop down list, the page gets posted back to the server.

    Default value of AutoPostBack on control is false.

    0 讨论(0)
  • 2020-12-01 09:48

    AutoPostBack property:

    Asp.net controls which cannot submit the Form (PostBack) on their own and hence ASP.Net has provided a feature using

     AutoPostBack = "true"
    

    : which controls like DropDownList, CheckBoxList, RadioButtonList, etc. can perform PostBack(when clicked on it).

    And

    AutoPostBack = "false"
    

    It is the by default state of controls which can perform Postback on button submit.

    0 讨论(0)
  • 2020-12-01 09:50

    hai sir

    There is one event which is default associate with any webcontrol. For example, in case of Button click event, in case of Check box CheckChangedEvent is there. So in case of AutoPostBack true these events are called by default and event handle at server sid

    0 讨论(0)
提交回复
热议问题