swap->GetAddInObject(_T("Solidworks.Simulation.5"),&imObject); will give you simulation interface(ICosworks Object)
See the c++ code snippet below
swap->GetAddInObject(_T("Solidworks.Simulation.5"),&imObject);
CComPtr pCWAddin = NULL;
CComPtr pCWApp = NULL;
CComPtr pCWDoc = NULL;
(addin->QueryInterface(__uuidof(ICwAddincallback), (void **) &pCWAddin) != S_OK)
break;
pCWAddin->get_CosmosWorks(&pCWApp);
Thank you
swap->GetAddInObject(_T("Solidworks.Simulation.5"),&imObject); will give you simulation interface(ICosworks Object)
See the c++ code snippet below
swap->GetAddInObject(_T("Solidworks.Simulation.5"),&imObject);
CComPtr pCWAddin = NULL;
CComPtr pCWApp = NULL;
CComPtr pCWDoc = NULL;
(addin->QueryInterface(__uuidof(ICwAddincallback), (void **) &pCWAddin) != S_OK)
break;
pCWAddin->get_CosmosWorks(&pCWApp);
Thank you