Please tell me which code or process turns a gridview links into a format like
javascript:__doPostBack(‘ctl00$…
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Asp.Net uses the __doPostback javascript function called _doPostBack(). The function is –
This function is used to submit the form back to the server. _doPostBack accepts arguments – event target and event arguments by using hidden variables
__EVENTTARGETand__EVENTARGUMENT. This tells the server which control caused the postback and also passes appropriate arguments to the server.if you have this code in your aspx page –
The corresponding generated markup will be –
So, say you click on a link button, the page is postback by the
__doPostBack()function. Then, the page is recreated at server with the respective control state on the page. To get the state of each control on the page mechanisms like viewstate are used. Once the page is loaded, the server computes and renders the response markup.