相关代码 |
|
Ch09-02-02.aspx RangeValidator控件 ' 用户单击“Button控件”的事件处理程序 Sub Button1_Click(obj As Object, e As EventArgs) Dim strA As String If Page.IsValid Then strA = "输入的成绩是:" & Text1.Text Show1.InnerHTML = strA Else Show1.InnerHTML = "" End If End Sub 输入ASP.NET的测试成绩: Runat="Server" /> ControlToValidate="Text1" MinimumValue="0" MaximumValue="100" Type="Integer" Display="Dynamic" ErrorMessage="必需是介于0到100之间的数字!" Runat="Server" />
相关资源 |
|