以文本方式查看主题 - Foxtable(狐表) (http://foxtable.com/bbs/index.asp) -- 专家坐堂 (http://foxtable.com/bbs/list.asp?boardid=2) ---- [求助] 身份证号判别 (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=174575) |
||||
-- 作者:njzwm -- 发布时间:2022/1/21 16:21:00 -- [求助] 身份证号判别 Dim Age As Integer Dim VV As Boolean VV = validPIN("身份证号") If VV = True Then output.show(VV) output.show("right!") Else Output.show(VV) MessageBox.show("wrong!") e.cancel = True End If 结果判别都是VV=false,是这句“VV = validPIN("身份证号")”有问题吗?
|
||||
-- 作者:有点蓝 -- 发布时间:2022/1/21 16:37:00 -- 是身份证号码有问题吧 |
||||
-- 作者:njzwm -- 发布时间:2022/1/21 17:33:00 -- Dim Age As Integer Dim VV As Boolean VV = validPIN("身份证号") e.DataRow("判别正确性")=VV If VV = True Then e.DataRow("生日") = Readbirthday(e.DataRow("身份证号")) MessageBox.show("right!") Else MessageBox.show("wrong!") e.cancel = True End If 请看我的例子,谢谢!
|
||||
-- 作者:njzwm -- 发布时间:2022/1/21 17:34:00 --
|
||||
-- 作者:foxtablefanse -- 发布时间:2022/1/21 17:36:00 -- ![]() ![]() |
||||
-- 作者:njzwm -- 发布时间:2022/1/21 17:38:00 -- 请打开我的文件你试一下就发现问题了。单个测试validPIN(“3322xxxxx33”)语句没问题,但是如果在表中把数字放进表中的字段里后就发现问题,结果总是“false”。 [此贴子已经被作者于2022/1/21 17:41:12编辑过]
|
||||
-- 作者:foxtablefanse -- 发布时间:2022/1/21 17:42:00 -- Dim Age As Integer Dim VV As Boolean VV = validPIN(e.DataRow("身份证号")) e.DataRow("判别正确性")=VV If VV = True Then e.DataRow("生日") = Readbirthday(e.DataRow("身份证号")) MessageBox.show("right!") Else MessageBox.show("wrong!") e.cancel = True End If
[此贴子已经被作者于2022/1/21 17:42:08编辑过]
|
||||
-- 作者:njzwm -- 发布时间:2022/1/21 17:53:00 -- 完美解决,谢谢! ![]() |