Click to See Complete Forum and Search --> : Turtle drawing !!!
1. Does anyone know a way of identifying the UP, DOWN, LEFT and RIGHT arrow keys in the keypress event?
2. Does anyone know how to stop a picture box from being cleared when the form loses focus.
my picture box goes blank each time the form is hiddn beneath another program.
I really only need the up / down arrows to do a "Doskey"-type command-recalling sub routine.
Both of the above questions relate to a program that i am writing, which is a clone of "LOGO" (remember the turtle
drawing program?), i will happily send you a free copy of the finished article (not that i plan to sell it anyway).
The program is in its final stages now, and this would really help me a lot!
"Tilde bitter end!" ~&&
------------------
Wossname,
Email me: wossnamex@talk21.com :)
Yonatan
Dec 2nd, 1999, 01:46 AM
Up, Down, Left and Right keys get the vbKeyUp, vbKeyDown, vbKeyLeft and vbKeyRight key codes.
To stop a picture from being cleared, set its AutoRedraw property to True.
------------------
Yonatan
Teenage Programmer
E-Mail: RZvika@netvision.net.il
ICQ: 19552879 (http://www.icq.com/19552879)
AIM: RYoni69
Serge
Dec 2nd, 1999, 01:46 AM
For the arrow keys:
You can use KeyDown, KeyUp event to check if on of those keys was pressed.
Private Sub Text1_KeyDown(KeyCode As Integer, Shift As Integer)
Select Case KeyCode
Case vbKeyDown
'Do your down key function
Case vbKeyUp
'Do your up key function
Case vbKeyLeft
'Do your left key function
Case vbKeyRight
'Do your right key function
End Select
End Sub
------------------
Serge
Software Developer
Serge_Dymkov@vertexinc.com
Access8484@aol.com
ICQ#: 51055819 (http://www.icq.com/51055819)
swarnalatha
Dec 2nd, 1999, 01:47 AM
The answer for the second question is, Set the redraw property of the picturebox to be true
Latha
wow! 3 responses within 2 minutes of each other!!
thanks guys, it seems so obvious now!
I was trying everyting i could think of:
vbLeftArrow, vbLArrow, vbLeftKey etc...
and i was just testin' ya about the auto redraw thing i knew that already! (yeah, right woss!)
Thanks again, Yonatan and Serge automatically get a copy of the LOGO clone (if they want one or not), and swarnalatha can have on too if he/she sends me his/her email addy!
Watch out Mr. Gates, here i come!
------------------
Wossname,
Email me: wossnamex@talk21.com :)
Bob Baddeley
Dec 2nd, 1999, 07:14 AM
I remember logo. It was awesome. I remember doing it in 7th grade in math class and we had to synchronize it with music. Needless to say, mine was the best (programming is so much fun). I'm sorry I didn't get here soon enough to respond to your question, but I would really appreciate a copy of your program.
Thanks,
bob
bobbaddeley@hotmail.com
jritchie
Dec 2nd, 1999, 08:31 AM
Could l get a copy as well. Have been looking for over a year for a copy for my son. What l am attempting to do is produce a kind of cut down computer language to teach sub-teens the wonders of computing, (gee all those late nights non-responsive users etc).
Regards,
Jeff Ritchie (jritchie@genauto.com)
Tonio169
Dec 2nd, 1999, 09:42 AM
i have no idea what your program is but i would appreciate it if you could give me copy as well.
onerrorgoto
Dec 2nd, 1999, 08:24 PM
I'm greedy :D
I want two copies ;)
Just kidding, it would be cool to see your program since I cant recall ever using LOGO.
If you need more help, dont hesitate to "call". I'm here everyday :)
------------------
On Error Goto Bed :0)
anders@zsystemdesign.se
[This message has been edited by onerrorgoto (edited 12-03-1999).]
ok fellas you got it!
uhh tonio, dude could you, like, give me your addy or something.
for those who dont know LOGO, youll know it when you see this. the only thing i havent been able to figure out yet is how to get the actual turtle on the screen! instead im using a label with the heading in text: 354 (degrees).
ill do a readme file too, so it could take a few days to arrive, dont worry though it will eventually!
------------------
Wossname,
Email me: wossnamex@talk21.com :)
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.