Bagikan melalui


CortanaActionableInsightsOptions.SurroundingText Properti

Definisi

Teks dari konteks sekitar konten yang disediakan ke CortanaActionableInsights untuk menampilkan wawasan.

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

Nilai Properti

String

Platform::String

winrt::hstring

Konteks tekstual mengelilingi konten (panjang maksimum 3000 karakter). Nilai ini bisa null.

Atribut

Persyaratan Windows

Kemampuan aplikasi
cortanaSurface

Keterangan

Jika setter dipanggil dengan string yang melebihi panjang maksimum, pengecualian akan dilemparkan.

Kelas CortanaActionableInsights mengharuskan hal berikut ditambahkan ke Package.appxmanifest:

  • Ke <Paket>
    • xmlns:rescap="http://schemas.microsoft.com/appx/manifest/foundation/windows10/restrictedcapabilities"
    • IgnorableNamespaces="rescap"
  • Di bawah <Kapabilitas>
    • <rescap:capability name="cortanaSurface"/>

Berlaku untuk