0
I have a dropdownlist that takes data from the bank sql server. I carry that dropdownlist in page_load within a if(!IsPostBack){}
and from what I understand of !IsPostBack
, it only goes there if it’s the first time it loads the page.
What bothers me is that every time I click on one of the items from dropdownlist, page reload. Placing a breakpoint on page_load from the page, I saw that goes there every time I click on an item.
Why does this happen?
How to make it not reload the page for each chosen item?
use Autopostback = "true" in the dropdownlist in the form if you need to load another field or another dropdownlist that depends on the value chosen in the first, so your second field will be loaded.
– Marco Souza