This is the actual state:
In idl file:
Code:
interface IProblem : IDispatch{
[propget, id(1)] HRESULT miProblema([out, retval] ISolver** pVal);
[propput, id(1)] HRESULT miProblema([in] ISolver* newVal);
};
Definition in private section of Problem.h:
Code:
CComObject<CSolver> *pProblema;
Constructor:
Code:
CProblem()
{ // THIS RUNS
HRESULT hRes = CComObject<CSolver>::CreateInstance(&pProblema);
ATLASSERT(SUCCEEDED(hRes));
pProblema->AddRef();
}
Definition:
Code:
STDMETHODIMP CProblem::get_miProblema(ISolver** pVal)
{
// THIS RUNS!!
pProblema->QueryInterface(IID_ISolver, (void**)pVal);
return S_OK;
}
STDMETHODIMP CProblem::put_miProblema(ISolver* newVal)
{
// I DON'T KNOW HOW TO DO THIS
return S_OK;
}