Results 1 to 3 of 3

Thread: Im still a beginner and i need help with this code

  1. #1

    Thread Starter
    New Member
    Join Date
    May 2009
    Posts
    7

    Im still a beginner and i need help with this code

    Okay, so the error message says "Block If without End If"....any suggestions?


    Private Sub Timer1_Timer()

    intCounter = intCounter + 1
    If intCounter = 185000 Then
    MsgBox "Times up!", vbInformation + OKOnly, "UR SO SLOW"
    If Response = vbOK Then
    Unload Me
    Timer1.Enabled = False

    End If
    lblTimer = intCounter
    End Sub

  2. #2
    VB Addict Pradeep1210's Avatar
    Join Date
    Apr 2004
    Location
    Inside the CPU...
    Posts
    6,614

    Re: Im still a beginner and i need help with this code

    If you indent your code properly, you will find that you have two IF statements but only one END IF.
    Pradeep, Microsoft MVP (Visual Basic)
    Please appreciate posts that have helped you by clicking icon on the left of the post.
    "A problem well stated is a problem half solved." — Charles F. Kettering

    Read articles on My Blog101 LINQ SamplesJSON ValidatorXML Schema Validator"How Do I" videos on MSDNVB.NET and C# ComparisonGood Coding PracticesVBForums Reputation SaverString EnumSuper Simple Tetris Game


    (2010-2013)
    NB: I do not answer coding questions via PM. If you want my help, then make a post and PM me it's link. If I can help, trust me I will...

  3. #3

    Thread Starter
    New Member
    Join Date
    May 2009
    Posts
    7

    Re: Im still a beginner and i need help with this code

    OOooooo gotcha buds, thanks really much

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