E_NOINTERFACE

Hi,
I am using StgOpenStorageEx to open a file but it gives me the error
E_NOINTERFACE.

below is the code snippet

LpStorage lpstor;
IPropertySetStorage* pPropSetStg = NULL;//TEMPJAI


DWORD dw = StgOpenStorageEx(L"C:\\ETools\\Power Generation\\Shared\\Data\\AllCtrl.dfa", STGM_READ | STGM_SHARE_DENY_WRITE, STGFMT_FILE, 0, 0, 0, IID_IStorage, reinterpret_cast<void**>(&pPropSetStg));

I just want to know what is wrong with this code.

Doubt this is your problem, but all COM functions return HRESULTs - not DWORDs. Its been quite a while since I've worked with structured storage, and when I did I was likely using StgOpenStorage(). Without looking into it any further, my guess would be to examine and play around with the enumeration parameters, i.e., specifically the 2nd and 3rd ones, and also the ones where you are passing in zeros.
Topic archived. No new replies allowed.