Results 1 to 3 of 3

Thread: Click HELP!!!!

  1. #1

    Thread Starter
    New Member
    Join Date
    Oct 2006
    Posts
    12

    Exclamation Click HELP!!!!

    I am new to this forum and programming
    I am trying to create a program in which when you click the button it counts how mnay clicks you do. i have came across some problems can someone help?


    ) When you click on the "button" it show it while clicking but when you let go it disappears. i want to let go and it stay there and change
    1,2, 3 etc.

    ) what must you do for it to clear the picbox and restart count?


    ) i also want the game to it prompts for a number as a time value 20 secons andwhen you click the button it starts at the value and you can see the timer and counts down and records the clicks. once the set time is up the button is disabled.


    Help?






    VB Code:
    1. Dim num As Integer
    2.  
    3. Private Sub cmdclick_Click()
    4. picscore.Cls
    5. NumberCount = 1
    6.  
    7. End Sub
    8.  
    9. Private Sub cmdclick_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
    10. num = num + 1
    11.  
    12. picscore.Print num
    13. End Sub
    14.  
    15.  
    16.  
    17. Private Sub cmdprocess_Click()
    18.  '
    19.  '
    20.  '
    21.  
    22.  Dim Names As String, Location As Single, First As String, Last As String
    23.  picscore.Cls
    24.  nom = Val(txtname.Text)
    25.  Locations = InStr(nom, " ")
    26.  First = Left(nom, Locations - 1)
    27.  Last = Right(nom, Len(nom) - Locations)
    28.  ScoreRound = Round(FormatNumber(Score, Number))
    29.  Number = (txtdec.Text)
    30.  
    31.  picscore.Print First; " "; ","
    32.  picscore.Print "Your Score Is:"
    33.  picscore.Print Last
    34. End Sub
    35.  
    36. Private Sub cmdquit_Click()
    37. End
    38. End Sub
    39.  
    40. Private Sub Command1_Click()
    41. NumberCount = 1
    42. End Sub

  2. #2
    Banned timeshifter's Avatar
    Join Date
    Mar 2004
    Location
    at my desk
    Posts
    2,465

    Re: Click HELP!!!!

    VB Code:
    1. Option Explicit
    2.  
    3. Dim ClickCounter As Integer
    4.  
    5. Private Sub Command1_Click()
    6.  
    7. ClickCounter = ClickCounter + 1
    8.  
    9. End Sub

  3. #3
    Banned timeshifter's Avatar
    Join Date
    Mar 2004
    Location
    at my desk
    Posts
    2,465

    Re: Click HELP!!!!

    Just put If...Then statements after each click to direct the program to whatever function needs to happen when certain criteria are reached.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width