javascript - How to Postback with radconfirm window with RadContextMenu? -


i have code below , aspx-->

<telerik:radcontextmenu id="radcontextmenu1" runat="server" onclientitemclicking="onclientcontextmenuitemclicking"          onitemclick="radcontextmenu1_itemclick" oninit="radcontextmenu1_oninit">          <items>              <telerik:radmenuitem value="addnick" text="" />              <telerik:radmenuitem value="edit" text="" />              <telerik:radmenuitem value="delete" text="" font-bold="true" />          </items>      </telerik:radcontextmenu>  

javascript -->

 var allowposback = false;   function confirmcallbackfn(arg, eventargs) {                  if (arg) {                      allowposback = true;                  }    }     function onclientcontextmenuitemclicking(sender, eventargs) {                  var item = eventargs.get_item();                  item.get_menu().hide();                   switch (item.get_value()) {                      case "delete":                           var message = "delete"                         var event = "event";                          var width = 300;                          var height = 100;                          var title = "want delete";                         radconfirm(message, confirmcallbackfn, width, height, null, title);                          eventargs.set_cancel(allowposback);                          break;                  }              }  

control radcontextmenu not postback after confirm clicking why not having post back. great ?

i think you've misunderstood how radconfirm box works. i've answered similar question (strange behavior of confirmation in telrik ?) should re-write code above work properly.

also might find following link useful (also posted @ end of other answer): http://demos.telerik.com/aspnet-ajax/window/examples/confirmserverclicks/defaultcs.aspx.


Comments

Popular posts from this blog

java - activate/deactivate sonar maven plugin by profile? -

python - TypeError: can only concatenate tuple (not "float") to tuple -

java - What is the difference between String. and String.this. ? -