Professional Web Applications Themes

Show percent in cfchart legend? - Coldfusion - Advanced Techniques

I would like to show Column Name and percent (like cfchartseries datalabelstyle="pattern") in the legend of my CFMX 7 charts. Any suggestions?...

Sponsored Links
  1. #1

    Default Show percent in cfchart legend?

    I would like to show Column Name and percent (like cfchartseries datalabelstyle="pattern") in the legend of my CFMX 7 charts. Any suggestions?
    Sponsored Links
    CAESoit Guest

  2. #2

    Default Re: Show percent in cfchart legend?

    The short answer is that you cannot do this right now due to a bug in CF.

    http://www.macromedia.com/cfusion/webforums/forum/messageview.cfm?catid=3&thread
    id=1022929, CF pie chart legends are VERY poorly executed.

    Anyway create the file, "PercentLegend.xml" using the attached text.
    If you paste this XML into Webcharts designer, you will see that it does what
    you want.

    However, when you add style="PercentLegend.xml" to your <cfchart> tag, you'll
    see that the pie slice labels are nice but the legend ignored the pattern.

    Cheers,
    -- MikeR


    **** Save the following text as "PercentLegend.xml". ****
    <?xml version="1.0" encoding="UTF-8"?>
    <pieChart depth="Double" style="Solid">
    <axis type="Category" />
    <dataLabels style="Pattern" placement="Inside" background="#FFF9BE"
    isAntialiased="true"
    font="Dialog-11" foreground="black">
    <decoration style="ThinRound" foreColor="#CCCCCC"
    backColor="#FFF9BE"/>
    <![CDATA[$(colLabel): $(value)\n$(colPercent) of $(colTotal)]]>
    </dataLabels>
    <legend>
    <![CDATA[$(colLabel) ($(colPercent))]]>
    </legend>
    </pieChart>
    **** "PercentLegend.xml" ended just above this line. ****

    MikerRoo Guest

  3. #3

    Default Re: Show percent in cfchart legend?

    Thanks for the tip - I did report it to Macromedia.

    sherri
    CAESoit Guest

Similar Threads

  1. why the legend can`t be shown?
    By jinnaluo in forum Macromedia Flex General Discussion
    Replies: 1
    Last Post: December 14th, 07:33 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not 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