See the question and my original answer on StackOverflow

There is only one IDispatch implementation per COM object, so if you want a call such as IDispatch::Invoke to succeed, you need to have DISPIDs unique per COM object.

EDIT: In fact, after thinking more about it, the question is quite irrelevant, as Hans points out in his comment. Because you define ClassInterfaceType as None, it means .NET will only make the first interface IMyInterface1 dispids usable (by default, but you can configure the default interface using the ComDefaultInterfaceAttribute Class attribute).

And if you use ClassInterfaceType as AutoDual or AutoDispatch, DISPIDs will be auto generated, and the one defined manually will not be used.

.NET does not combine or merge the interfaces, and the fact that the dispids are different is therefore not important in this ".NET exposed as COM" case, as only one set of DISPIDs are used (for the default interface). Note if you define twice the same set of DISPIDs on the same class, it will compile fine, but regasm will complain and ignore the duplicate ones.

Here is a small C++ program that confirms all this:

int _tmain(int argc, _TCHAR* argv[])
{
    CoInitialize(NULL);
    IDispatch *pDispatch;
    CoCreateInstance(__uuidof(MyClass), NULL, CLSCTX_ALL, IID_IDispatch, (void**)&pDispatch);
    DISPID dispid;
    LPOLESTR name1 = L"Name1";
    LPOLESTR name2 = L"Name2";
    HRESULT hr;
    hr = pDispatch->GetIDsOfNames(IID_NULL, &name1, 1, 0, &dispid);
    printf("Name1:%i hr=0x%08X\n", dispid, hr);
    hr = pDispatch->GetIDsOfNames(IID_NULL, &name2, 1, 0, &dispid);
    printf("Name2:%i hr=0x%08X\n", dispid, hr);
    pDispatch->Release();
    CoUninitialize();
    return 0;
}

It will output this:

Name1:1 hr=0x00000000 (S_OK)
Name2:-1 hr=0x80020006 (DISP_E_UNKNOWNNAME)

It you change to AutoDispatch or AutoDual, it will output this (ids are calculated using some algorithm):

Name1:1610743812 hr=0x00000000
Name2:1610743813 hr=0x00000000