Registriert seit: 30. Mai 2007
Ort: Leipzig
78 Beiträge
|
Re: Hilfe bei If then else
13. Mai 2009, 11:31
ja delay sind drin
Delphi-Quellcode:
var
Text: String;
Begin
Text:= 'Private';
{andere Anweisungen}
if RadioButton2.Checked then //Private
begin
for i := 1 to 10 do
begin
handle1 := FindWindow('wxWindowClassNR', PCHar(Edit1.Text));
handle1 := FindWindowEx(handle1, 0, 'wxWindowClassNR', 'ID_PANEL1');
handle1 := FindWindowEx(handle1, 0, 'wxWindowClass', 'ID_LISTBOOK1');
handle1 := FindWindowEx(handle1, 0, 'wxWindowClassNR', 'ID_SCROLLEDWINDOW6');
handle4 := GetDlgItem(handle1, 428);
handle3 := GetDlgItem(handle1, 430);
handle2 := GetDlgItem(handle1, 426);
if (handle1 <> 0) and (handle2 <> 0) then
begin
if trim(GetWintext(handle4)) = Text then
begin
showmessage(Getwintext(handle4));
if EscPressed('Anwendung abbrechen ?') then Break;
delay(6000);
end
else
begin
Showmessage(Getwintext(handle4));
PostMessage(handle4, WM_KEYUP, Integer('P'), 0);
if EscPressed('Anwendung abbrechen ?') then Break;
delay(6000);
end;
end;
end;
end;
|
|
Zitat
|