private static ICLRMetaHost CreateClrMetaHost() { object pClrMetaHost; HResult result = CLRCreateInstance(CLSID_CLRMetaHost, typeof(ICLRMetaHost).GUID, out pClrMetaHost); result.ThrowOnFailure(); return((ICLRMetaHost)pClrMetaHost); }
public void Flush() { HResult hr = DwmFlush(); // Accept success, or "Desktop composition is disabled". if (hr != 0x80263001) { hr.ThrowOnFailure(); } }