Поделиться через


CortanaActionableInsightsOptions.SurroundingText Свойство

Определение

Текст из окружающего контекста содержимого, предоставленного в CortanaActionableInsights для отображения аналитических сведений.

public:
 property Platform::String ^ SurroundingText { Platform::String ^ get(); void set(Platform::String ^ value); };
winrt::hstring SurroundingText();

void SurroundingText(winrt::hstring value);
/// [get: Windows.Foundation.Metadata.Deprecated("CortanaActionableInsightsOptions is deprecated and might not work on all platforms. For more info, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 655360, "Windows.Foundation.UniversalApiContract")]
/// [set: Windows.Foundation.Metadata.Deprecated("CortanaActionableInsightsOptions is deprecated and might not work on all platforms. For more info, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 655360, "Windows.Foundation.UniversalApiContract")]
winrt::hstring SurroundingText();

void SurroundingText(winrt::hstring value);
public string SurroundingText { get; set; }
public string SurroundingText { [Windows.Foundation.Metadata.Deprecated("CortanaActionableInsightsOptions is deprecated and might not work on all platforms. For more info, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 655360, "Windows.Foundation.UniversalApiContract")] get; [Windows.Foundation.Metadata.Deprecated("CortanaActionableInsightsOptions is deprecated and might not work on all platforms. For more info, see MSDN.", Windows.Foundation.Metadata.DeprecationType.Deprecate, 655360, "Windows.Foundation.UniversalApiContract")] set; }
var string = cortanaActionableInsightsOptions.surroundingText;
cortanaActionableInsightsOptions.surroundingText = string;
Public Property SurroundingText As String

Значение свойства

String

Platform::String

winrt::hstring

Текстовый контекст, окружающий содержимое (максимальная длина 3000 символов). Это значение может быть равно NULL.

Атрибуты

Требования к Windows

Возможности приложения
cortanaSurface

Комментарии

Если метод задания вызывается со строкой, превышающей максимальную длину, возникает исключение.

Класс CortanaActionableInsights требует добавления в Package.appxmanifest следующее:

  • В <пакет>
    • xmlns:rescap="http://schemas.microsoft.com/appx/manifest/foundation/windows10/restrictedcapabilities"
    • IgnorableNamespaces="rescap"
  • В разделе <Возможности>
    • <rescap:capability name="cortanaSurface"/>

Применяется к