Calling postback in asp.net programmatically

10,535

Solution 1

I think you can use triggers after the content template of update panel.

One more simple suggestion:

If you just want to cause a postback and to do nothing after postback, simply double click the button in the design view, you will get an onbuttonclick event generated in the code behind page. Don't write anything inside that button click event block. The page will get posted onclicking the button. If you want to implement something, write the code inside the button click event.

Solution 2

Since there are some quite good articles on the web explaining this, let me answer your question with a link:

Solution 3

go to the button property u will find postback url .. if not then use rowCommand to get the button event rise

Share:
10,535

Related videos on Youtube

Ramesh.kbvr
Author by

Ramesh.kbvr

Updated on June 04, 2022

Comments

  • Ramesh.kbvr
    Ramesh.kbvr almost 2 years

    I am using spgridview with spgridviewpager in update panel. I need to postback using c# in aspx page. I used button field in the spgridview. When i clicked on the button field, i need to raise the postback event using c# or javascript.

    Can any have an idea how to do it programmatically?

  • Ramesh.kbvr
    Ramesh.kbvr about 13 years
    do you have an idea how to do it programatically
  • Robin Agrahari
    Robin Agrahari about 13 years
    many others ways are there ypu can also use the onclientclick event handler of ur button ,u can use the postbackurl of ur button but it depends all on what u actually want to do with the postback.i can give explained solution if u give the full scenario