Jump to content
JChartFX Community

JuanC

Administrators
  • Posts

    421
  • Joined

  • Last visited

  • Days Won

    3

Everything posted by JuanC

  1. This is a bug, we are in the process of testing a fix for it. In the meantime you can workaround the bug by changing the MarkerStyle for all series to Filled, to retain the look of your markers you can then set the MarkerStyle for each series to Hollow, e.g. if your chart has 2 series chart1.getAllSeries().setMarkerStyle(cfx.MarkerStyle.Filled); chart1.getSeries().getItem(0).setMarkerStyle(cfx.MarkerStyle.Hollow); chart1.getSeries().getItem(1).setMarkerStyle(cfx.MarkerStyle.Hollow); JuanC
  2. I already forwarded your question to our licensing guys as this forum is more geared to technical questions. You can contact them directly with your question in case they need more info, send an email to sales at softwarefx dot com. JuanC
  3. I suspect when you do PriceData = $("#hidPriceChart").val() you might be getting a string instead of an array of javascript objects, if this is so, you might need to use eval() to get the data as an array of objects. Note that when you manually hardcode var priceData = [{..}], the priceData variable will hold an array of objects so if you do alert(priceData) javascript should tell you object or array or something like that as opossed to a string. Another option would be to change your ASP.NET code so that it generates the client code that declares var priceData=[{... instead of using a hidden field. Regards, JuanC
  4. We do not support organizational charts and it is not a feature we have plans for at this point. JuanC
  5. We are exploring this but we have not comitted to a release date or timeframe yet. JuanC
  6. This bug should be fixed on our next build. We apologize for the inconvenience. Note that we do not try to alphabetically sort the cells or headings. The cells are painted in the correct order which is the order of the series in your data, in the sample data the first series is AAPL, the second is GOOG and so on. The headings are being incorrectly painted in the reverse order of the data. JuanC
  7. You can configure per-point attributes using our jQuery UI as follows var points = $("div", ".demo2").chart("getPoints"); var pointAttr = new cfx.PointAttributes(); // Use this if you are NOT using jChartFX CSS // pointAttr.setColor("#00FF40"); // Use this if you are using jChartFX CSS and make sure there is an entry // in your CSS for this tag // pointAttr.setTag("SpecialPoint"); points.setItem(0, 4, pointAttr); Please note that whenever you want to access one of our complex properties, e.g. a property that represents a collection such as Points you get the collection as a method and then use a very similar code that you would use against a pure JS implementation. JuanC
  8. Try posting the interesting parts of your page in the order they appear in the page, including <script> tags and code where you create the chart. JuanC
  9. Please note that you can create charts without using our css, if you want to change colors or other visual attributes you can do so using our API. JuanC
  10. I would try 2 or 3 things to try to isolate the problem 1) Comment all the lines trying to update the date for ChartWhole and ChartDetail and add a line that changes something simple in one of the charts, e.g. the gallery, obviously you want to make sure you set a gallery different than then one you are using ChartWhole.setGallery(cfx.Gallery.Doughnut); 2) If option 1 worked, try changing the chart's data to other "hardcoded" data, e.g. var newData = [{"Open":127,"Date":"2013-10-02T16:45:05.000Z"},{"Open":45,"Date":"2013-10-03T23:30:05.000Z"},{"Open":92,"Date":"2013-10-04T22:45:05.000Z"}]; ChartWhole.setDataSource(newData); 3) Add code to make sure result.d contains the data you expect (using alert and/or console.log), sometimes the function will be called with a string instead of a json object. Checking the documentation it would seem that the default for the $.post function is to make an intelligent guess so you want to make sure they are guessing right, the parameters you are passing to the URL (company and dataType) are only used by the server, it also seems you can pass a fourth parameter to specify the dataType so I would also test adding a fourth parameter "json" to the $.post parameter, e.g. In my personal tests the browser did not guess right with a static php (maybe it uses a header and it does not inspect the URL contents) so I had to use "json" as the fourth parameter, doing an alert(result) will show different results with and without the fourth parameter. $.post("data.php", { company: "foo", dataType : "json", }, function(result) { if(!result) return; chart1.setDataSource(result); }, "json"); JuanC
  11. We do not show the data because the namecount field contains strings not numbers. You have 2 choices 1) Modify the json response as shown, note the values for namecount do not contain quotes which makes them numbers and not strings [{"name":"Event","namecount":1},{"name":"Job","namecount":1}] 2) If you cannot modify the json used to populate the chart, specify how to use the data fields var field1 = new cfx.FieldMap(); field1.setName("name"); field1.setUsage(cfx.FieldUsage.Label); var field2 = new cfx.FieldMap(); field2.setName("namecount"); field2.setUsage(cfx.FieldUsage.Value); chart1.getDataSourceSettings().getFields().add(field1); chart1.getDataSourceSettings().getFields().add(field2); Regards, JuanC
  12. You need 2 things, - Use the setMultipleColors so that we know the chart will be displayed one color per point, note that as soon as you do this and even if you do not set your own colors, each point will use a different color. this.chart.getAllSeries().setMultipleColors(true); - Change the index of the series from 0 to -1 inside the loop where you set the colors for each bar, this tells us that the particular attribute applies to all series (in case there is more than 1) so it will appear in the legend box this.chart.getPoints().getItem(-1,i).setColor(this.config.items.color); Regards, JuanC
  13. Not sure what your question means. Can you please expand on what you mean by "give the user preferred color to the 3D charts"? Is this the same question that was posted in the Styling forum about colors in CSS? Regards, JuanC
  14. Zoom is currently not supported in jChartFX. Regards, JuanC
  15. Currently there is no property to control the depth of a 3D Pie. We will consider adding this to future builds. Regards, JuanC
  16. There is a bug but you can work around it by passing the color to the conditional attributes, e.g. conditional1.setColor("#00FF00"); conditional2.setColor("#FFFF00"); conditional3.setColor("#FF0000"); We will actually use the color from the CSS (for the 3D planes) so it is not necessary that the colors you supply match the CSS but they should be different for each conditional (there might be optimizations where we ignore the change if we think the colors are the same). Regards, JuanC
  17. It would be really simple switching to our "plain" javascript scripts. - You are already including jchartfx.system and jchartfx.coreVector, remove the reference to jchartfx.ui.js - Add a div in your page that will be the holder of the chart - create a new cfx.chart object and call the create method passing the div object (or div id). You can read more details at http://support.softwarefx.com/jChartFX/article/2501235#2d0978a4-8c87-e211-84a5-0019b9e6b500 JuanC
  18. >> On another note on the same code as above, how would I go about removing the title, or more specificly turn it "visible: false" like I can with the legend? That yellow box is actually created by our jQuery UI plugin so that it looks similar to other jQuery UI plugins, unfortunately there is currently no way to remove it, we should fix this in our next build, for now you can remove the text by setting the title text to "" titles : [{text: ""}], >> Also how would I go about setting the Y value minimum to what is the lowest data value on the chart, it does the maximum fine You do not have to set min or max, if you do not want 0 to be the min (we do this because in most cases it is what users want) you want to turn off the forceZero property axisY : { forceZero: false } Regards, JuanC
  19. When you do $.get('data.php', ... afaik the browser will asynchronously download the URL and then run your code, which means the items variable will be invalid when the chart is created, I would recommend you try the following 1) Initialize the items variable to dummy data, later you can try to set this to an empty array to avoid showing dummy data 2) Inside your function make sure you parse response as it is a string and the set the dataValues property of the chart as follows $.get('data.php', function (response) { var data = $.parseJSON(response); $("div", ".chartDiv1").chart("option", {dataValues:data}); }); I also noticed that the dates for the php generated output are slightly different than what we expect, they do not have the T separating the date and time and the Z at the end, we pass this dates to a javascript function that expects a very particular format, if you still have problems with the proposed changes I would recommend you try first without using dates, e.g. - Do no set dataSourceSettings in the chart initialization - Use dummy data as follows var items = [{"Month":"Jan", "Value":15},{"Month":"Feb", "Value":23},{"Month":"Mar", "Value":18}]; - Create a new php that returns something like this [{"Month":"Jan", "Value":150},{"Month":"Feb", "Value":87},{"Month":"Mar", "Value":120}, {"Month":"Apr", "Value":120}] If the data changes then you know you have fixed the "dynamic" part of the data and then can focus on why your dates don't work as expected Regards, JuanC
  20. We have uploaded a new build (7.1.5021) that should fix this tooltip positioning issue. Regards, JuanC
  21. We have uploaded a new build (7.1.5021) that should fix this issue. We changed how tooltips are handled in XY charts with both X as numbers or dates. Regards, JuanC
  22. We have uploaded a new build (7.1.5021) that changes how we handle tooltips in XY charts or charts where you use dates in the X axis. If you are using dates and need the full date/time info in the tooltip you should change the Format property of the AxisX DataFormat object as follows chart1.getAxisX().getDataFormat().setFormat(cfx.AxisFormat.DateTime); Regards, JuanC
  23. We have uploaded a new build (7.1.5021) that should fix this issue. Regards, JuanC
  24. Hopefully this sample helps both the operator name question and the new line question var items = [ { "FullName": "John Smith", "Sales": 10, "NickName": "JohnS" }, { "FullName": "Mark Twain", "Sales": 12, "NickName": "MarkT" }, { "FullName": "Peter Collins", "Sales": 8, "NickName": "PeterC" }, ]; var field1 = new cfx.FieldMap(); field1.setName("Sales"); field1.setUsage(cfx.FieldUsage.Value); chart1.getDataSourceSettings().getFields().add(field1); var field2 = new cfx.FieldMap(); field2.setName("NickName"); field2.setUsage(cfx.FieldUsage.Label); chart1.getDataSourceSettings().getFields().add(field2); chart1.setDataSource(items); var contentTemplate = '<DataTemplate>' + '<DockPanel Orientation="Vertical">' + '<DockPanel Orientation="Horizontal" Margin="3,0,3,0">' + '<TextBlock Text="{Binding Path=SeriesT}" Margin="0,0,4,0"/>' + '<TextBlock Text="{Binding Path=Value}" FontWeight="Bold" HorizontalAlignment="Right"/>' + '</DockPanel>' + '<DockPanel Orientation="Horizontal" Margin="3,0,3,0">' + '<TextBlock Text="Full Name:" Margin="0,0,4,0"/>' + '<TextBlock Text="{Binding Path=DataFullName}" FontWeight="Bold" HorizontalAlignment="Right"/>' + '</DockPanel>' + '</DockPanel>' + '</DataTemplate>'; chart1.getToolTips().setContentTemplate(contentTemplate); Note that we have not documented the XML language we interpret (heavily inspired by XAML) but the next build will also support a Grid layout. JuanC
  25. There is a bug in the current build, we should upload a new build soon with a fix for this. Regards, JuanC
×
×
  • Create New...