Hi,
I have a grid with a detail view. The layout of the detail view needs to vary depending on the asset type selected in a dropdown box. The number of different layouts is 30. Each layout has around 20 fields. The data in the grid is driven off an sql table. I have around 240 columns in the table. I have a number of fields that are common to all layouts, some fields which are common to a subset of the layouts, and some fields which are unique to each layout.
The only way I can see to do this is to use the show/hide client-side expression for each of the fields. So the fields that are common to all layouts would have no show/hide expression (so they would appear on all layousts). The fields that appear on a subset of layouts would have an 'ORed' show/hide expression (eg asset_type = 'Truck' or asset_type = 'Car') and the unique fields would have a simple show/hide expression (eg asset_type = 'Boat').
I can see this will involve a lot of work to implement, and I would need to pay attention to thinks like number of fields per column (I need to have multi-column layouts) so I will end up with balanced columns for each of the different layouts.
I'm thinking there must be a better way to do this ? I looked at using a formview control (as it supports multiple layouts) but the data source needs to List control, JSON data or javascript function. I can' see how to use it as a detailed view for a grid?
Any one got a better suggestion ?
Thanks,
Greg
I have a grid with a detail view. The layout of the detail view needs to vary depending on the asset type selected in a dropdown box. The number of different layouts is 30. Each layout has around 20 fields. The data in the grid is driven off an sql table. I have around 240 columns in the table. I have a number of fields that are common to all layouts, some fields which are common to a subset of the layouts, and some fields which are unique to each layout.
The only way I can see to do this is to use the show/hide client-side expression for each of the fields. So the fields that are common to all layouts would have no show/hide expression (so they would appear on all layousts). The fields that appear on a subset of layouts would have an 'ORed' show/hide expression (eg asset_type = 'Truck' or asset_type = 'Car') and the unique fields would have a simple show/hide expression (eg asset_type = 'Boat').
I can see this will involve a lot of work to implement, and I would need to pay attention to thinks like number of fields per column (I need to have multi-column layouts) so I will end up with balanced columns for each of the different layouts.
I'm thinking there must be a better way to do this ? I looked at using a formview control (as it supports multiple layouts) but the data source needs to List control, JSON data or javascript function. I can' see how to use it as a detailed view for a grid?
Any one got a better suggestion ?
Thanks,
Greg
Comment