Jump to content
Software FX Community

Frank

Staff
  • Posts

    1,761
  • Joined

  • Last visited

Everything posted by Frank

  1. e.Series, e.Point may be -1 if you click outside of the pie. Check for this condition before using them as indexes.
  2. How about the samples included with the product?
  3. Client-Side? Please explain exactly what you want to do in this click event. If your event code is going to change the chart, the best way is to capture the event server-side. Set UseCallbackForEvents if you want your event to refresh only the chart and not the whole page using AJAX.
  4. Like any Windows Form control, Chart FX is single threaded. You can't set any chart property from any thread other than the UI thread. You need to determine whether this time is spent reading the data or painting the chart by measuring how long does chart.DataSource = [dataTable] takes to return. If the time is beign spent during data loading, check the structure of your data to make sure it is optimal. If the time is beign spent during paint, the only thing you can do is simplify your chart so that it takes less CPU. Here are some pointers to improve the performance of your chart during paint: - If using a chart with markers, consider eliminating the markers or chosing a less complex marker (Rect is the fastest). - Use 2D over 3D - Consider scrolling - Avoid PointLabelOrganizer
  5. > In the bottom right hand corner there is a green checkmark, Trusted Sites | Protected Mode Off. Then you must assign full trust to Trusted Sites.
  6. > I've set my trust level to full trust for localhost and medium for .net internet Which zone is your page running from? What does the bowser says on the bottom-right? > Although, in that case, I do not get the value from the event args What value? With the series and point index you can obtain the value for that point. > but in FireFox the chart does not show up at all as the .NetClient Firefox doesn't support .NET clients. Only IE on Windows does.
  7. In order for the client control to call an event on the server or fire a JavaAscript it requires FullTrust. Make sure your .NET settings are set so that the client control has full trust. Here is some additional info: Q6141001. Security settings required by the .NET client control URL: http://support.softwarefx.com/ShowArticle.aspx?Type=KB&Product=CfxNet70&Source=http://support.softwarefx.com/kb/614/1/001.htm?_r=1
  8. Frank

    About OLAP

    Headfiles? If you are taliking about references you need to reference the OLAP extension, either ChartFX.WebForms.Olap.dll or ChartFX.WinForms.Olap.dll.
  9. chart.AxisY.DataFormat.Format = AxisFormat.Number;
  10. Chart FX 5.0 is discontinued and is no longer upgraded to work with new technology. However, I have Windows Vista (64-Bit) installed in my desktop and Chart FX 5.0 runs just fine.
  11. Simply capture the Click event.
  12. The following code. Exactly as it is works for me in a sample project created from the scratch: // Set the chart background red.chart.BackColor = System.Drawing.Color.Red; // Set the first series tanchart.Series[0].Color = System.Drawing.Color.Tan; string xmlPreferences; // Get the chart preferences with the red background and tan series.using (System.IO.MemoryStream savedPreferences = new System.IO.MemoryStream()) { chart.Export(ChartFX.WebForms.FileFormat.Xml, savedPreferences); // Try flushing the data to the stream to see if this helps.savedPreferences.Flush(); savedPreferences.Close(); // Convert the stream to a string so we can read the preferences. // You can see here that the new red background and tan series were exported as XML into // the memory stream.xmlPreferences = System.Text.Encoding.UTF8.GetString(savedPreferences.ToArray()); } // Set the chart background white.chart.BackColor = System.Drawing.Color.White; // Set the first series black.chart.Series[0].Color = System.Drawing.Color.Black; // Convert the string back to a stream. This is the preferred method so we can save it to a database column.using (System.IO.MemoryStream restorePreferences = new System.IO.MemoryStream()) { using (StreamWriter sw = new StreamWriter(restorePreferences)) { // Write the XML data to the stream.sw.Write(xmlPreferences); // Try flushing the data to the stream to see if this helps.sw.Flush(); restorePreferences.Flush(); restorePreferences.Seek(0, SeekOrigin.Begin); // Import the colors we set above. // **** THIS DOES NOT SET THE CHART COLORS FOR SOME REASON.chart.Import(ChartFX.WebForms.FileFormat.Xml, restorePreferences); } } // THIS IS STILL WHITESystem.Drawing.Color backgroundColor = chart.BackColor; // THIS IS STILL BLACKSystem.Drawing. Color seriesColor = chart.Series[0].Color;
  13. The problem now you are encoding to UTF8 twice. Change: using (StreamWriter sw = new StreamWriter(restorePreferences,System.Text.Encoding.UTF8)) To using (StreamWriter sw = new StreamWriter(restorePreferences))
  14. During a Zoom you will receive a UserZoom event. You can write code here to enable tootips and highlighting.
  15. I see. Interesting. We are redesigning the auto-layout feature and this will be a nice piece of input for it.
  16. The problem you are having is that the XML you are passing has invalid characters at the end and therefore is not a valid XML document. The reason is that you are using GetBuffer. GetBuffer returns the internal buffer of the memory stream which may be bigger than the actual contents. To obtain the content of the stream you must use ToArray instead: xmlPreferences = System.Text. Encoding.UTF8.GetString(savedPreferences.ToArray());This issue is not related to Chart FX but rather to an incorrect handling of Memory Streams.
  17. chart1.Points[sliceIndex].Link.Url = "http://www.softwarefx.com";
  18. chart1.Points[sliceIndex].Link.Url = "http://www.softwarefx.com";
  19. SVG Rendering is only supported in the Web Forms product. PNG and JPEG can be generated using the Paint method to draw the chart into a Bitmap graphics and then save the bitmap as either JPEG or PNG.
  20. We do not currently have a Windows CE offering. Please contact Software FX sales for more information.
  21. > At least chart can hide empty categories, so "0" point label will not be shown (There is another disadvantage in current behavior: > topmost empty category in the stacked bar chart is visible in 3D view). You should think about hiding empty categories in the charts. > It may be a property in the component interface. Zero and empty are two different things. zero is like any other value. In many applications zero is very important. If you want to hide some segments you should assing null (chart.Hidden) to the value. If you are databinding the chart, any null values in your data will be taken as hidden values. So while hidding zero may seem like the obvious thing to do in this case it not always the case. However, Chart FX is open enough to acoomodate what you want. By simply creating a conditional attribute as follows you will hide the point labels for all zero values: chart1.AllSeries.PointLabels.Visible = true;ConditionalAttributes ca = new ConditionalAttributes(); ca.Condition.From = -1; ca.Condition.To = 1; ca.Condition.FromOpen = ca.Condition.ToOpen = false; ca.PointLabels.Visible = false;chart1.ConditionalAttributes.Add(ca); > I realize that my ideas may be unacceptable for your components, but at least you should think about these things. > Information that your algorithm doesn't guarantee that all items should be shown was new for me. It would be great if you'll add it in the documentation. We welcome your ideas and although we need to worry about more generic cases as one single scenario, we would like to learn more about your case to determine how we can incorporate this into our product. So besides not showing zero, what do you think is the best way to arrange the labels in the chart posted by you previously if you were to do it by hand and what are the rules you used?
  22. The Minj and Max value will be adjusted to fit the data automatically, simply don't set them at design time. Myabe I am not undeerstanding correctly what you want. In that case, can you explain with a specific exaple (data)?
  23. Two things: 1) Organize Point Labels only has an effect on axes-based chart types. It has no effect on Pie charts. The problem you are having in the Pie is that space allocated for the labels is limited as a percentage of the total available space. This can be adjusted using the MaximumLabelMargin property in the Pie class. 2) The Organize Point Labels heuristic does not guarantee all labels will be shown. The algorithm is independent of the gallery type or the Stacked setting. The screenshots you posted show that is working as designed. I think what you are looking for is not going to be achivable using this feature. I don't see how, even doing it manually you can organize the labels on this chart making clear which label corresponds to which segment.
×
×
  • Create New...