[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

microsoft.public.axapta.programming

How to use Microsoft Chart 6.0 in Axapta ?

Dave

12/1/2005 9:38:00 AM

Hi All,
In order to create a chart in axapta form, report. I've tried to use
Microsoft Chart 6.0 ActiveX Control.
Anyone have a sample code to do that ? please send me a copy. thanks in
advance

for more infomation :
The control have many many properties, method, event to manipula the chart,
but the problem is the DataSource of the chart.
The control have method :
eg : active.DataSource, active.DataMember, active.DataSourceType, I guess
these method is used to set the Datasource for the chart, however, the
DataSource method require a COM object parameter.
The question is : How a COM object which required ? from Array, container,
int ... ?
3 Answers

Nitin

12/7/2005 11:21:00 AM

0

Hi,

You can pass the data using the active.ChartData() method. In which we need
to pass a COMVaraiant.

COMVariant sc = new COMVariant();
;
sc.variantType(COMVariantType::VT_VARIANT);

sc.container([
["Company", "Company A", "Company B", "Company c",
"Company d"],
["Jan", 20, 100, 123, 222],
["Feb", 20, 100, 223, 322],
["March", 20, 100 ,22,22],
["April", 20, 100,22,22],
["June", 20, 100,233,333],
["July", 10, 15,333,33],
["August", 30, 15,345,55],
["September", 14, 17,34,43]
]);

this.ChartData(sc);


But the chart is not coming correctly. I will try to spend some more time to
complete it. I think it may help u to proceed.

Let me know also once u complete it.

Thanks
Nitin Jain
"Vy" wrote:

> Hi All,
> In order to create a chart in axapta form, report. I've tried to use
> Microsoft Chart 6.0 ActiveX Control.
> Anyone have a sample code to do that ? please send me a copy. thanks in
> advance
>
> for more infomation :
> The control have many many properties, method, event to manipula the chart,
> but the problem is the DataSource of the chart.
> The control have method :
> eg : active.DataSource, active.DataMember, active.DataSourceType, I guess
> these method is used to set the Datasource for the chart, however, the
> DataSource method require a COM object parameter.
> The question is : How a COM object which required ? from Array, container,
> int ... ?

Dave

12/12/2005 8:59:00 AM

0

Hi Nitin,
thanks a lot ,I tried your way, but the chart is shown incorectly, then, I
even tried to rem the line : active.chartData(). The chart still show, but,
of course, the data is incorect.
So, I think, it take the default value to make the chart, do you think so ?

"Nitin" wrote:

> Hi,
>
> You can pass the data using the active.ChartData() method. In which we need
> to pass a COMVaraiant.
>
> COMVariant sc = new COMVariant();
> ;
> sc.variantType(COMVariantType::VT_VARIANT);
>
> sc.container([
> ["Company", "Company A", "Company B", "Company c",
> "Company d"],
> ["Jan", 20, 100, 123, 222],
> ["Feb", 20, 100, 223, 322],
> ["March", 20, 100 ,22,22],
> ["April", 20, 100,22,22],
> ["June", 20, 100,233,333],
> ["July", 10, 15,333,33],
> ["August", 30, 15,345,55],
> ["September", 14, 17,34,43]
> ]);
>
> this.ChartData(sc);
>
>
> But the chart is not coming correctly. I will try to spend some more time to
> complete it. I think it may help u to proceed.
>
> Let me know also once u complete it.
>
> Thanks
> Nitin Jain
> "Vy" wrote:
>
> > Hi All,
> > In order to create a chart in axapta form, report. I've tried to use
> > Microsoft Chart 6.0 ActiveX Control.
> > Anyone have a sample code to do that ? please send me a copy. thanks in
> > advance
> >
> > for more infomation :
> > The control have many many properties, method, event to manipula the chart,
> > but the problem is the DataSource of the chart.
> > The control have method :
> > eg : active.DataSource, active.DataMember, active.DataSourceType, I guess
> > these method is used to set the Datasource for the chart, however, the
> > DataSource method require a COM object parameter.
> > The question is : How a COM object which required ? from Array, container,
> > int ... ?

Nitin

12/12/2005 11:02:00 AM

0

Hi Vy,

It seems that there is something more that we are missing, I am trying on
it. If I got something new that I will let u know.

Thanks
Nitin

"Vy" wrote:

> Hi Nitin,
> thanks a lot ,I tried your way, but the chart is shown incorectly, then, I
> even tried to rem the line : active.chartData(). The chart still show, but,
> of course, the data is incorect.
> So, I think, it take the default value to make the chart, do you think so ?
>
> "Nitin" wrote:
>
> > Hi,
> >
> > You can pass the data using the active.ChartData() method. In which we need
> > to pass a COMVaraiant.
> >
> > COMVariant sc = new COMVariant();
> > ;
> > sc.variantType(COMVariantType::VT_VARIANT);
> >
> > sc.container([
> > ["Company", "Company A", "Company B", "Company c",
> > "Company d"],
> > ["Jan", 20, 100, 123, 222],
> > ["Feb", 20, 100, 223, 322],
> > ["March", 20, 100 ,22,22],
> > ["April", 20, 100,22,22],
> > ["June", 20, 100,233,333],
> > ["July", 10, 15,333,33],
> > ["August", 30, 15,345,55],
> > ["September", 14, 17,34,43]
> > ]);
> >
> > this.ChartData(sc);
> >
> >
> > But the chart is not coming correctly. I will try to spend some more time to
> > complete it. I think it may help u to proceed.
> >
> > Let me know also once u complete it.
> >
> > Thanks
> > Nitin Jain
> > "Vy" wrote:
> >
> > > Hi All,
> > > In order to create a chart in axapta form, report. I've tried to use
> > > Microsoft Chart 6.0 ActiveX Control.
> > > Anyone have a sample code to do that ? please send me a copy. thanks in
> > > advance
> > >
> > > for more infomation :
> > > The control have many many properties, method, event to manipula the chart,
> > > but the problem is the DataSource of the chart.
> > > The control have method :
> > > eg : active.DataSource, active.DataMember, active.DataSourceType, I guess
> > > these method is used to set the Datasource for the chart, however, the
> > > DataSource method require a COM object parameter.
> > > The question is : How a COM object which required ? from Array, container,
> > > int ... ?