int OleInterop.IDataObject.GetCanonicalFormatEtc(OleInterop.FORMATETC[] pformatectIn, OleInterop.FORMATETC[] pformatetcOut) { if (null != oleData) { return(oleData.GetCanonicalFormatEtc(pformatectIn, pformatetcOut)); } // Check that the arrays are not null and with only one element. if ((null == pformatectIn) || (pformatectIn.Length != 1) || (null == pformatetcOut) || (pformatetcOut.Length != 1)) { throw new ArgumentException(); } BclComTypes.FORMATETC bclFormatIn = StructConverter.OleFormatETC2Bcl(ref pformatectIn[0]); BclComTypes.FORMATETC bclFormatOut; int hr = bclData.GetCanonicalFormatEtc(ref bclFormatIn, out bclFormatOut); NativeMethods.ThrowOnFailure(hr); pformatetcOut[0] = StructConverter.BclFormatETC2Ole(ref bclFormatOut); return(hr); }