Adding items from different Listboxes, and then counting them

2 posts, 0 answers
  1. Laurence
    Laurence avatar
    1 posts
    Member since:
    Dec 2014

    Posted 21 Dec 2014 Link to this post

    I currently have 3 listboxes - Each one contains a "CustomAttr" attribute.

    Listbox1.items["CustomAttr"] = 1
    Listbox2.items["CustomAttr"] = 2
    Listbox3.items["CustomAttr"] = 3

    Destination Listbox = DestinationListBox

    So when I drag an item from Listbox 1 to DestinationListBox, the item in DestinationListBox will still maintain ["CustomAttr"] = 1 (I believe)

    In the OnClientTransferring client event, is it possible to get a count of items in DestinationListBox by attribute? 

    The reason I ask is I want to be able to add only 5 items of ["CustomAttr"]  = 1, and ensure that if that is the case from OnClientTransferring, I can cancel the event using args.set_cancel(true);

    If anyone has a better way of carrying out this type of function, I would really appreciate the assistance..

    Many thanks,
  2. Bozhidar
    Bozhidar avatar
    1096 posts

    Posted 24 Dec 2014 Link to this post


    I've created a sample page demonstrating the described functionality. Feel free to modify it to suit your requirements as needed.


    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

  3. DevCraft R3 2016 release webinar banner
Back to Top