public static void IndexDirectory(string dirPath) { structs.IndexDirectoryResult result = new structs.IndexDirectoryResult(); IndexDirectory(dirPath, out result); if (result.opStatus != 0) { throw new Exception("Couldn't index the specified directory. Call to the unmanaged DLL failed"); } }
private static extern void IndexDirectory([MarshalAs(UnmanagedType.LPWStr)] string dirPath, out structs.IndexDirectoryResult result);