Hide/Show ajax cloud BalloonPopupExtender

时光总嘲笑我的痴心妄想 提交于 2019-12-13 04:42:46

问题


I'm using the BalloonPopupExtender on a text box in order to say : "Unknown input" because its the only one that allows me to have a panel in which i can insert whatever controls i want.

i want from a button push to show it and from a text change in the textbox to hide it. i noticed there is no visibility property for BalloonPopupExtender, only the DisplayOnFocus, DisplayOnClick.... properties. but no way to control it from another button or function.

how can i hide/show the BalloonPopupExtender?


回答1:


Try using the below event handler call

onmouseout="this.BalloonPopupControlBehavior.hidePopup();"



回答2:


Ok i found the answer:

in the javascript i wrote :

var ctrl = $find('PopupCnt'); 

event.cancelBubble = true;

    if (ctrl._popupVisible == true) 
        ctrl.hidePopup(); 
    else 
        ctrl.showPopup();  

the 'event.cancelBubble = true' row did the thing.

and another thing - i was pushing a button that caused a postback so even if the popup showed it would reset when the new page is up so it looked like it didn't work. i just created a button with no postback and it worked.



来源:https://stackoverflow.com/questions/8286741/hide-show-ajax-cloud-balloonpopupextender

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!