- hr = ((IDispatch*)m_dispatchPtr)->GetIDsOfNames(IID_NULL, argNames,
- 1 + namedArgCount, LOCALE_SYSTEM_DEFAULT, dispIds);
+ hr = ((IDispatch*)m_dispatchPtr)->GetIDsOfNames(IID_NULL,
+ // We rely on the fact that wxBasicString is
+ // just BSTR with some methods here.
+ reinterpret_cast<BSTR *>(&argNames[0]),
+ 1 + namedArgCount, m_lcid, &dispIds[0]);