Skip to main content
GameDev.net gamedev.net
🔒 Locked

lol

Started by bkw4ever Jun 12, 2008 at 1:29 PM 20 replies 3.5k views
Original Post
bkw4ever
bkw4ever
ok so basically the problem is this: im an idiot i am currently programming in vb 6( i know lol i know) and will possibly be stuck with it for awhile.... i dont get why this doesnt work: private sub Form_KeyUp(KeyCode as integer, Shift as integer) if KeyCode = 50 then 'do this end if end sub its pseudo obviously but i just dont get why i cant get any form key event to work.. whether i work with ascii or keycode it just doesnt work.... Help please!!
WOW YOU HAVE TOO MUCH TIME ON YOUR HANDS
PaulCesar
PaulCesar
Quote:
ok so basically the problem is this: im an idiot


lol

I dont know BASIC at all, but have you checked to make sure that Form_Keyup is even being called in the first place? Try putting a message box or debug break in there and make sure its hitting the function. If that doesent work then you need to get that working first. Then I would look at what the keycode is currently set to. Like I said, I know nothing about BASIC, but there are many ways a keycode can be represented.

Hope this helps
bkw4ever
bkw4ever
yea thanks... i tried to set a label.caption to the keycode because i believe that when a key is pressed a keycode is sent to the user(if that makes sense).. but it doesnt display... ill try to set it to 0 but i cant imagine that working... the worst part is ive done this before but it just wont work

i wish i could just say ...

VisualBasic.isKeyPressed("space");
lol
WOW YOU HAVE TOO MUCH TIME ON YOUR HANDS
programmermattc
programmermattc
Quote:
Original post by bkw4ever
ok so basically the problem is this: im an idiot


I saw this line and immediately thought, 'this' inherits from the 'im an idiot' class.
=============================RhinoXNA - Easily start building 2D games in XNA!Projects
bkw4ever
bkw4ever
well i dont have internet on my pc so i need someway to get an installer onto a flash but cant figure it out.. so im stuck with 6.0
WOW YOU HAVE TOO MUCH TIME ON YOUR HANDS
CableGuy
CableGuy
I remember when I programmed with VB6 ions ago there was something like Debug.print.
So try printing the keyCode value, this might help.
smr
smr
Put your cursor on the line "If KeyCode = 50 Then". Press [F9] on your keyboard. This will set a breakpoint. Run your program. Press a key. The program will break. Focus on the "Immediate Window" in the VB6 development environment. Type "print KeyCode". See what it says. Now you've learned how to use breakpoints and the immediate window. I don't recall how to get to the Watch and Locals windows, but those would be preferable over typing "print KeyCode". See if you can find them on your own.
benryves
benryves
Quote:
Original post by bkw4ever
well i dont have internet on my pc so i need someway to get an installer onto a flash but cant figure it out.. so im stuck with 6.0
Visual Studio 2008 Express Offline Installer. Just copy it to a Flash drive or burn to a DVD and you're all set. [smile]
[Website] [+++ Divide By Cucumber Error. Please Reinstall Universe And Reboot +++]
bkw4ever
bkw4ever
.......... i donwloaded that yesterday for four hours but when it didnt do anything i deleted it..........
WOW YOU HAVE TOO MUCH TIME ON YOUR HANDS
bkw4ever
bkw4ever
ok so i didnt delete it i have a winrar archive called VS2008ExpressENUX1397868 its 916,122 kb if that sounds right.. when i extract the files all it has is a readme file so yea idk.......
WOW YOU HAVE TOO MUCH TIME ON YOUR HANDS
bkw4ever
bkw4ever
the read me file says this



"This disc contains a "UDF" file system and requires an operating system
that supports the ISO-13346 "UDF" file system specification."
WOW YOU HAVE TOO MUCH TIME ON YOUR HANDS
bkw4ever
bkw4ever
yea so is this it... im so confused

http://www.microsoft.com/downloadS/details.aspx?FamilyID=5fbbc453-cd04-4562-a66e-5c21436e6f56&displaylang=en
WOW YOU HAVE TOO MUCH TIME ON YOUR HANDS
bkw4ever
bkw4ever
ok well i am still not understanding whats going on... if anyone would do this for me i can discuss payment arrangements in a pm
WOW YOU HAVE TOO MUCH TIME ON YOUR HANDS
danishgoel
danishgoel
Hi,

Well That's the right File. Its ans .iso file in UDF Format. You have to Burn it on a DVD using a program That Supports UDF Format Files Like Nero, Roxio etc..

Or You Can Extract it Using A software Such as MagicISO etc..

Then You will Be able to Install It.

I have The same version for Visual C++ on My comp and I burned it onto a DVD and Then Installed it.

Hope this helps.

Danish :-)
bkw4ever
bkw4ever
i dont have any burnable discs handy thats the thing
WOW YOU HAVE TOO MUCH TIME ON YOUR HANDS
daviangel
daviangel
I still got VB6 installed and this works fine for me:
Private Sub Form_KeyDown(KeyCode As Integer, Shift As Integer)If KeyCode = 27 ThenMsgBox ("wazzup")End If

I also suggest you move on to VB2008 express as has been suggested and if you cannot download/burn it just about any VB2008 book at the bookstore most likely comes with a copy of the express versions on dvd. At least most of my VB2005 books did.
p.s. 27 is the escape key if you didn't already know so this points out why "magic numbers" aren't a good idea to use in the first place!

[Edited by - daviangel on June 13, 2008 2:31:19 AM]
[size="2"]Don't talk about writing games, don't write design docs, don't spend your time on web boards. Sit in your house write 20 games when you complete them you will either want to do it the rest of your life or not * Andre Lamothe
bkw4ever
bkw4ever
oh ok good idea ill steal a copy lol jk yea ill check it out thanks
WOW YOU HAVE TOO MUCH TIME ON YOUR HANDS
Bonedry
Bonedry
Quote:
Original post by bkw4ever
i dont have any burnable discs handy thats the thing


You can install a virtual CD/DVD reader, like Daemon Tools, by which you can mount the image file (.iso) without burning it.
bkw4ever
bkw4ever
i know it doesnt make sense ive done this before same exact code, ive seen it work hundreds of times but it just isnt working idk what the problem is
WOW YOU HAVE TOO MUCH TIME ON YOUR HANDS

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.