This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

v8 - Webdesigner - Default grid filter

Hi Experts

When defining a grid, is it possible to define a default filter when loading the grid on one of the columns?

For instance, assume my gridband has a column with either a value of Yes or No. By default, I would like to load this gridband to only show elements with value "Yes". Is this possible?

Thanks

Kin

Parents
  • Hi,

    You could apply a similar solution as when pre-defined grouping columns, described here:

    https://support.oneidentity.com/technical-documents/identity-manager/8.0.1/web-designer-reference-guide/41

    I used the column "IsExternal"; you will need to change the column name.

        var dataSource = GridBand1.DataSource;
    
        var col = dataSource.Table.GetColumn("IsExternal");
    
    	if (!dataSource.Filters.Any())
    	{
    		dataSource.Filters.Add(new VI.WebRuntime.Data.ColumnFilterValueList{
    			Column = col,
    			Values = new object[]{
    			// Insert the filter value here:
    			false
    			}
    		});
    	}
    
  • Hi Hanno,

    Thanks a lot for the response. Please suggest on the below.

    Trying to display a grid with the ability for end users to select additional columns. This seems to work fine when using Database load, however is it possible to get this to work using Collection load instead? Also, when adding additional columns, is it possible to control the order in which the columns are added (e.g. before or after a certain column). Finally, is it possible to re-order columns displayed on a grid by drag-and-drop or even to remove columns shown on a grid?

Reply
  • Hi Hanno,

    Thanks a lot for the response. Please suggest on the below.

    Trying to display a grid with the ability for end users to select additional columns. This seems to work fine when using Database load, however is it possible to get this to work using Collection load instead? Also, when adding additional columns, is it possible to control the order in which the columns are added (e.g. before or after a certain column). Finally, is it possible to re-order columns displayed on a grid by drag-and-drop or even to remove columns shown on a grid?

Children
No Data