以文本方式查看主题 - Foxtable(狐表) (http://foxtable.com/bbs/index.asp) -- 专家坐堂 (http://foxtable.com/bbs/list.asp?boardid=2) ---- 这两个值相等为什么不执行退出呢? (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=9764) |
-- 作者:dd-zdh -- 发布时间:2011/5/6 19:56:00 -- 这两个值相等为什么不执行退出呢? Dim UserName As String = e.Form.Controls("UserName").Value End If |
-- 作者:狐狸爸爸 -- 发布时间:2011/5/6 20:17:00 -- 说明他俩不等嘛 |
-- 作者:dd-zdh -- 发布时间:2011/5/6 20:25:00 -- 我把表里的值都取出来了,和我textbox1.text相等,也不执行退出 |
-- 作者:狐狸爸爸 -- 发布时间:2011/5/6 20:30:00 -- 在: If s1 = s2 Then 的前面加一行:
messagebox.show(s1 = s2 )
|
-- 作者:dd-zdh -- 发布时间:2011/5/6 20:51:00 -- 是不等,但我输入的值和取出的值都为11,怎么还显示False呢 |
-- 作者:狐狸爸爸 -- 发布时间:2011/5/6 20:57:00 -- 把 messagebox.show(s1 = s2 )
改为 messagebox.show(s1.Length & "|" & s2.legnth )
比较二者的长度,你可能会发现原因,通常是因为前后有空格所致。
|