Share via


AutoSuggestBox.searchHistoryContext property

Gets or sets the search history context. This context is used a secondary key (the app ID is the primary key) for storing search history.

Syntax

<div 
    data-win-control="WinJS.UI.AutoSuggestBox" 
    data-win-options="{ searchHistoryContext : value}" >
</div>
var searchHistoryContext = autoSuggestBox.searchHistoryContext;
autoSuggestBox.searchHistoryContext = searchHistoryContext;

Property value

Type: String

The search history context.

Remarks

An app can use the search history context string to store different search histories based on the context of the application. If you don't set this property, the system assumes that all searches in your app occur in the same context.

Requirements

Minimum WinJS version

WinJS 4.0

Namespace

WinJS.UI

See also

AutoSuggestBox