Warning, this page is marked to be deleted!
Columns Selector - Grid Objects

All the information that the grid contains is now important for ones or other users of the system, although the grid continues with a large width and the columns are too tight. WorkWithPlus provides a functionality for giving the possibility to the final users to select which columns to show and in which order: Columns Selector for grids. This feature is enabled by default when you apply WorkWithPlus to a transaction.

The following attributes must be hidden when the grid is loaded the first time, but the user must have the option to select them if he wants to visualize them.

  • PersonFirstName
  • PersonLastName
  • PersonNickName
  • CompanyId
  • PersonHasFavoriteMusicBand
  • PersonFavoriteMusicBand
  • PersonIsHomeAddressRequired
  • PersonHomeAddress

To do this, you can use the Visible by default property.

Observation: you can select many columns at a time (attributes in this case) and modify the property that you think is the right one.

SelectionFeatures_img09

Run the application (F5), and go to PersonWW in order to visualize the results.

Observation:

  • The ColumnsSelector implemented with a Regular Grid does not have the option to reorder the columns because is a GeneXus limitation that the columns cannot be reordered at runtime. And the Free Style Columns Selector does have that option but it has other limitations. We recommend using the first option.
  • If you close the application and open PersonWW again, the columns that the grid will display and the order of them will be reset to the values by default. It is able to save the columns state in the data base opening the procedures LoadColumnsSelectorState and SaveColumnsSelectorState and following the instructions defined in their sources, but we won’t do it in this training (you could try this at the end of the training).

In the following video you can see an overview of this functionality: