Suchergebnisse

Suchergebnisse 1-2 von insgesamt 2.

  • Benutzer-Avatarbild

    Speziell für HRESULT beim DLLImport kannst du auch einfach void als Rückgabetyp setzen und dann PreserveSig auf False stellen: DllImportAttribute.PreserveSig-Feld​ Zitat: „​When you set the PreserveSig field to false, the resulting method signature contains a void return type instead of an integer (HRESULT) return type. When the unmanaged method produces an HRESULT, the runtime automatically ignores a return value of S_OK (or 0) and does not throw an exception. For HRESULTs other than S_OK, the …

  • Benutzer-Avatarbild

    Das ist ein Auszug der Implementierung im .Net Framework.