Jump to content
Software FX Community

JuanC

Staff
  • Posts

    863
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by JuanC

  1. Can you duplicate this issue if you do not generate silverlight content? Can you post a small sample ASPX that duplicates this issue? Regards, JuanC
  2. JuanC

    Tooltip issues

    >> How do I reduce the tooltip delay? We use the standard tooltip control but we do not use a ToolTipService so as of now there is no way to control the delays, we will see if we can support this in future builds. >> When I have a pie chart with 1 slice the slice is not highlighted when the tooltip appears By default we do not change any attributes in the highlighted items but instead dim the other elements, in the case of the 1-slice pie there is nothing else to dim. Are you changing some of the properties related to highlighting? Regards, JuanC
  3. If there is a string property in the objects you are passing to the chart then all you have to do is pass that name to the AxisX.Labels.BindingPath property (please note that in older builds this property was AxisX.LabelPath) If you want to style the X axis and show more than one property - e.g. you want to show an image in the X axis - then you will set the AxisX.Template to a datatemplate where you use bindings like "DataItem.YourPropertyName". Regards, JuanC
  4. >> it appears that lines are drawn from columns values and not from rows You are correct the default behavior is that a series reads data from a column/property and each series represents a line in a line chart. Each line will have as many points as items in the collection you pass to the chart. There is a feature we support called DataTransform, the idea is that we can expand the way data is processed by the chart. One of the most useful transforms is crosstab, this allows you to read data like the following Pepsi,Jan,10 CocaCola,Jan,14 Pepsi,Feb,20 CocaCola,Feb,17 Sprite,Feb,12 CocaCola,Mar,9 Sprite,Mar,15 And generate a chart with 3 series (Pepsi, CocaCola and Sprite) and 3 points for each series (Jan, Feb and Mar). You can view a sample here at the end of the thread. In your case you will need a recently added transform called ListTransform. The class in question is in the ChartFX.WPF.Data assembly and it can be used as follows xmlns:cfx="clr-namespace:ChartFX.WPF;assembly=ChartFX.WPF" xmlns:cfxData="clr-namespace:ChartFX.WPF.Data;assembly=ChartFX.WPF.Data" <cfx:Chart Gallery="Line" x:Name="chart1" Grid.Row="2" Margin="10" ItemsSource="{Binding Source={StaticResource prodData}}"> <cfx:Chart.DataTransforms> <cfxData:ListTransform ColumnPath="Sales" ValuePath="Value" /> </cfx:Chart.DataTransforms> </cfx:Chart> In this sample the collection passed to the chart contains CLR objects with a property named Sales that returns a collection of CLR objects with a numerical property called Value. In this scenario if the
  5. If you are passing data you do not need to the set the chart.PointCount property. Also are you sure you want the size of the plotted points to be as big as the number of points in the chart? (This is what series.Marker.Size controls, the size of the rectangle/circle/etc used to represent each point). If you are binding to a datatable you must pass the dataTable.Rows to the chart.ItemsSource property and "NumericData" should be the name of the dataTable column you want to plot. Regards, JuanC
  6. It is hard to know without context about your data. - histogram.Charts should return a collection, this collection should have at least one numerical property - The name of such property should be used as the series.BindingPath - You might want to comment the series.Template = new DataTemplate() line as even if you can fix the NullReferenceException you will be generating an empty chart as the template you are providing has no visuals. I noticed you are using an old version of our control since the MultiPanes property is now AllSeries.MultiplePanes, please download the most recent build or send a message to wpf at softwarefx dot com for an updated version. Regards, JuanC
  7. >> Is it possible to achieve with single series in chart!!! Yes, it is possible. There are 2 ways to accomplish this, manually user per-point attributes or using Conditional Attributes 1) Using per-point Attributes The Points collection allows you to assign per-point attributes. private void PageLoaded(object sender, EventArgs e){ chart1.DataBound += new EventHandler(OnChartBound); }void OnChartBound (object sender, EventArgs e){ // Find the first point that matches your criteria (date greater than today) int firstPoint = 4; PointAttributes pointAttr = new PointAttributes(); pointAttr.StrokeDashArray = new DoubleCollection(new double[] { 1, 2}); int n = chart1.Data.Points; for (int i = firstPoint; i < n; i++) chart1.Points = pointAttr; } 2-a) Using ConditionalAttributes in code private void PageLoaded(object sender, EventArgs e){ ConditionalAttributes conditional = new ConditionalAttributes(); conditional.StrokeDashArray = new DoubleCollection(new double[] { 1, 2 }); RangeCondition rangeCondition = new RangeCondition(); rangeCondition.From = DateTime.Today; rangeCondition.BindingPath = "X"; conditional.Condition = rangeCondition; chart1.ConditionalAttributes.Add(conditional); } 2- Or using ConditionalAttributes in XAML < cfx:Chart.ConditionalAttributes> < cfx:ConditionalAttributes StrokeDashArray="1 2"> < cfx:ConditionalAttributes.Condition> < cfx:RangeCondition From="{x:Static sys:DateTime.Today}" BindingPath="X"/> </ cfx:ConditionalAttributes.Condition> </ cfx:ConditionalAttributes></ cfx:Chart.ConditionalAttributes> Where sys and cfx are defined in your root XAML node as follows xmlns:sys="clr-namespace:System;assembly=mscorlib"xmlns:cfx="clr-namespace:ChartFX.WPF;assembly=ChartFX.WPF" Unfortunately we recently discovered (and fixed) an issue related to conditional attributes when using dates in the X axis, if you want to follow this approach please send an email to wpf at softwarefx dot com requesting an updated build. Regards, JuanC
  8. >> About the Point Label You have to change what we display in the point label by using the chart.PointLabelMask property. You will probably be using %v to show the value and %L to show the text associated with the point. If I remember correctly you will want to use the Tag property, e.. chart1.Points[0,1000].Tag = "XYZ" >> About the Point Color not working What gallery type are you using? I noticed the index used for all other Point attributes was 1000 but the one used for the Color was 100, was this on purpose? Regards, JuanC
  9. Yes, you can assign many properties on a per-series basis (using the Chart.Series collection property) including Gallery and YAxis. Regards, JuanC
  10. >> I'm trying to figure out which named objects are associated with each datapoint. >> I notice that the output from the silverlight writer includes a "canvasmap." ... Could you expose that from the silverlight chart control? Can you expand on when do you need to the mapping?We already expose a click event where we internally use the canvasmap to translate from a visual object to a series/point combination. Do you need an alternate method that exposes this mapping? Or do you need mouse move/hover events with the same information as the click? >> Does the flash writer have this same problem? Actually the flash output is just a static SWF there is no client-side counterpart. >> Is this the right forum for this question? You might want to post silverlight add-on questions in the ChartFX 7 extensions forum. Regards, JuanC
  11. We have fixed this issue in the Silverlight Writer. Please contact support at softwarefx dot com if you need an updated build. Regards, JuanC
  12. The Silverlight client control was not honoring these settings, we have added support for this so future builds will honor the Highlight.Enabled = false setting. Regards, JuanC
  13. We currently keep track of object changes by supporting objects that expose the INotifyPropertyChanged interface but we do not support updates on DPs. You could make your app work by changing your data class as follows public class Venue : INotifyPropertyChanged|{ private double _percent; public event PropertyChangedEventHandler PropertyChanged; protected void RaisePropertyChanged (string name) { if (PropertyChanged != null) PropertyChanged(this, new PropertyChangedEventArgs(name)); } public double Percent { get { return _percent; } set { m_percent = value; RaisePropertyChanged("Percent"); } }} Normally I would recommend supporting INotifyPropertyChanged in your data objects instead of making them DependencyObjects, specially if they will only be used as source of bindings as you may not need the additional perf cost of making them Dependency Objects. That being said, other WPF controls such as listbox support changes in both ways so we will be adding support for DP changes in future builds. Regards, JuanC
  14. Yes, we support stack. All you have to do is chart1.AllSeries.StackedStyle = ChartFX.WPF. StackedStyle.Normal;Note that we also support multiple stack sets, e.g. in a 7 series chart, you could have 3 stack sets (2 ,3 and 2) by setting each series Stacked property. Setting the per-series Stacked property to false will create a new stack set. Regards, JuanC
  15. We have fixed this issue. If anybody else is experiencing this problem please request a new build to wpf at softwarefx dot com Regards, JuanC
  16. In the meantime feel free to send us the template (support at powergadgets dot com) and we can take a look at why highlighting in the X axis is not working as expected. JuanC
  17. >> Can I get them on the same line? Yes, we will contact you offline with a sample on how to do this. Regards,
  18. Can you post details about the chart you are creating, e.g - Data: Is it an XY chart? How many series does it have? - Gallery: are you combining galleries on multiple series? Please include any other relevant modification you are making to the chart. Regards, JuanC
  19. Our current builds will do that automatically, you can also setup your own panel by using the LegendBox.ContainerStyle property with a style as follows < Style x:Key="MyLegendStyle" TargetType="{x:Type ItemsControl}"><Setter Property="Template"><Setter.Value><ControlTemplate><StackPanel Orientation="Horizontal" IsItemsHost="True"/></ControlTemplate></Setter.Value></Setter></Style>Regards, JuanC
  20. Please email your sample app to wpf at softwarefx dot com Regards, JuanC
  21. Inside the chart we use a DockPanel - actually a very similar panel - to layout the different tools (LegendBox, DataView). Because of this you can get the legend at the top of the chart by doing this in XAML < cfx:Chart.LegendBox><cfx:LegendBox Visibility="Visible" DockPanel.Dock="Top" /></cfx:Chart.LegendBox>or in code DockPanel .SetDock(chart1.LegendBox, Dock.Top);Regards, JuanC
  22. JuanC

    3D Charts

    Our new builds declare this property as double instead of bool. We do not support manual transformations to the camera so I am afraid the only zooming available would be to set the chart.Zoom.Mode to ZoomMode.Magnifier. Regards, JuanC
  23. JuanC

    3D Pie Chart Bugs

    We have a build that should fix these issues, please send an email to wpf at softwarefx dot com. Regards, JuanC
  24. You definitely could, but I just wanted to clarify that if you use Olap and Silverlight you will NOT have our OLAP UI that allows you to switch dimensions, slice, filter, etc. JuanC
  25. Because of the way the extensions plug into ChartFX, the silverlight extension should generate the chart data regardless of whether you are using OLAP or any other extension (Statistical, Financial, Maps). Please note that currently none of these extensions support interactivity when the output is not an "Active" chart, i.e. the do not offer interactivity when rendering the chart as Image, Flash, SVG or Sliverlight. Regards, JuanC
×
×
  • Create New...