共用方式為


LocalLocationFinder.FindLocalLocationsAsync 方法

定義

取得符合指定搜尋準則之企業和地點的相關資訊。

注意

此 API 不適用於所有 Windows 應用程式。 除非您的開發人員帳戶是由 Microsoft 特別布建,否則呼叫此 API 會在執行時間失敗。 如需 Windows.Services.Maps.LocalSearch 命名空間的詳細資訊,請與您的 Microsoft 帳戶小組代表合作。

public:
 static IAsyncOperation<LocalLocationFinderResult ^> ^ FindLocalLocationsAsync(Platform::String ^ searchTerm, Geocircle ^ searchArea, Platform::String ^ localCategory, unsigned int maxResults);
/// [Windows.Foundation.Metadata.RemoteAsync]
 static IAsyncOperation<LocalLocationFinderResult> FindLocalLocationsAsync(winrt::hstring const& searchTerm, Geocircle const& searchArea, winrt::hstring const& localCategory, uint32_t const& maxResults);
[Windows.Foundation.Metadata.RemoteAsync]
public static IAsyncOperation<LocalLocationFinderResult> FindLocalLocationsAsync(string searchTerm, Geocircle searchArea, string localCategory, uint maxResults);
function findLocalLocationsAsync(searchTerm, searchArea, localCategory, maxResults)
Public Shared Function FindLocalLocationsAsync (searchTerm As String, searchArea As Geocircle, localCategory As String, maxResults As UInteger) As IAsyncOperation(Of LocalLocationFinderResult)

參數

searchTerm
String

Platform::String

winrt::hstring

搜尋的查詢文字;您要搜尋的 。

searchArea
Geocircle

要包含在搜尋中的地理區域。

localCategory
String

Platform::String

winrt::hstring

用來限制搜尋結果的搜尋類別。 建議您使用一或多個 LocalCategories 屬性來指定 localCategory。 使用分號 「; 」 分隔符號來指定多個類別。

maxResults
UInt32

unsigned int

uint32_t

要從搜尋傳回的結果數目上限。

傳回

符合指定搜尋準則的相關企業或地點,類型為 LocalLocationFinderResult

屬性

適用於