12092.html
来自「VB技巧问答10000例,是一个教程」· HTML 代码 · 共 38 行
HTML
38 行
<html>
<head>
<title>How to eliminate unlimited loop?</title>
</head>
<body bgcolor="#FFFFFF" vlink="#808080">
<center>
<h1>How to eliminate unlimited loop?</h1>
</center>
<hr size=7 width=75%>
<hr size=7 width=75%><p>
Posted by <a href="mailto:svc009@ntut.edu.tw">小飞虾</a> on April 16, 1999 at 20:49:45:<p>
连续两个text box, 皆有下列事件:<br> private sub text_LostFocus(index)<br> If Not IsCorrectDate(txtFields(index), False) Then<br> txtFields(index).setfocus<br> End If<br> end sub<br>Public Function IsCorrectDate(strDate As String, AllowEmpty As Boolean) As Boolean<br> If AllowEmpty Then<br> If strDate = "" Then<br> IsCorrectDate = True<br> Else<br> IsCorrectDate = IsDate(strDate)<br> End If<br> Else<br> If strDate = "" Then<br> IsCorrectDate = False<br> Else<br> IsCorrectDate = IsDate(strDate)<br> End If<br> End If<br>End Function<p>问题是在第一个text box按tab 跳过后curosr 就在这两textbox跳来跳去,无止尽。除了将两个连续text box 隔开外,有没有其他办法。
<br>
<br><hr size=7 width=75%><p>
<a name="followups">Follow Ups:</a><br>
<ul><!--insert: 12092-->
<!--top: 12098--><li><a href="12098.html">Re: How to eliminate unlimited loop?</a> <b>阿毛</b> <i>23:33:11 4/16/99</i>
(<!--responses: 12098-->3)
<ul><!--insert: 12098-->
<!--top: 12137--><li><a href="12137.html">这是讨厌的问题</a> <b>cww</b> <i>21:57:33 4/18/99</i>
(<!--responses: 12137-->2)
<ul><!--insert: 12137-->
<!--top: 12168--><li><a href="12168.html">Re: 这是讨厌的问题:validate 好像也不可以</a> <b>小飞虾</b> <i>14:55:11 4/19/99</i>
(<!--responses: 12168-->1)
<ul><!--insert: 12168-->
<!--top: 12173--><li><a href="12173.html">应该像这样做</a> <b>cww</b> <i>16:04:33 4/19/99</i>
(<!--responses: 12173-->0)
<ul><!--insert: 12173-->
</ul><!--end: 12173-->
</ul><!--end: 12168-->
</ul><!--end: 12137-->
</ul><!--end: 12098-->
</ul><!--end: 12092-->
<br><hr size=7 width=75%><p>
</body></html>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?