17134.html

来自「以电子书的形式收集了VB一些常见问题解决方法,可以很方便的查找自己需要解决的问题」· HTML 代码 · 共 27 行

HTML
27
字号
<html>  <head>    <title>Re: 如何限制在Text Box 中只能输入数字及小数点 ??? (无内文)</title>  </head>  <body bgcolor="#FFFFFF" vlink="#808080">    <center>      <h1>Re: 如何限制在Text Box 中只能输入数字及小数点 ??? (无内文)</h1>    </center><hr size=7 width=75%><hr size=7 width=75%><p>Posted by Fai on August 12, 1999 at 17:16:56:<p>In Reply to: <a href="17130.html">如何限制在Text Box 中只能输入数字及小数点 ??? (无内文)</a> posted by 小小 on August 12, 1999 at 16:48:51:<p>: ...<p>Public Sub ValidateNumber(KeyAscii As Integer)<br>    Dim strValid As String<br>    <br>    strValid = "0123456789." & Chr(8)<br>    If InStr(strValid, Chr(KeyAscii)) = 0 Then<br>        KeyAscii = 0<br>    End If<br>End Sub<p>Private Sub Text1_KeyPress(KeyAscii As Integer)<br>    Call ValidateNumber(KeyAscii)<br>End Sub<br><br><br><hr size=7 width=75%><p><a name="followups">Follow Ups:</a><br><ul><!--insert: 17134--><!--top: 17171--><li><a href="17171.html">谢谢! (无内文)</a> <b>小小</b> <i>09:58:40 8/13/99</i>(<!--responses: 17171-->0)<ul><!--insert: 17171--></ul><!--end: 17171--></ul><!--end: 17134--><br><hr size=7 width=75%><p></body></html>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?