private void GetAudioSessionManager() { object result; Marshal.ThrowExceptionForHR(_RealDevice.Activate(ref IID_IAudioSessionManager, CLSCTX.ALL, IntPtr.Zero, out result)); _AudioSessionManager = new AudioSessionManager(result as IAudioSessionManager2); }