1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: 30: 31: 32: 33: 34: 35: 36: 37: 38: 39: 40: 41: 42: 43: 44: 45: 46: 47: 48: 49: 50: 51: 52: 53: 54: 55: 56: 57: 58: 59: 60: 61: 62: 63: 64: 65: 66: 67: 68: 69: 70: 71: 72: 73: 74: 75: 76: 77: 78: 79: 80: 81: 82: 83: 84: 85: 86: 87: 88: 89: 90: 91: 92: 93: 94: 95: 96: 97: 98: 99: 100: 101: 102: 103: 104: 105: 106: 107: 108: 109: 110: 111: 112: 113: 114: 115: 116: 117: 118: 119: 120: 121: 122: 123: 124: 125: 126: 127: 128:
| procedure TForm1.Button2Click(Sender: TObject); var times,i,rest,ids,lines:Integer; begin lines := memo1.Lines.Count; progressbar1.Max := lines; button1.Enabled := false; button2.Enabled := false; for i:= 1 to lines do begin combobox1.ItemIndex := combobox1.itemindex +1; edit24.Text := combobox1.items[combobox1.itemindex]; if ((Pos('/',edit24.Text) = 1) OR (edit24.text = '')) then begin combobox1.ItemIndex := combobox1.itemindex +1; edit24.Text := combobox1.items[combobox1.itemindex]; progressbar1.position := progressbar1.position+1; end else begin
ids := Pos(',',edit24.text)-1; edit2.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit3.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit4.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit5.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit6.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit7.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit8.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit9.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit10.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit11.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit12.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit13.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit14.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit15.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit16.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit17.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit18.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit19.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit20.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit21.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999); ids := Pos(',',edit24.text)-1; edit22.Text := Copy(edit24.text,1,ids); rest := Pos(',',edit24.text)+1; edit24.Text := Copy(edit24.text,rest,999);
edit23.Text := Copy(edit24.text,1,999);
if ((edit5.text = '4') OR (edit5.text = '5')) then begin edit12.text := edit1.text; edit25.text := edit2.text +','+edit3.text+','+edit4.text+','+edit5.text+','+edit6.text+','+edit7.text+','+edit8.text+','+edit9.text+','+edit10.text+','+edit11.text+','+edit12.text+','+edit13.text+','+edit14.text+','+edit15.text+','+edit16.text+','+edit17.text+','+edit18.text+','+edit19.text+','+edit20.text+','+edit21.text+','+edit22.text+','+edit23.text; Memo1.Lines.Strings[combobox1.itemindex] := edit25.Text; times := times +1; end;
progressbar1.position := progressbar1.position+1; end; if (ProgressBar1.position = ProgressBar1.Max) then begin button1.Enabled := True; button2.Enabled := True; Memo1.Lines.SaveToFile(opendialog1.filename); label1.caption := inttostr(times); end;
end;
end; |