Discussion:
How to Get IFileDialog interface for office save-as/open dialogs.
(too old to reply)
Jomerce
2010-05-25 04:02:34 UTC
Permalink
Raw Message
Hi,

My NSE integrates with office and other applications save-as/open
dialogs. I want to catch "save" and "open" button commands of these
dialogs. For this I am trying to access IFileDialog interface. This is
what I tried

IFileDialog *pfv = NULL;
CComPtr<IServiceProvider> spServiceProvider;
m_pShellBrowser->QueryInterface(&spServiceProvider);
if (SUCCEEDED(hr1))
{
hr1 = spServiceProvider-
QueryService(SID_SCommDlgBrowser,IID_PPV_ARGS(&pfv));
if (SUCCEEDED(hr1))
{
pfv->Release();
}
}
Jomerce
2010-05-25 04:04:35 UTC
Permalink
Raw Message
Post by Jomerce
Hi,
My NSE integrates with office and other applications save-as/open
dialogs. I want to catch "save" and "open" button commands of these
dialogs. For this I am trying to access IFileDialog interface. This is
what I tried
        IFileDialog *pfv = NULL;
        CComPtr<IServiceProvider> spServiceProvider;
 HRESULT hr1 = m_pShellBrowser->QueryInterface(&spServiceProvider);
        if (SUCCEEDED(hr1))
        {
                hr1 = spServiceProvider->QueryService(SID_SCommDlgBrowser,IID_PPV_ARGS(&pfv));
                if (SUCCEEDED(hr1))
                {
                        pfv->Release();
                }
        }
Hi,

I am sorry, the post got saved before I complete. Above code returns
E_NOINTERFACE. Any help on this?


Thak you,
Jomerce

Loading...