BBDB_1.PRG
上传用户:abc1382430
上传日期:2013-01-31
资源大小:1233k
文件大小:3k
- ********************************
- * 文件名: wjdb.prg *
- * 功能: 文件打包 *
- * 设计: 黄朝生 *
- ********************************
- cd=space(30)
- *---------------------------------------------------------------------
- if !file('cwnul')
- ?? chr(7)
- sm='请将JQFAX与JQ财务系统安装到同一盘中!'
- wait sm window
- endif
- sm=''
- *****************
- defi wind jqwin1 from 6,20 to 11,60 titl ' 输入打包报表日期 '
- acti wind jqwin1
- Ryear=0
- Rdate=0
- @2,2 say '请输入报表日期: 年 月'
- @ 2,18 get Ryear pict'@bz9999'
- @ 2,26 get Rdate pict'@bz99' valid(Rdate>0 .and. Rdate<13)
- read
- deac wind jqwin1
- if len(ltrim(str(Ryear)))<>4
- retu
- endif
- *@ 8,20 say '正在处理数据......'
- file='cw'+ltrim(str(Ryear))+'m'+ltrim(str(Rdate))+''
- pd1=0
- pd2=0
- if !file(file+'fzb.dbf')
- ?? chr(7)
- sm=' 资产负债表没找到!'
- wait sm window
- pd1=1
- else
- pd2=1
- endif
- if !file(file+'syb.dbf')
- ?? chr(7)
- sm=' 损 益 表没找到!'
- wait sm window
- pd1=1
- else
- pd2=1
- endif
- if !file(file+'BCMXB.DBF')
- ?? chr(7)
- sm=' 补充明细表没找到!'
- wait sm window
- pd1=1
- else
- pd2=1
- endif
- if !file(file+'yjkb.dbf')
- ?? chr(7)
- sm=' 应交款项表没找到!'
- wait sm window
- pd1=1
- else
- pd2=1
- endif
- if !file(file+'zzsb.dbf')
- ?? chr(7)
- sm=' 增值税报表没找到!'
- wait sm window
- pd1=1
- else
- pd2=1
- endif
- db=1
- if pd1=1 .and. pd2=1
- defi wind JQWIN1 from 6,20 to 11,60
- acti wind jqwin1
- ?? chr(7)
- @1,2 say '报表没有全部找到,是否打包?'
- set colo to w/b,6+/bg
- @2,8 prom '打包'
- @2,14 prom '不打包'
- menu to pd
- do case
- case pd=1
- db=1
- case pd=2 .or. pd=0
- db=0
- endcase
- deac wind jqwin1
- endif
- if db=1 .and. pd2=1
- @ 8,20 say '正在处理数据......'
- ! deltree -y outdata >nul
- ! md outdata
- ***********拷贝文件
- if file(file+'fzb.dbf')
- file1=file+'fzb.dbf'
- copy file &file1 to outdatafzbhz.dbf
- endif
- if file(file+'syb.dbf')
- file1=file+'syb.dbf'
- copy file &file1 to outdatasybhz.dbf
- endif
- if file(file+'bcmxb.dbf')
- file1=file+'bcmxb.dbf'
- copy file &file1 to outdatabcmxbhz.dbf
- endif
- if file(file+'yjkb.dbf')
- file1=file+'yjkb.dbf'
- copy file &file1 to outdatayjkbhz.dbf
- endif
- if file(file+'zzsb.dbf')
- file1=file+'zzsb.dbf'
- copy file &file1 to outdatazzsbhz.dbf
- endif
- ************
- set path to jqfax
- ! copy jqfaxyear.dbf outdata && 记住数据日期 解包时用
- use jqfaxoutdatayear
- repl nf with Ryear,yf with Rdate
- use
- * 内存不够时,可用-M0参数打包,但不进行压缩
- ! arj a -m4 outdatabb.arj outdata*.* -y
- deac wind jqwin1
- acti wind jqwin
- acti wind jqfaxwin
- clea
- endif
- retu
-