Thread View: cn.bbs.comp.program
1 messages
1 total messages
Started by ���ܵ�Сʨ
Thu, 07 May 1998 00:00
��Foxpro�лָ���ɾ�����
Author: ���ܵ�Сʨ
Date: Thu, 07 May 1998 00:00
Date: Thu, 07 May 1998 00:00
75 lines
4990 bytes
4990 bytes
��Foxpro��ݿ��е���ݽ���ɾ���Լ���������ַ���:
����DOS����Del�������Foxpro����DELETE FILE����ֱ��ɾ��
��ݿ��ļ���
����Foxpro�д���ݿ�,��PACK�����������ɾ���ǵļ�¼
��
����Foxpro�д���ݿ�,��ZAP����ɾ����ݿ��е����м�¼��
���ڵ�һ�ַ���,����DOS�ṩ��UNDELETE����ֱ�ӻָ������ڵ�
���ַ���,����Foxprɾ����ݵĹ�����Ƚ�δ��ɾ���ǵļ�¼����
ͷ������һ�����ļ�,Ȼ����ɾ��ԭ��ݿ��ļ�,����,����PACK����
��ɾ��������Ȼ����DOS�ṩ��UNDELETE����ֱ�ӻָ������ڵ���
�ַ���,��Щ������������PCTools�ȹ�������ָ�,����������,����
����ͨ��������ʹ��,���������������п����ƻ�������ݡ�����
�ڳ���о���Foxpro��ݿ�ṹ�Ļ���,����Foxpro�ĵͼ���ʽ��
������������ͨ�ûָ�����
�ó���Ĺؼ����ڻָ���ݿ��ļ��Ĵ�С����ݿ��еļ�¼��
�ļ��Ĵ�С���ɺ���C HSIZE()ֱ�ӻָ�;��¼��ɸ����ݿ�Ĵ�С
�ͼ�¼�ij������,��������ݿ�ͷ���ĵ�5��8���ֽ�,�ҵ�λ�ֽ�
��ǰ,��λ�ֽ��ں�,�ö��������ʾ(һ��Foxpro��ݿ���鼮�о�
�н���,�ڴ˲�����)�������嵥����:
clear
clear all
set talk off
name=space(12)
size=0
@10,20 say��������Ԥ�ָ���ݿ��ȫ��:'get name
@12,20 say��������Ԥ�ָ���ݿ�Ĵ�С:'get sizepict��9999
999999'
read
use &name
head=header () &&����ݿ��ͷ����ռ���ֽ���
reclen=recsize() &&����ݿ��м�¼�ij���
jls=int((size-head1)/reclen) &&�����ݿ��С�ͼ�¼��
����ü�¼��
zjs1=chr(mod(jls,256)) &&��ݿ�ͷ��5���ֽڵ�����
jls=int((jls/256)
zjs2=chr(mod(jls,256)) &&��ݿ�ͷ��6���ֽڵ�����
jls=int(jls/256)
zjs3=chr(mod(jls,256)) &&��ݿ�ͷ��7���ֽڵ�����
jls=int(jls/256)
zis4=chr(mod(jls,256)) &&��ݿ�ͷ��8���ֽڵ�����
jls=int(jls/256)
use
handle=fopen(name,2)
=fchsize(handle,size) &&�ı��ļ��Ĵ�С
=fclose(handle)
handle=fopen(name,2)
=fseek(handle,4,0)
=fwrite(handle,zjs1) &&�ı��ļ��ļ�¼��
=fwrite(handle,zjs2)
=fwrite(handle,zjs3)
=fwrite(handle,zjs4)
=fclose(handle)
delete file &name
filename=��?'+alltrim(substr(name,2,10))
run undelete &filename/all
run ren &filename &name
retu
ʹ�øó���ʱ,����������ɾ��ݿ��ȫ��,Ȼ������ɾ����ǰ��
�ݿ��ļ��Ĵ�С(��֪���ļ���Сֱ�����뼴�ɻָ�ȫ�����;��֪
���ļ���С��������һ����ֵ,�øù���ֵ�ָ���,����ݿ�鿴��
��,����ݻָ���ȫ,˵������ֵ��С,��ZAP����ɾ�����,�������
ֵ���»ָ�ֱ�����ȫ���ָ�Ϊֹ)��
�ó�����LX-P5/75PCI���ϡ�DOS6.22�¡�Foxpro2.6 for DOS��
��������ͨ��,����Ȥ�Ķ��߲���һ�ԡ�
--
________ _____ _____ ______________ _____
___ __ \___(_)________ ___(_) __ ___/___ /_ ___(_)
__ /_/ /__ / ___ __ \__ / _____ \ __ __ \__ /
_ ____/ _ / __ /_/ /_ / ____/ / _ / / /_ /
/_/ /_/ _ .___/ /_/ /____/ /_/ /_/ /_/
/_/
[m[1;36m�� ��Դ:���ϴ�С�ٺ���Ϣ����վ bbs.nju.edu.cn��[FROM: hsia.nju.edu.cn][m
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads