CASE 9
FOR i=5 TO 6
r_bit=mid(r_km_code,i,1)
IF not ( r_bit >= "0" and r_bit <= "9" ) THEN
messagebox('提示','请输入数字!')
this.setitem(r_row,'km_code','')
return 1
END IF
NEXT
FOR i=8 TO 9
r_bit=mid(r_km_code,i,1)
IF not ( r_bit >= "0" and r_bit <= "9" ) THEN
messagebox('提示','请输入数字!')
this.setitem(r_row,'km_code','')
return 1
END IF
NEXT
IF not (mid(r_km_code,4,1)='-' and mid(r_km_code,7,1)='-') THEN
messagebox('提示','科目编码格式错误,,正确格式为:"XXX-XX-XX')
this.setitem(r_row,'km_code','')
return 1
END IF
CASE ELSE
messagebox('提示','科目编码格式错误!')
this.setitem(r_row,'km_code','')
return 1
END CHOOSE
//3 插入默认科目级别
CHOOSE CASE r_cd
CASE 3
this.setitem(r_row,'kmjb',1)
CASE 6
this.setitem(r_row,'kmjb',2)
CASE 9
this.setitem(r_row,'kmjb',3)
CASE ELSE
END CHOOSE
//4 插入上级科目
CHOOSE CASE r_cd
case 3
this.setitem(r_row,'sjkm','')
CASE 6
r_sjkm= left(r_km_code,3)
this.setitem(r_row,'sjkm',r_sjkm)
CASE 9
r_sjkm= left(r_km_code,6)
this.setitem(r_row,'sjkm',r_sjkm)
END CHOOSE
//非一级科目的增加必须存在上级科目
//5 末级标记的处理
CHOOSE CASE r_cd
CASE 3
this.setitem(r_row,'mjbj_code','Y')
CASE 6
//判断数据库中是否存在上级科目
select count(*) into :r_count from zz_kjkmbmb where zth=:g_zth and km_code=substring(:r_km_code,1,3);
if not r_count > 0 then
//判断当前的数据窗口中是否
论文范文http://www.chuibin.com/ 存在上级科目
r_found = this.Find("km_code = '" +mid(r_km_code,1,3)+"'", 1, this.RowCount())
if not r_found>0 then
messagebox('提示',"无一级科目"+left(r_km_code,3))
this.setitem(r_row,'km_code','')
return 1
end if
this.setitem(r_found,'mjbj_code','N')
end if
this.setitem(r_row,'mjbj_code','Y')
CASE 9
select count(*) into :r_count from zz_kjkmbmb where zth=:g_zth and km_code=substring(:r_km_code,1,6);
if not r_count > 0 then
//判断当前的数据窗口中是否存在上级科目
r_found = this.Find("km_code = '" +mid(r_km_code,1,6)+"'", 1, this.RowCount())
if not r_found>0 then
messagebox('提示',"无二级科目"+left(r_km_code,6))
this.setitem(r_row,'km_code','')
上一页 [1] [2] [3] [4] [5] [6] [7] [8] 下一页
账务处理系统会计科目输入模块 第6页下载如图片无法显示或论文不完整,请联系qq752018766