procedure TForm1.Button5Click(Sender: TObject);<br>Var i:integer;<br> newitem:Tlistitem;<br> Temp:TStrings;<br>begin<br>Temp:=TStringList.Create;<br> For i:=0 To StrList.Count-1 Do<br> Begin<br> Temp.Delimiter:=FenGe;<br> Temp.DelimitedText:=StrList;<br> newitem:=ListView.Items.Add;<br> newitem.Caption:=Temp[0];<br> newitem.SubItems.Add(Temp[1]);<br> newitem.SubItems.Add(Temp[2]);<br> newitem.Checked:=true;<br> End;<br>Temp.Free;<br>end;<br><br>procedure TForm1.Button3Click(Sender: TObject);<br>Var UpData,Ben,Yuan:TStrings;<br>I,S:integer;<br>begin<br>UpData:=TStringList.Create;<br>Ben:=TStringList.Create;<br>Yuan:=TStringList.Create;<br>UpData.LoadFromFile(edit4.Text);<br>Ben.LoadFromFile(edit2.Text);<br>Yuan.LoadFromFile(edit4.Text);<br>S:=0;<br>For I:=0 To Yuan.Count-20 Do<br>Begin<br> Ben.Move(1,1);<br> If Pos(Yuan,Ben.Text)>0 then<br> Begin<br> //showmessage(inttostr(i)+#13#10+'OK');<br> UpData.Delete(I-S);<br> Inc(S);<br> End;<br>End;<br>UpData.SaveToFile(ExtractFilePath(Application.ExeName)+'UpData.txt');<br>UpData.Free;<br>Ben.Free;<br>Yuan.Free;<br>end;