Showing results for 
Search instead for 
Did you mean: 

Select which row of the gallery is selected and visible

We have many scenarios where it will be useful to select which row of a gallery is active and ensure it is visible. For example, if a screen allows “in-gallery” editing, and the user clicks on the “Add” button, we add a blank row in the gallery, but the user must scroll/sort/search the new records if the gallery as many. In another scenario, the user scrolls in the gallery and the clicks on “view detail” button that opens a screen with the selected record information. When the user returns to the gallery screen, it is repositioned at the beginning of the list.


In both scenarios, it will be helpful to

  • be able to indicate programmatically which row is the “selected” one in the gallery :
    SelectRow(<Logical expression>) //Select the first row matching the expression
  • issue a command to ensure the selected row is currently visible:
    EnsureSelectedVisible(MyGallery) //Ensure the selected record of MyGallery is visible in the gallery control (even if the screen is not visible)
Status: New
Community Champion

Hi all, this is a duplicate to this idea:


Please add your vote and/or comments to the above thread as well.


To control which item is selected you do this via the Default property of the gallery.

Advocate II

Ok, I read the other idea and I guess I could work with this solution... very convoluted ways to get the thing done compare to a simple method on the gallery... but I will try the suggested approach.