如何从文本文件中提取有用的字段(50分)

  • 主题发起人 主题发起人 li_one
  • 开始时间 开始时间
L

li_one

Unregistered / Unconfirmed
GUEST, unregistred user!
在一个文本文件中有很多纪录,例
COMPANY: Chee Siang Industrial Co., LTD.
ADDRESS: No. 32, Wu Chuan 7th Road, Wu Ku Industrial Area,
Wu Ku Hsiang 24248, Taipei Hsien, Taiwan
PHONE: 886-2-2299-9518
FAX: 886-2-2299-9519,886-2-2299-9519
EMAIL: cheesiang@golden-wheel.com
CONTACT: Quo Zhen, Zhou
ETO:
The 々Chee Siang—President-Mr. Chen, Man-Chuing who
established 々Chiho Trading Co., Ltd.— in 1976,
specialized to be the Taiwan sole agent of ¨YAKUMO〃
我不要ETO以后的纪录.该如何做.
 
var str:Tstrings;
s:string;
begin
try
str:=Tstringlist.create;
str.loadfromfile('你的文件名.txt');
s:=str.text;
delete(s,i,length(s));
str.Text:=s;
str.savetofile('你的文件名.txt');
finally
str.free;
end;
 
接受答案了.
 
后退
顶部