Pergunta

I am working on a project using DevExpress XAF trying to create a dashboard which is mainly a Pivot grid.

When I configure the Pivot Settings in the mode I get the option to Show Chart which, as it states, shows the chart below the pivot grid when the application is run.

When the application is running the end user can then go to the chart and customise the chart.

My question is this: How do I customise the chart in the development environment?

Our end result is to create pivot grid based reporting screens that are configured during development rather than the end user being able to configure them; Customization will be switched off.

Foi útil?

Solução

You can format the pivot grid with a controller in code using a controller. There is a knowledge base article here which shows how to access the pivot grid or pivot chart in code.

Alternatively, you can follow the instructions here which explain how pivot grid customisations are saved to the Analysis object.

The pivot grid's settings are saved to the PivotGridSettingsContent property of the current Analysis object. The settings of the Chart control are saved to the ChartSettingsContent property. So, the next time you invoke a detail View for this Analysis object, the pivot grid and chart are configured in the same way as they were the previous time. Saving and loading settings is performed by the AnalysisEditorWin (AnalysisEditorWeb) editor.

So you can set up the grid correctly and then copy the saved Analysis record and restore it as part of your application startup.

Another option is to look at the eXpand Framework's Pivot Chart module which provides plenty of additional layout options via XAF model extensions.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top