public static unsafe void StringToHStringReference(
 char* pchPinnedSourceString,
 string sourceString,
 HSTRING_HEADER* pHeader,
 HSTRING* phString)
 {
     throw new PlatformNotSupportedException("StringToHStringReference");
 }
Exemplo n.º 2
0
        public static unsafe void StringToHStringReference(
            char* pchPinnedSourceString,
            string sourceString,
            HSTRING_HEADER* pHeader,
            HSTRING* phString)
        {
            if (sourceString == null)
                throw new ArgumentNullException("sourceString", SR.Null_HString);

            int hr = ExternalInterop.WindowsCreateStringReference(
                pchPinnedSourceString,
                (uint)sourceString.Length,
                pHeader,
                (void**)phString);

            if (hr < 0)
                throw Marshal.GetExceptionForHR(hr);
        }
Exemplo n.º 3
0
 internal static extern unsafe int WindowsCreateStringReference(
     char* sourceString, uint length, HSTRING_HEADER* phstringHeader, void* hstring);