Jump to content
Software FX Community

Axis Format and Binding problem


beltrams
 Share

Recommended Posts

Dear Forum,

I have a chart with the following binding:

<cfx:Chart ... ...  ItemsSource="{Binding Path=ReportData, Mode=OneWay}" ... ..."> 

and the X axis with the format:

<

cfx:AxisLabelAttributes Format="Date" />

I have also the following cross table transformation:

<cfx:Chart.DataTransforms>

<cfxData:CrosstabTransform RowPath="AxisXColumn" ColumnPath="SeriesColumn" ValuePath="AxisYColumn" />

</cfx:Chart.DataTransforms>

ReportData is a List<ChartableReportRow>

where ChartableReportRow is a class with the followinf fields:

public

object AxisXColumn (this return actually DateTime but I need "object" because it is a configurable view model and in some case it return strings)

public

decimal AxisYColumn

public

object SeriesColumnMy problem is that the format of dates does not take place (they have always time component, my guess is that the chart is actually using them as strings instead ?)

If I change public object AxisXColumn into public DateTime AxisXColumn the format take place correctly.

Fo you have any suggestion?

Link to comment
Share on other sites

Starting on build 3880 we changed our support for object properties, instead of doing ToString we will wait for the first element and then act according to its type. Please check the version of ChartFX.WPF.dll, if the build number (3rd number) is older than 3880 you can download our most recent hotfix.

JuanC

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...