WebRenderTreeBuilderExtensions.AddEventPreventDefaultAttribute 方法

定义

追加表示指令的帧,以防止指定事件的默认操作。

public:
[System::Runtime::CompilerServices::Extension]
 static void AddEventPreventDefaultAttribute(Microsoft::AspNetCore::Components::Rendering::RenderTreeBuilder ^ builder, int sequence, System::String ^ eventName, bool value);
public static void AddEventPreventDefaultAttribute (this Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder builder, int sequence, string eventName, bool value);
static member AddEventPreventDefaultAttribute : Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder * int * string * bool -> unit
<Extension()>
Public Sub AddEventPreventDefaultAttribute (builder As RenderTreeBuilder, sequence As Integer, eventName As String, value As Boolean)

参数

sequence
Int32

一个整数,表示指令在源代码中的位置。

eventName
String

要受影响的事件的名称。

value
Boolean

如果要阻止默认操作,则为 True,否则为 false。

适用于