If e.keycode = 13 Then Dim fdr As DataRow = DataTables("领取表").find("编码 = '" & e.sender.Text & "'") If fdr Is Nothing Then e.form.controls("TextBox2").Text = Nothing msgbox("没有找到") Else Dim idx As Integer = Date.Today.Day fdr("领取_" & idx) = True e.form.controls("TextBox2").Text = fdr("姓名") End If e.cancel = True End If