if len(ls_user)<1 then
messagebox('提示!','用户名不能为空.')
sle_1.setfocus()
return
end if
if len(ls_pass)<1 then
messagebox('提示!','密码不能为空.')
sle_2.setfocus()
return
end if
select 100 into:li_flag
from ts_user
where userid=:ls_user;
if li_flag<>100 then
messagebox('提示!','用户不存在.')
sle_1.setfocus()
return
end if
select groupid,password into:gi_groupid,:ls_pwd
from ts_user
where userid=:ls_user;
if ls_pass<>trim(ls_pwd) then
messagebox('提示!','密码不正确.')
sle_2.setfocus()
return
else
gs_name=ls_user
open(w_main)
close(parent)
end if