Jump to content
Software FX Community

Customizing the "Properties" Property Pages


User (Legacy)
 Share

Recommended Posts

Hi All,

In my implementation of Chart FX I can't allow the user to choose any color

they want. Instead they can only choose from a set of predefined colors.

To make this happen I need to customize the property pages that come up when

the user chooses Properties... Is there a way to do this? I thought of

making my own set of property pages appear instead but I would like the 3D

page to appear also. Trying to make my own version of that would be

difficult. Is there a way to add that page to my own? Any ideas?

Thanks,

Ben

Link to comment
Share on other sites

Thanks for the responce.  I assume you mean IPropertyPages instead.  I

couldn't find anything on ISuppertPropertyPages. Using what I found in MSDN

and on the web I've written this code. But it causes an unhandled expection

error in the CFX4032.dll when I make the call to OleCreatePropertyFrame().

I'm using the trial version of ChartFX and I was wondering if that was the

problem. Can you find anything wrong with this code? m_pChartFX is a

IChartFXPtr.

Thanks,

Ben

void CChartTestDlg::OnButton1()

{

HRESULT hr;

CAUUID pages;

CComPtr<IPropertyPage> pPropertyPage;

CString csTitle = "Title";

CComPtr<ISpecifyPropertyPages> pStockPage;

hr = m_pChartFX->QueryInterface(IID_ISpecifyPropertyPages, (void

**)&pStockPage);

if (SUCCEEDED(hr))

hr = pStockPage->GetPages(&pages);

if (SUCCEEDED(hr))

hr = OleCreatePropertyFrame(GetSafeHwnd(), 0, 0, csTitle.AllocSysString(),

1, (IUnknown**)&m_pChartFX, pages.cElems, pages.pElems, 0L, 0L, NULL);

}

"Software FX Support" <frankp@softwarefx.com> wrote in message

news:3YXuWjF0BHA.2804@webserver1.softwarefx.com...

> Chart FX Supports ISupportProperty Pages, you can ask for this interface,

> retrieve the pages you need and add them to your property own frame.

>

> ISupportPropertyPages is a standard COM Interface.

>

> --

> FP

> Software FX, Inc.

>

>

>

Link to comment
Share on other sites

I figured it out.

Thanks,

Ben

"Ben Macri" <bmacri@docucorp.com> wrote in message

news:d3OSvhb0BHA.2108@webserver1.softwarefx.com...

> Thanks for the responce. I assume you mean IPropertyPages instead. I

> couldn't find anything on ISuppertPropertyPages. Using what I found in

MSDN

> and on the web I've written this code. But it causes an unhandled

expection

> error in the CFX4032.dll when I make the call to OleCreatePropertyFrame().

> I'm using the trial version of ChartFX and I was wondering if that was the

> problem. Can you find anything wrong with this code? m_pChartFX is a

> IChartFXPtr.

>

> Thanks,

> Ben

>

> void CChartTestDlg::OnButton1()

> {

> HRESULT hr;

> CAUUID pages;

> CComPtr<IPropertyPage> pPropertyPage;

> CString csTitle = "Title";

>

> CComPtr<ISpecifyPropertyPages> pStockPage;

> hr = m_pChartFX->QueryInterface(IID_ISpecifyPropertyPages, (void

> **)&pStockPage);

>

> if (SUCCEEDED(hr))

> hr = pStockPage->GetPages(&pages);

>

> if (SUCCEEDED(hr))

> hr = OleCreatePropertyFrame(GetSafeHwnd(), 0, 0,

csTitle.AllocSysString(),

> 1, (IUnknown**)&m_pChartFX, pages.cElems, pages.pElems, 0L, 0L, NULL);

> }

>

> "Software FX Support" <frankp@softwarefx.com> wrote in message

> news:3YXuWjF0BHA.2804@webserver1.softwarefx.com...

> > Chart FX Supports ISupportProperty Pages, you can ask for this

interface,

> > retrieve the pages you need and add them to your property own frame.

> >

> > ISupportPropertyPages is a standard COM Interface.

> >

> > --

> > FP

> > Software FX, Inc.

> >

> >

> >

>

>

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.

 Share

×
×
  • Create New...