|
-
Aug 31st, 2000, 04:52 PM
#1
Thread Starter
Lively Member
I am making a slot machine game. well to put coins in you click on a money bag and drag it up to the coin slot. you can put up to 3 coins in. But I have a problem. When I put this in the destination control:
Code:
Private Sub hhh_DragDrop(Source As Control, X As Single, Y As Single)
coinsin = coinsin + 1
Label3.Caption = "Coins In:" & coinsin
End Sub
It displays one coin in but when you go to put more coins in it doesnt show!!! HELP!!
Frankie Weindel
VB 6 Learning Edtion SP3
-
Aug 31st, 2000, 05:07 PM
#2
Where do you have coinsin declared?
-
Aug 31st, 2000, 05:10 PM
#3
Fanatic Member
Change your code to this:
Code:
Private Sub hhh_DragDrop(Source As Control, X As Single, Y As Single)
Static coinsin As Integer
coinsin = coinsin + 1
Label3.Caption = "Coins In:" & coinsin
End Sub
This should solve the problem.
-
Aug 31st, 2000, 05:31 PM
#4
Thread Starter
Lively Member
Frankie Weindel
VB 6 Learning Edtion SP3
-
Aug 31st, 2000, 05:36 PM
#5
Fanatic Member
Strange, it works fine for me. Can you give me some more code, maybe there's a bug somewhere.
-
Aug 31st, 2000, 07:01 PM
#6
Thread Starter
Lively Member
Frankie Weindel
VB 6 Learning Edtion SP3
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|