RepeaterCommandEventArgs.CommandSource Property

Definition

Gets the source of the command.

C#
public object CommandSource { get; }

Property Value

The command source.

Examples

The following example demonstrates how to determine the command source from the CommandSource property.

C#
void R1_ItemCommand(Object Sender, RepeaterCommandEventArgs e) {
    Label2.Text = "The " + ((Button)e.CommandSource).Text + " button has just been clicked; <br>";
 }

Remarks

Use this property to determine the source of the command.

Applies to

Proizvod Verzije
.NET Framework 1.1, 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1

See also