asp.net dropdownlist should have unique value item, i.e.
ddl.items.add(new listitem(key, value)) -> here value should be unique
otherwise on postback you get incorrect selectedindex.
e.g.
ddl -> America, 1
Europe, 2
Asia, 3
is correct
but
ddl -> America 1
Europe 1
Asia 2
is not correct
No comments:
Post a Comment