Delphi - Como mover Timage con el teclado

 
Vista:

Como mover Timage con el teclado

Publicado por *** MS *** (42 intervenciones) el 12/08/2010 00:40:26
quiero saber como puedo mover un Timage pulsando las teclas izquierda, derecha, arriba y abajo
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder

RE:Como mover Timage con el teclado

Publicado por *** MS *** (42 intervenciones) el 12/08/2010 05:14:46
Yo mismo me respondo

begin
if key = VK_LEFT then
image2.left:=image2.left-5 else
if key = VK_RIGHT then
image2.left:=image2.left+5 else
if key = VK_UP then
image2.top:=image2.top-5 else
if key = VK_DOWN then
image2.top:=image2.top+5;
end;
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar