Adding labels to PieChart made with WPF Toolkit Charting Controls

WPF Toolkit Charting Controls is a dated assembly that allows to create line, bar, area, pie and column charts (it is possible to find an exhaustive and very tutorial on CodeProject about how to use it). It is a really ready to use tool, but sometimes it lacks some useful features.

In my case the pie chart does not allow to show labels with percentage on each pie area. It is a real pity.

Since each pie area is rendered by using a Geometry, my idea is to add something (i.e. another Geometry) to the one already computed. Areas are a handled by the PieDataPoint class. So we can get the Geometry computed by PieDataPoint, then add a new Geometry with the relative parcentage value and the use this new composition for drawing the area in the chart.

Continue reading “Adding labels to PieChart made with WPF Toolkit Charting Controls”

Appending pages to SSRS Pdf print management reports

More than once, it happened to me that a customer wanted to insert at the end of some PDF reports of the print management (invoices, confirmations, etc.) one or more pages containing different terms and conditions.

The first solution that can come to mind is to add these conditions directly to the report layout and repeat them for each requested report. However it is not uncommon that this list of clauses is the same for all reports and at the same time is very long. In cases like this it would not be a bad idea to have a single and already formatted text.

The ideal would be to have a pdf that contains the clauses to be able to hang directly to a report. Doing such a thing is not extremely complicated in D365fo. Let’s see how it can be done.
Continue reading “Appending pages to SSRS Pdf print management reports”

Create and release a Product

In AX 2012 it was possible to create Product and Product Master through coding by use of some classes like EcoResProductServices or EcoResEcoResProduct (more info here).

With Dynamics 365 for operation those classes do not exist anymore, but it is possible to obtain the same result by using the product data entity (i.e. EcoResProductEntity) and some standard – long named – classes.

Continue reading “Create and release a Product”