Make split button behave like dropdown

2 posts, 0 answers
  1. Antony
    Antony avatar
    57 posts
    Member since:
    Oct 2008

    Posted 10 Sep 2009 Link to this post

    HI Everyone,

    At the moment I have a split button on my toolbar with two options:

    Format HTML
    Format Text

    By default the Format HTML is selected and displayed on the toolbar.
    When a user selects Format Text a postback occurs and the Toolbar split button is updated to display the Format Text image.
    Is there a way to stop a postback from occuring when the user clicks the split button?, I only want a postback to occur when the user makes a selection from the dropdown list.

    I know that this is how the DropDown button operates but I can't use it as it does not update the Image displayed on the toolbar when a user makes a selection.

    Any help would be appreciated

    Antony


  2. Yana
    Admin
    Yana avatar
    4554 posts

    Posted 11 Sep 2009 Link to this post

    Hi Antony,

    Please subscribe to OnClientButtonClicking event and check whether the dropdown is open like this:

    function buttonClicking(sender, args) { 
        if (!args.get_item().get_parent()._isDropDownVisible) 
            args.set_cancel(true); 

    Best regards,
    Yana
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top