Vivian River
Vivian River

Reputation: 32410

How do I make my ASP.net control perform a postback?

I'm writing my first ASP.net control. I would like to know to know how to make the control postback when the user clicks something (but in general, I want to know how to make arbitrary events make the control postback).

Update Thanks for the answer. However, upon more Googling, it sounds like I'm supposed to make my control call a JavaScript function called __doPostBack. It says that I'm supposed to pass __doPostBack the UniqueID of the control.

Upvotes: 1

Views: 213

Answers (1)

womp
womp

Reputation: 116987

You implement IPostBackEventHandler. The linked MSDN page includes a code example.

Upvotes: 5

Related Questions