By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,846 Members | 1,554 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,846 IT Pros & Developers. It's quick & easy.

Adding MSChart to a windows forms project

P: n/a
I don't know any thing about c#, I really need to do this in visual c++. I
don't manually wrap the dll but since it's called AxInterop.OWC10.dll I
assume visual studio has done that for me.

"Steve Alpert" wrote:
Richard wrote:
I have Visual C++ .net 2003 and am trying to add a chart to a form. When I
try and use MSChart or any other of the activeX controls (ie MS Calendar) I
get an error message saying that it can't find a dll file but if I look in
the debug directory of the project file it's there.

Some help please. Or an other way of adding charts to my application that
doesn't involve complicated coding or buying 3rd party software.


Are you using the InterOp to wrap the DLL? You can't just add an
ActiveX DLL to a C# project...

/steveA

--
Steve Alpert
my email Fgrir_Nycreg @ vqk.pbz is encrypted with ROT13 (www.rot13.org)
and spaces


Nov 17 '05 #1
Share this Question
Share on Google+
5 Replies


P: n/a
Richard wrote:
I don't know any thing about c#, I really need to do this in visual c++. I
don't manually wrap the dll but since it's called AxInterop.OWC10.dll I
assume visual studio has done that for me.

"Steve Alpert" wrote:

Richard wrote:
I have Visual C++ .net 2003 and am trying to add a chart to a form. When I
try and use MSChart or any other of the activeX controls (ie MS Calendar) I
get an error message saying that it can't find a dll file but if I look in
the debug directory of the project file it's there.

Some help please. Or an other way of adding charts to my application that
doesn't involve complicated coding or buying 3rd party software.


Are you using the InterOp to wrap the DLL? You can't just add an
ActiveX DLL to a C# project...


I created a new project (C++ managed, window form). I then did an add
reference, surfed to c:\windows\system32\mschart.ocx and added it. It
appears as MSChartLib in the reference list.

Add:
using namespace Interop::MSChartLib;

and finally

MSChart * chart; // com ChartClass

/steveA

--
Steve Alpert
my email Fgrir_Nycreg @ vqk.pbz is encrypted with ROT13 (www.rot13.org)
and spaces

Nov 17 '05 #2

P: n/a
I've searched my whole computer and I can't find the file mschart.ocx, how do
I get it?

"Steve Alpert" wrote:
Richard wrote:
I don't know any thing about c#, I really need to do this in visual c++. I
don't manually wrap the dll but since it's called AxInterop.OWC10.dll I
assume visual studio has done that for me.

"Steve Alpert" wrote:

Richard wrote:

I have Visual C++ .net 2003 and am trying to add a chart to a form. When I
try and use MSChart or any other of the activeX controls (ie MS Calendar) I
get an error message saying that it can't find a dll file but if I look in
the debug directory of the project file it's there.

Some help please. Or an other way of adding charts to my application that
doesn't involve complicated coding or buying 3rd party software.

Are you using the InterOp to wrap the DLL? You can't just add an
ActiveX DLL to a C# project...


I created a new project (C++ managed, window form). I then did an add
reference, surfed to c:\windows\system32\mschart.ocx and added it. It
appears as MSChartLib in the reference list.

Add:
using namespace Interop::MSChartLib;

and finally

MSChart * chart; // com ChartClass

/steveA

--
Steve Alpert
my email Fgrir_Nycreg @ vqk.pbz is encrypted with ROT13 (www.rot13.org)
and spaces

Nov 17 '05 #3

P: n/a
dunno.... I just did a search "dir/s" from c:\windows and there it was.
Guess you're on your own on that one..

/steveA

Richard wrote:
I've searched my whole computer and I can't find the file mschart.ocx, how do
I get it?

"Steve Alpert" wrote:

Richard wrote:
I don't know any thing about c#, I really need to do this in visual c++. I
don't manually wrap the dll but since it's called AxInterop.OWC10.dll I
assume visual studio has done that for me.

"Steve Alpert" wrote:

Richard wrote:
>I have Visual C++ .net 2003 and am trying to add a chart to a form. When I
>try and use MSChart or any other of the activeX controls (ie MS Calendar) I
>get an error message saying that it can't find a dll file but if I look in
>the debug directory of the project file it's there.
>
>Some help please. Or an other way of adding charts to my application that
>doesn't involve complicated coding or buying 3rd party software.

Are you using the InterOp to wrap the DLL? You can't just add an
ActiveX DLL to a C# project...


I created a new project (C++ managed, window form). I then did an add
reference, surfed to c:\windows\system32\mschart.ocx and added it. It
appears as MSChartLib in the reference list.

Add:
using namespace Interop::MSChartLib;

and finally

MSChart * chart; // com ChartClass

/steveA

--
Steve Alpert
my email Fgrir_Nycreg @ vqk.pbz is encrypted with ROT13 (www.rot13.org)
and spaces

--
Steve Alpert
my email Fgrir_Nycreg @ vqk.pbz is encrypted with ROT13 (www.rot13.org)
and spaces

Nov 17 '05 #4

P: n/a
maybe it comes with office?

/steveA

Richard wrote:
I've searched my whole computer and I can't find the file mschart.ocx, how do
I get it?

"Steve Alpert" wrote:

Richard wrote:
I don't know any thing about c#, I really need to do this in visual c++. I
don't manually wrap the dll but since it's called AxInterop.OWC10.dll I
assume visual studio has done that for me.

"Steve Alpert" wrote:

Richard wrote:
>I have Visual C++ .net 2003 and am trying to add a chart to a form. When I
>try and use MSChart or any other of the activeX controls (ie MS Calendar) I
>get an error message saying that it can't find a dll file but if I look in
>the debug directory of the project file it's there.
>
>Some help please. Or an other way of adding charts to my application that
>doesn't involve complicated coding or buying 3rd party software.

Are you using the InterOp to wrap the DLL? You can't just add an
ActiveX DLL to a C# project...


I created a new project (C++ managed, window form). I then did an add
reference, surfed to c:\windows\system32\mschart.ocx and added it. It
appears as MSChartLib in the reference list.

Add:
using namespace Interop::MSChartLib;

and finally

MSChart * chart; // com ChartClass

/steveA

--
Steve Alpert
my email Fgrir_Nycreg @ vqk.pbz is encrypted with ROT13 (www.rot13.org)
and spaces

--
Steve Alpert
my email Fgrir_Nycreg @ vqk.pbz is encrypted with ROT13 (www.rot13.org)
and spaces

Nov 17 '05 #5

P: n/a
or VB6??

/steveA
Nov 17 '05 #6

This discussion thread is closed

Replies have been disabled for this discussion.