Group columns containing column propertiesHello,
Is there a way to use contain to search the column properties and group them if only the column contains spec limits properties?
Trying to group the columns that contain the column property "Spec Limits". Any advice?

Thanks,
Jackie
Automation and ScriptingRe: Group columns containing column propertiesYou just need to go through the numeric columns and put into a list, the ones with Spec Limits. Then use the Group Columns message to create the group
Names Default To Here( 1 );
dt = Current Data Table();
theNames = dt << get column names( numeric, string );
specLimitsList = {};
For Each( {colName}, theNames,
If( Is Empty( Column( colName ) << get property( "Spec Limits" ) ) == 0,
Insert Into( specLimitsList, colName )
)
);
dt << group columns( "HaveSpecLimits", specLimitsList );Re: Group columns containing column propertiesThis should work on your example table:
</CODE></P><PRE><CODE class=" language-jsl">Names Default To Here( 1 );
dt = Current Data Table();
colList = dt << Get Column Names();
For( i = 1, i <= N Items( colList ), i++,
If( Contains( Char( (Column( i ) << Get Column Properties( string )) ), "Spec" ),
Column( i ) << set selected
)
);
dt << group columns( "name of your group" );