Control.ControlAccessibleObject.RaiseLiveRegionChanged 方法

定義

引發 LiveRegionChanged 使用者介面自動化事件。Raises the LiveRegionChanged UI automation event.

public:
 override bool RaiseLiveRegionChanged();
public override bool RaiseLiveRegionChanged ();
override this.RaiseLiveRegionChanged : unit -> bool
Public Overrides Function RaiseLiveRegionChanged () As Boolean

傳回

若作業成功,則為 true;否則為 falsetrue if the operation succeeds; otherwise, false otherwise.

例外狀況

擁有者控制項不是即時區域。The owner control is not a live region.

備註

若要讓此方法生效,控制項必須System.Windows.Forms.Automation.IAutomationLiveRegion執行介面,而且其LiveSetting屬性必須AutomationLiveSetting.Polite傳回或AssertiveFor this method to be effective, the control must implement the System.Windows.Forms.Automation.IAutomationLiveRegion interface, and its LiveSetting property must return either AutomationLiveSetting.Polite or Assertive. 此外,應用程式必須重新編譯為目標 .NET Framework 4.8,或使用相容性參數加入宣告此功能。In addition, the application must be recompiled to target .NET Framework 4.8 or opt in to this feature by using compatibility switches.

適用於