Thema: Delphi Is this correct and Safe

Einzelnen Beitrag anzeigen

sdean

Registriert seit: 5. Dez 2009
64 Beiträge
 
#1

Is this correct and Safe

  Alt 20. Aug 2010, 19:18
Delphi-Version: 2005
I would like to do 3 Loops and each loop gives a Message , but without using IF .. Then

i did it in this way * Is it correct and Safe ... ? *
// in ASM
Delphi-Quellcode:
var
  Str: string;
begin
  Str := 'Just to popup a message without using IF Then';
   try
  Asm
  PushAd
  Xor al,al
    @Loop:Cmp al,3//xLoop //---> 3 loops
          JE @ExitpRoc
         PushAd
            Push 0
            Push 0
            Push Str
            Push 0
            Call MessageBoxA
         PopAd
        Inc al
        Jmp @Loop
  @ExitpRoc:PopAd
  End;
  except
    Exit;
  end;
end;
  Mit Zitat antworten Zitat