コード例 #1
0
        public static IAsyncOperation <bool> ShowPrintUIForWindowAsync(IntPtr hWnd)
        {
            Guid iid = InteropHelper.GetIID <IAsyncOperation <bool> >();
            IPrintManagerInterop factory = InteropHelper.GetActivationFactory <IPrintManagerInterop>(typeof(PrintManager));

            return(factory.ShowPrintUIForWindowAsync(hWnd, ref iid));
        }
コード例 #2
0
        public static IAsyncOperation <bool> ShowPrintUIForWindowAsync(IntPtr hWnd)
        {
            IPrintManagerInterop printManagerInterop = (IPrintManagerInterop)WindowsRuntimeMarshal.GetActivationFactory(typeof(PrintManager));
            Guid guid = typeof(IAsyncOperation <bool>).GUID;

            return(printManagerInterop.ShowPrintUIForWindowAsync(hWnd, ref guid));
        }
コード例 #3
0
        public static PrintManager GetForWindow(IntPtr hWnd)
        {
            Guid iid = InteropHelper.GetIID <PrintManager>();
            IPrintManagerInterop factory = InteropHelper.GetActivationFactory <IPrintManagerInterop>(typeof(PrintManager));

            return(factory.GetForWindow(hWnd, ref iid));
        }
コード例 #4
0
        public static PrintManager GetForWindow(IntPtr hWnd)
        {
            IPrintManagerInterop printManagerInterop = (IPrintManagerInterop)WindowsRuntimeMarshal.GetActivationFactory(typeof(PrintManager));
            Guid guid = typeof(PrintManager).GetInterface("IPrintManager").GUID;

            return(printManagerInterop.GetForWindow(hWnd, ref guid));
        }