ExtensionMethod.NET Home of 880 C#, Visual Basic, F# and Javascript extension methods
Returns Dropdownlist Selected Value as Integer
public static int SelectionValue(this DropDownList ddl) { var r = -1; int.TryParse(ddl.SelectedValue, out r); return r; }
var selectedValue = ddl.SelectedValue();
Author: Andi Haviari
Submitted on: 29 apr. 2016
Language: C#
Type: Integer
Views: 3591