an89 wrote:
InitializeWMI(); const BSTR ClassName = SysAllocString(L"Win32_NetworkAdapterConfiguration"); const BSTR AdapterName = SysAllocString(ADAPTER_INDEX); const BSTR MethodName = SysAllocString(L"EnableStatic"); IWbemClassObject* pClassObj = NULL; IWbemClassObject* pInClass = NULL; IWbemClassObject* pInInstClass = NULL; IWbemServices *pSvc = NULL ; LONG index[1]={0}; HRESULT hr = pSvc->GetObject(ClassName,0,NULL,&pClassObj,NULL);///at this point its showing unhandled exception
Well, for starters it looks like pSvc is still NULL so that would cause the exception... Peace!
-=- James
Please rate this message - let me know if I helped or not! * * * If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong!
Remember that Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road!
See DeleteFXPFiles