Access Unique DataKeyValue and Delete Images from RadImageGallery Bound to a Data source

1 posts, 0 answers
  1. Telerik Admin
    Telerik Admin avatar
    1679 posts
    Member since:
    Oct 2004

    Posted 02 Jul 2015 Link to this post


    Telerik Product and Version


    Supported Browsers and Platforms

    FF - current and previous
    Chrome - current and previous

    Programming language

    C#, VB


    When RadImageGallery is bound to a database either by using its DataSourceID property or programmatically using NeedDataSource event handler, you can access the Description, ImageUrl and Title properties exposed by the ImageGalleryItem class respectively filled with values coming from the DataDescriptionField, DataImageField, DataTitleField settings of the RadImageGallery. The attached web site demonstrates how to access any other field value from the related data source record by adding the fields in the DataKeyNames collection.

    There are two specific points to be noted when deleting the selected Image:
    • EnableViewState should be set to False
    • CurrentItemIndex should be reset to 0

Back to Top