Jump to content
Software FX Community

Chartfx Cleint server returns exception


Samaya

Recommended Posts

Hi!

I am the new user of ChartFx Client server control.

I have installed ChartFx Cleint Server 5.1 on my PC(Licenced version), now i am trying to write small MFC Dialog based application using Visual Studio 2005.

I have registered "Cfx4032.ocx" and "sfxbar.dll" in my PC. and added the import directives as below - this is mentioned in ChartFx's programer guide.

In your precompiled header (STDAFX.H)

// DEFINITION of COM wrappers

#import "sfxbar.dll" no_namespace no_implementation

#import "Cfx4032.ocx" no_namespace no_implementation

In your implementation (STDAFX.CPP)

// IMPLEMENTATION of COM wrappers

#import "sfxbar.dll" no_namespace implementation_only

#import "Cfx4032.ocx" no_namespace implementation_only

 

I am trying to run the sample application given in ChartFx installed folder(Cfx98 project) and this runs very well.

Now i have copied the same code to my VC2005 project and this code compiles well only.

If i run in debug mode, the application throws me an exception. i ahve no clues why thsi execption is ocurring, but my sample project runs fine.

Any response would be of great help.

Thanks,Samaya

Link to comment
Share on other sites

Hello Thanks for your response!

I have posted the code snippet below:

I have craeted the pointer to the ChartControl  as below - This is as given in the ChartFX Programmers guide.

This code in my dialog header file

CWnd m_ChartFX1;

IChartFXPtr m_pChartFX1;

In my DDX function i have the below code:

DDX_Control(pDX, IDC_CHART1, m_ChartFX1);

if (!pDX->m_bSaveAndValidate) { // Link Chart FX pointer to control window

m_pChartFX1 = m_ChartFX1.GetControlUnknown();

}

 

Then i use m_pChartFX1 to call teh Chart control functions.

Thanks.

 

WebSite27.zip

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...