close
question:
IShellItem GetDisplayName NULL,
RPC_E_WRONG_THREAD The application called an interface that was marshalled for a different thread.
IShellItem* psiResult;
PWSTR pszFilePath = NULL;
hr = psiResult->GetDisplayName(SIGDN_FILESYSPATH, &pszFilePath);
SOL:
因為這段CDialogEventHandler 寫在獨立的.cpp file 導致此問題,所以需到這段code裡取得 GetDisplayName,再回傳
CDialogEventHandler_CreateInstance(REFIID riid, void** ppv)
{
*ppv = NULL;
pDialogEventHandler = new CDialogEventHandler();
...
文章標籤
全站熱搜
留言列表