Change the direction of a shape with a button

Closed Thread

Join Date: Jul 2004
Posts: 3
Reputation: Maineboy is an unknown quantity at this point 
Solved Threads: 0
Maineboy Maineboy is offline Offline
Newbie Poster

Change the direction of a shape with a button

 
0
  #1
Aug 11th, 2004
I want to change the direction of movement of a shape (Circle) on a Form, using up,down,left,right, buttons placed within a panel also on the Form.

The form contains a shape(Circle) and a TTimer component.

I can get the Circle to move across the Form using :
Circle->Left = Circle->Left + 20; for the OnTimer event, but I now want to change the direction of the Circle using the buttons.

I know I will have to enter similar code in each of the ButtonClick events and I have the feeling that additional code will be required in the OnTimer event handler, but I can't work out what it is.

Please reply to my email with any help.

Regards,

Maineboy.
Quick reply to this message  
Closed Thread

This thread is more than three months old.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC