private SHShowManageLibraryUI ( [ library, [ hwndOwner, [ title, [ instruction, [ lmdOptions ) : int | ||
library | [ | |
hwndOwner | [ | |
title | [ | |
instruction | [ | |
lmdOptions | [ | |
리턴 | int |
private static void ShowManageLibraryUI(ShellLibrary shellLibrary, IntPtr windowHandle, string title, string instruction, bool allowAllLocations) { int hr = 0; Thread staWorker = new Thread(() => { hr = ShellNativeMethods.SHShowManageLibraryUI( shellLibrary.NativeShellItem, windowHandle, title, instruction, allowAllLocations ? ShellNativeMethods.LibraryManageDialogOptions.NonIndexableLocationWarning : ShellNativeMethods.LibraryManageDialogOptions.Default); }); staWorker.SetApartmentState(ApartmentState.STA); staWorker.Start(); staWorker.Join(); if (!CoreErrorHelper.Succeeded(hr)) { throw new ShellException(hr); } }
private static void ShowManageLibraryUI(ShellLibrary shellLibrary, IntPtr windowHandle, string title, string instruction, bool allowAllLocations) { int hr = 0; Thread staWorker = new Thread(() => { hr = ShellNativeMethods.SHShowManageLibraryUI( shellLibrary.NativeShellItem, windowHandle, title, instruction, allowAllLocations ? ShellNativeMethods.LIBRARYMANAGEDIALOGOPTIONS.LMD_NOUNINDEXABLELOCATIONWARNING : ShellNativeMethods.LIBRARYMANAGEDIALOGOPTIONS.LMD_DEFAULT); }); staWorker.SetApartmentState(ApartmentState.STA); staWorker.Start(); staWorker.Join(); if (!CoreErrorHelper.Succeeded(hr)) { Marshal.ThrowExceptionForHR(hr); } }