CFChart Problem in ColdFusion MX 7

Ask a Question related to Coldfusion - Advanced Techniques, Design and Development.

  1. #1

    Default CFChart Problem in ColdFusion MX 7

    Macromedia, We just recently upgraded to CFMX 7 and some cfcharts
    that we are using are not displaying like they used to. In reading through the
    notes it sounds like there have been some modifications made to where if you
    enter a scaleTo value that is going to 'crop' the graph, it takes the scale
    higher. I have a graph that I want to go from 0 to 100 with the maximum data
    value being 99 so it would never be off the chart. It still will not display
    from 0 to 100. This is a very annoying problem and I was wondering if there is
    anyway to bypass the 'auto-scale' function of the cfchart? Thanks. Micah Knox

    jmicah Guest

  2. Similar Questions and Discussions

    1. cfchart Problem
      I am having a problem displaying all of the itemColumn values when I use the cfchart function. I am retreiving 10 records with a query, however on...
    2. CFChart Problem in MX 7
      I am unable to get a single stacked bar to display using cfchart, but I can get multiple bars to display correctly. When I look at the chart, the...
    3. CFChart Pie problem
      When creating a pie from a database query, if 2 or more adjacent slices are very small, say 1 or 2 percent, then the data labels will overlap each...
    4. CFCHART Problem
      I have a few pages with flash charts and a java menu on the same page. I cannot find where to set the WMODE properties for the flash charts to make...
    5. CFCHART problem in CF7
      My charts in CF7 are not showing all of my x-labels when they worked fine in CF6.1. The only way all the x labels appear in CF7 is when I increase...
  3. #2

    Default Re: CFChart Problem in ColdFusion MX 7

    <cfchart scalefrom="0" scaleto="100" chartheight="#chartheight#"
    chartwidth="#chartwidth#" fontbold="yes" format="flash" labelformat="percent"
    show3d="yes"
    xaxistitle="#thisyear#" title="YTD Occupancy" showlegend="yes">

    Here is a sample of code I use. Would the scalefrom and scaleto params work
    for you?

    Just a thought.

    Eric

    EricInToronto Guest

  4. #3

    Default Re: CFChart Problem in ColdFusion MX 7

    Eric, Thanks for the reply. My code looks very similar to yours, the
    problem is that the new cfchart actually changes the scale parameters. It
    doesn't matter if I put 0 to 100 it will change it to -50 to 150 if there is a
    plot that falls on 1 and a different plot that falls on 99. I'm not sure why
    they made this change because in CFMX 6.2, I have the exact same data being
    charted and it doesn't crop the graph even though the points are that close to
    the scale min and max. If you are running CFMX 7 try plotting something with
    data that is very close to your 0 to 100 scale and see what happens. It's all
    sorts of fun. :) Micah

    jmicah Guest

  5. #4

    Default Re: CFChart Problem in ColdFusion MX 7

    I don't have a fix, Micah. Rather, I'm experiencing a similar problem, which
    I'll share here. My development server is running CFMX7, and I have not had a
    chance to test this on 6.1, so I'm sure if the issue is related to the CF
    version. In certain charts, the 'scaleto', 'scalefrom' and 'gridlines' values
    are not being used correctly when the chart is generated. I'm aware that the
    'scalefrom' and 'scaleto' values are modified by the charting code if they
    would result in cropping the chart contents, but that's not the case here. I'm
    attempting to display two charts: one works, the other doesn't. The first has
    the following atttributes - scalefrom='0' , scaleto = '1', gridlines='11'. The
    values displayed on the chart are always decimals <= 1. The chart displays
    correctly, with Y-axis labels and gridlines from 0 to 1, in increments of 0.1.
    The second chart has its scaling values set dynamically, to present a compact
    chart based on making the top of the Y-axis slightly higher than the largest
    displayed Y-value. (For instance, if the largest Y-value is 298, the 'scaleto'
    is set to 300.) The following values were sent to the <cfchart> tag (I output
    them elsewhere to verify them): scalefrom='0', scaleto='300', gridlines='31'.
    This should have produced a Y-axis running from 0 to 300, naturally, with
    gridlines at 10,20,30,etc. The displayed chart, however, ran from -50 to 600,
    in increments of 50. There were 14 total gridlines, including the axis. No data
    points were less than 0, so there was no need for the Y-Axis value to extend
    below 0. All data points were displayed in the correct positions - the highest
    Y-value was 298, just as it should have been. Only the number of gridlines and
    the scaling were incorrect. I followed up by placing static values into these
    attributes as a test, using the same data to create the data points. The
    results changed, but were still mostly wrong. Occasionally, the number of
    gridlines was correct, but the scaling values continued to be wrong, although
    they changed. For instance, when I hard-coded the following: scalefrom='0',
    scaleto='300', gridlines='4', I got a chart which did, in fact have 4
    gridlines. But the scale went from -200 to 400. I have also tested this with
    chart formats of both Flash and JPEG, with the same results. Does anyone (MM,
    perhaps?) have any light to shed on this? Tom McNeer

    TMc Guest

  6. #5

    Default Re: CFChart Problem in ColdFusion MX 7

    Hi - This is a new behavior of the new charting engine in CFMX 7. It tries to
    ensure that no content on the chart is ever clipped off. So if a thick line
    touches 0 or 100 it means that the bottom of it will be below zero (the middle
    of the line is drawn on zero) or above 100, so the Y axis gets adjusted (up or
    down). We are looking at a way to allow you to override this behavior if you
    wish. I'll follow up once I have some more information to report. Tim

    tbuntel Guest

  7. #6

    Default Re: CFChart Problem in ColdFusion MX 7

    I'm having the same problem. I am not able to use the 'scaleto' and
    'scalefrom' parameters. Is there a fix for this problem. It works fine with
    6.1, but it does not work for 7.0. I would like to scale from 0 to 100.
    However for some datapoints it will scale from 0 to 200 even though the
    datapoint is less than 100.

    amarana Guest

  8. #7

    Default Re: CFChart Problem in ColdFusion MX 7

    Hi everyone

    We are looking into this problem and will keep you guys informed.

    regards
    Prayank
    prayank Guest

  9. #8

    Default Re: CFChart Problem in ColdFusion MX 7

    Can you people post some sample code for which will help us reproduce this problem?

    Regards
    Prayank


    prayank Guest

  10. #9

    Default Re: CFChart Problem in ColdFusion MX 7

    Here is some sample code that will reproduce the problem we are talking about.
    You will notice in the code that the scale is from 0 to 100 and that is where I
    would like it to stay however, when the graph gets drawn, it changes from -50
    to 150. This is the effect we would like to be able to turn off or maybe
    change the width of the line so that if you have a point at 1, it doesn't
    actually touch the x axis. <cfchart format='flash' chartwidth='250'
    chartheight='175' tipbgcolor='##FFFFCC' scalefrom='0' scaleto='100'
    showxgridlines='no' showygridlines='yes' gridlines='5' showborder='no'
    markersize='4' fontbold='yes'> <cfchartseries type='line'
    markerstyle='diamond' seriescolor='##FF0000' serieslabel='Redline'>
    <cfchartdata item='Point1' value='1'> <cfchartdata item='Point2'
    value='50'> <cfchartdata item='Point3' value='99'>
    </cfchartseries> </cfchart> Hope this helps and thank you Macromedia for
    helping out on this one! -Micah

    jmicah Guest

  11. #10

    Default Re: CFChart Problem in ColdFusion MX 7

    Can you send me an email (tbuntel@macromedia.com)? I'd like to ask for your help in testing a fix for this.
    Thanks!
    tbuntel Guest

  12. #11

    Default Re: CFChart Problem in ColdFusion MX 7

    Status update on the CFMX 7 Scaleto and ScaleFrom issue?

    Will there be a hot fix for this issue?

    Thanks.

    realbeaux Guest

  13. #12

    Default Re: CFChart Problem in ColdFusion MX 7

    A technote with the fix for scaling and other issues in on the horizon, ETA mid next week.

    regards
    Prayank
    prayank Guest

  14. #13

    Default Re: CFChart Problem in ColdFusion MX 7

    While using cfchart with a "pie" type chart, legend does not contain anymore
    information like total and percentage ratio. With 6.1 MX, charting a pie will
    provide legend like Item A 3 (25%), now, only Item A is display, is there any
    way to customize this through webcharts to have more details in the legend

    SmoIntranet Guest

  15. #14

    Default Re: CFChart Problem in ColdFusion MX 7

    The technote addresses this issue too.
    prayank Guest

  16. #15

    Default Re: CFChart Problem in ColdFusion MX 7

    is the scalefrom/scaleto cfmx 7 problem fixed in the latest hotfix:

    ColdFusion MX 7 Cumulative Hot Fix 2
    Current hot fix level: chf700002
    Released: 4/21/2005

    I do still have problems with scalefrom/scaleto ...


    isocrates Guest

  17. #16

    Default Re: CFChart Problem in ColdFusion MX 7

    Macromedia,
    I was just wondering if there is any new word on the hot fix that's
    coming out to fix the cfchart problem? I think last we heard it was supposed
    to be the middle of last week and I was just wondering what the new eta would
    be. Thanks.

    -Micah Knox

    jmicah Guest

  18. #17

    Default Re: CFChart Problem in ColdFusion MX 7

    > I was just wondering if there is any new word on
    > the hot fix that's coming out to fix the cfchart problem?
    [url]http://www.macromedia.com/go/e6a6dd7a[/url]

    This was made available a while ago, sorry no one posted to this thread.

    --
    Tom Jordahl
    Macromedia Server Development



    Tom Jordahl Guest

  19. #18

    Default Re: CFChart Problem in ColdFusion MX 7

    Thanks macromedia for coming out with that fix. That really helped me out with
    my project. I was wondering what other parameters you can change in the xml
    style to manipulate the chart. For example, is there a way to turn off the
    small animation as the line on a line graph is being raised up? Just curious.
    Thanks again.

    Micah Knox

    jmicah Guest

  20. #19

    Default Re: CFChart Problem in ColdFusion MX 7

    Micah,

    There is a program that will allow you to tweak a ton of things in the XML
    file. Look for webcharts.bar in the CFusionMX7/charting directory.

    --
    Tom Jordahl
    Macromedia Server Development


    Tom Jordahl Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139