Sign in to follow this  
Gondrong

Using FC v3

Recommended Posts

Hi, I'm new to FC and XML so I need help very much. First of all I have this case that in previous (before using FC + XML) I use another chart lib and JSON for conectivity with DB. I try use FC with ExtJS 2.2 framework now. Now I want to know how can I make the case happen again using FC and XML.

 

 

 

The case is explained in here. I just need to know how XML should look like and how to parse it in the JS file. If the JS code is needed I will be very happy to show it to.

 

 

 

Thanks.

Share this post


Link to post
Share on other sites

Hi,

Let me show you how you would need to build the XML from the 2 filtered data samples:

You would need to use MSColumn2D.swf chart file for this, build the XML and pass it to the chart.

This is your sample data:

cd [PK]   | subject_name | lecture_score | subject_score | academicyear | term

1     | Management | 80 | 70 | 2007/2008 | 1

2     | Business   | 60 | 60 | 2007/2008 | 1

3     | Algorithm | 70 | 70 | 2007/2008 | 2

4     | CRM | 85 | 70 | 2007/2008 | 2

5     | ERP   | 90 | 80 | 2008/2009 | 1

6     | English   | 100 | 90 | 2008/2009 | 1

7     | Religion   | 90 | 75 | 2008/2009 | 1

1. When the options chosen are : 2007/2008 academic year and 2nd term

<chart>

<categories>

  <category label='Algorithm' />

  <category label='CRM' />

  </categories>

  <dataset seriesName='lecture_score ' >

  <set value='70' />

  <set value='85' />

  </dataset>

  <dataset seriesName='subject_score' >

  <set value='70' /> 

  <set value='70' />

  </dataset>

</chart>

-------------------------------------------------------

2.When the options chosen are :2008/2009 academic year and 1st term

<chart>

<categories>

  <category label='ERP'/>

  <category label='English'/>

  <category label='Religion'/>

  </categories>

  <dataset seriesName='lecture_score ' >

  <set value='90' />

  <set value='100' />

  <set value='90' />

  </dataset>

  <dataset seriesName='subject_score' >

  <set value='80' />

  <set value='90' />

  <set value='75' />

  </dataset>

</chart>

Edited by Guest

Share this post


Link to post
Share on other sites

So basically I need two XML for this correct? one each for 2007/2008 academic year and 2nd term, 2007/2008 academic year and 1nd term, 2008/2009 academic year and 1st term.

 

 

 

Thanks for the reply.

Share this post


Link to post
Share on other sites

One thing, is it possible to make it in one file? i mean the xml with the above data. If can, how will the xml look like (this must be in one xml file)?

 

 

 

Sorry for too many question.

 

 

 

Thanks.

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