
22.01.2011, 15:12
|
 |
Продвинутый
|
|
Регистрация: 07.09.2010
Сообщения: 726
Репутация: 26711
|
|
Код:
potokkomand1:=TstringList.Create;
PK1:=TstringList.Create;
PK1.add('7559384=hello');
PK1.add('7559384=hello');
PK1.add('7559384=hello');
potokkomand1:=PK1;
Timer1potok:=True; // за чем это?
If Timer1potok = True then // оно и так будет True, можно убрать if.
// также на будущее не пиши так: if(x=True), пиши так: if(x) then ...;
begin
Timer1potok:=false;
if potokkomand1.Count-1 > 6 then // здесь -1 не надо я так полагаю
begin
for mem1:=potokkomand1.Count-1 Downto 0 do
begin
UIN1:=copy(potokkomand1.strings[mem1],1,pos('=',potokkomand1.strings[mem1])-1);
Msg1:=copy(potokkomand1.strings[mem1],pos('=',potokkomand1.strings[mem1])+1,length(potokkomand1.strings[mem1]) - pos('=', potokkomand1.strings[mem1]));
potokkomand1.Delete(mem1);
Form1.obrabotchik1(UIN1, Msg1);
sleep(200);
end;
end
else
begin
for mem1:=potokkomand1.Count-1 DownTo 0 do
begin
UIN1:=copy(potokkomand1.strings[mem1],1,pos('=',potokkomand1.strings[mem1])-1);
Msg1:=copy(potokkomand1.strings[mem1],pos('=',potokkomand1.strings[mem1])+1,length(potokkomand1.strings[mem1]) - pos('=',potokkomand1.strings[mem1]));
potokkomand1.Delete(mem1);
Form1.obrabotchik1(UIN1, Msg1);
end;
end;
end;
Это просто мелкие ошибки. Чтоб узнать в чем причина надо показать весь код относящийся сюда.
__________________
Помогаю за Спасибо
|