开发者

autopackback dropdownlist only if changed using mouse

I would like to perform a postback when the droplist开发者_开发技巧list selected value changes, but only if it was changed via expanding the downdown and clicking an option, not is the user tabs to the control and uses the arrow keys. The reason for this is simple, keyboard accessibility.


Postbacks are triggered using __doPostBack('uniqueidofcontrol', 'commandname'); so when the list changes value (I believe in onchange event), it posts to the server. You would need to not set autopostback. What you would need to do is tap into the click event (if there is one) and then call __doPostBack(..) method upon that event.

HTH.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜