Sign in to follow this  
king satti

Show Yaxis Value Against Vertical Div Line Values Using Line Chart

Recommended Posts

I want to show the values according to the vertical div line valuse and the values come on the xaxis are dynamic .

i am using the php classes for all this.

Is it possible?

the code i m using is

 

 

# Include FusionCharts PHP Class

include('fusion/FusionCharts_Gen.php');

// height chart

$FC = new FusionCharts("Line","612","792");

$charts_path = $this->webroot."charts/";

$FC->setSWFPath($charts_path);

$FC->addColors("FF3300");

if($getdate < 20 && $patdata[0]['Patient']['sex'] == 'M'){

$bgimg = $this->webroot."chartimg/growth-2-20-boys.jpg";

$strParam=" shownames=0;showLimits=0;showDivLineValue=0;showvalues=1;showLegend=1;xAxisMaxValue = 20;xAxisMinValue =2;numVDivLines=17;vDivLineColor=ff3300;yAxisMaxvalue=200; yAxisMinvalue=75; adjustDiv = 1; numDivLines=24;formatNumberScale=0;showConvasBorder=0 ;bgSWF=$bgimg; canvasBgAlpha=1 ;bgSWFAlpha=40; AlternateHGridColor=ff5904; divLineColor=FF3300; divLineAlpha=20; chartLeftMargin=113; chartTopMargin=119;chartBottomMargin=98;chartRightMargin=81; alternateHGridAlpha=5;canvasBorderThickness=0;divLineThickness=3;vdivLineThickness=3";

 

 

$FC->setChartParams($strParam);

foreach($data as $key=>$val){

 

$datediff = date("Y-m-d",strtotime($val['PatientExamine']['dos'])) - date("Y-m-d",strtotime($patdata[0]['Patient']['DOB']));

$height=$val['PatientExamine']['height'];

$date = date("Y-m-d",strtotime($val['PatientExamine']['dos']));

$FC->addChartData($height);

 

}

$FC->renderChart();

}

 

thanx.

Share this post


Link to post
Share on other sites
Guest Angie

Hi,

 

Welcome to FusionCharts Forum!smile.gif

 

Could you please let us know the way you want to show vertical div line values?

 

We have found from the code that <numDivLines> has been set to 17.

 

Would you like to set the vertical div line values according to the data provided by chart?

 

Please clarify your query.

 

Awaiting for your feedback.

Share this post


Link to post
Share on other sites

Hi,

i have numVDivLines=17 and i have a value on y axis (i.e 23) and x axis value(i.e 4). now i want to show these value within these numdivline. now how this will be managed.

Hi,

 

Welcome to FusionCharts Forum!smile.gif

 

Could you please let us know the way you want to show vertical div line values?

 

We have found from the code that <numDivLines> has been set to 17.

 

Would you like to set the vertical div line values according to the data provided by chart?

 

Please clarify your query.

 

Awaiting for your feedback.

Share this post


Link to post
Share on other sites

yes i want to show the div line values according to the data provided by the chart .

thanx

Hi,

 

Welcome to FusionCharts Forum!smile.gif

 

Could you please let us know the way you want to show vertical div line values?

 

We have found from the code that <numDivLines> has been set to 17.

 

Would you like to set the vertical div line values according to the data provided by chart?

 

Please clarify your query.

 

Awaiting for your feedback.

Share this post


Link to post
Share on other sites
Guest Angie

Hi,

 

Thank you very much for your valuable feedback.

 

Please find attached a sample workaround to suffice your requirement.

 

Hope this helps.smile.gif

vdivline.xml

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this