1 Replies - 2240 Views - Last Post: 29 March 2013 - 12:26 PM Rate Topic: -----

#1 vamsc443  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 13
  • Joined: 08-March 13

Problem on creating Charts using CF

Posted 29 March 2013 - 05:37 AM

hi i am trying to build 3D bar chat for 13 items. hear i succeed up to showing my data as Cylinder shape.but if i put cursor on the particular Cylinder (item).it is showing only value not rowLabel(item name)(TYPEOFTREATMENT).

i need to show both

please help me for this


<td colspan="3" align="center" valign="middle"> 				<cfsavecontent variable="modelTreatment">                   <cfoutput>                   <?xml version="1.0" encoding="UTF-8"?>                   <XML type="default">                     <cfloop query="qryTypesOfTreatment">                     <col>                     #TYPEOFTREATMENT#                     </col>                     </cfloop>                     <ROW             <cfloop query="qryTypesOfTreatment"><cfset iRow = currentRow - 1> col#iRow#='#NOOFPATIENTS#'</cfloop>></ROW>                   </XML>                   </cfoutput>                   </cfsavecontent>                   <cfscript>                     context  = getPageContext();                     chart = createObject("java","com.gp.api.jsp.MxServerComponent");                     svr = chart.getDefaultInstance(context.getServletContext());                     myChart        = svr.newImageSpec();                     myChart.width  = 600; 					myChart.height = 250;                     myChart.type   = attributes.chartFormat;                     myChart.style  = BarStackedOnco;                     myChart.model  = modelTreatment;                     chartTag = svr.getImageTag(myChart,"/CFIDE/GraphData.cfm?graphCache=wc50&graphID=");                   </cfscript>                   <cfoutput>#chartTag#</cfoutput>                   <cfsetting enablecfoutputonly="false"/> 				    			   				  </td>


<cfsavecontent variable="BarStackedOnco"> <cfoutput> <frameChart font="Verdana-10">   <frame xDepth="12" yDepth="11" outline="black" wallColor="null" isHStripVisible="true"/>   <xAxis>     <labelStyle  color="black" orientation="Slanted" /> 	<titleStyle font="verdana-10" />   </xAxis>   <yAxis scaleMin="0">     <labelStyle orientation="Slanted" color="black"/>     <titleStyle font="verdana-10" isMultiline="false"/>   </yAxis>   <dataLabels style="Pattern" placement="Inside" font="Verdana-10">     <![CDATA[ $(rowLabel): $(value)\n ]]>   </dataLabels>   <legend allowSpan="true" equalCols="false" isVisible="false" placement="Right" halign="Right"                isMultiline="true">   <decoration style="None"/>   </legend>   <elements place="Stacked" shape="Cylinder" drawOutline="True">     <morph morph="Grow" stage="None"/>     <![CDATA[$(rowLabel):  $(value) ]]>   </elements>   <popup background="white" font="Verdana-10" foreground="black"/>   <decoration style="RoundShadow"/>   <paint palette="DawnTransluent" paint="Plain" isVertical="true" min="47" max="83"/>   <insets right="5"/>   <background minColor="#attributes.backgroundColor#"/> </frameChart> </cfoutput> </cfsavecontent>


Is This A Good Question/Topic? 0
  • +

Replies To: Problem on creating Charts using CF

#2 Craig328  Icon User is offline

  • I make this look good
  • member icon

Reputation: 1947
  • View blog
  • Posts: 3,488
  • Joined: 13-January 08

Re: Problem on creating Charts using CF

Posted 29 March 2013 - 12:26 PM

vamsc443, we may have to have an understanding here. Along with your previous posts and now this one, it's clear you're trying to maintain code that you didn't write, don't understand but apparently don't want to retain someone qualified to work on the issues its presenting you. Allow me to quote myself from a previous thread:

Quote

We here at DIC are more than happy to help our users with issues they encounter but we like to see some effort expended by the user explaining why they came here AFTER their efforts failed. So, what have you tried to fix this so far? If you're not a developer, perhaps consider contacting a local CF dev who can look at your issue for you.


What you have here isn't a problem you've tried to solve...it's just a problem for you because you're not a CF dev, don't want to retain a competent CF dev to do this work and believe that bringing here, dumping it in a heap and asking "please help me for this" substitutes for having a capable professional troubleshoot and fix these problems.

It does not.

What I will do is to tell you that the code you've posted here is an outdated version of leveraging the Java platform that underlies the CF engine to display a chart. It's outdated because CF now features a CFCHART and has since the CFMX days (since mid 2002). What I'll suggest you do is try and replace the code generating the chart that invokes the object from the Java stack and replace it with a similar CFCHART and see what you can get that to do. The link I provided should be a good starting point for you to actually learn how to do this rather than try and get somebody to do CF development work for you for free.

If you do make the attempt and it's not working, feel free to open a new thread for this with that issue because I'm closing this one.

Good luck!
Was This Post Helpful? 1
  • +
  • -

Page 1 of 1