+ Reply to Thread
Results 1 to 7 of 7

End if and While End Loops

  1. #1
    Registered User
    Join Date
    01-15-2009
    Location
    england
    MS-Off Ver
    Excel 2010
    Posts
    37

    End if and While End Loops

    I am trying to do a number of if then loops whilst inside a while wend loop. I am getting the error . Compile error WEND without While. I have these but obvisouly in my loops it is not rght. I have attached the sheet so you can see what it is doing.

    Thanks for your help
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: End if and While End Loops

    hi, luffield, it looks you are missing End If statement:
    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    01-15-2009
    Location
    england
    MS-Off Ver
    Excel 2010
    Posts
    37

    Re: End if and While End Loops

    Thanks ever such a lot.

  4. #4
    Registered User
    Join Date
    01-15-2009
    Location
    england
    MS-Off Ver
    Excel 2010
    Posts
    37

    Re: End if and While End Loops

    Watersev that works brill, however the last condition code is missing. Any idea's on what else I have got wrong ?

    Thanks again

  5. #5
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: End if and While End Loops

    what do you mean by the last condition code is missing? I copied-pasted all the code in the file plus added End if, didn't I?

  6. #6
    Registered User
    Join Date
    01-15-2009
    Location
    england
    MS-Off Ver
    Excel 2010
    Posts
    37

    Re: End if and While End Loops

    You did . No I think it is my code that is wrong.

    Basically if you run the sheet and look at LG3 Summary the last line has no condition entered in the box on the summary despite it being there on the LG3 tab.

    Sorry to be a pain...

  7. #7
    Forum Expert
    Join Date
    11-29-2010
    Location
    Ukraine
    MS-Off Ver
    Excel 2019
    Posts
    4,168

    Re: End if and While End Loops

    try sort of this:

    Please Login or Register  to view this content.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1