+ Reply to Thread
Results 1 to 3 of 3

Next without for error in macro

  1. #1
    Registered User
    Join Date
    06-05-2012
    Location
    Boston, Mass
    MS-Off Ver
    Excel 2007
    Posts
    10

    Next without for error in macro

    I have code for a button that works aI would like to add an If statement that only changes the text in that cell if it already equals a specific value,
    the orriginal code is:

    Please Login or Register  to view this content.
    i tried

    Please Login or Register  to view this content.
    But it keeps giving me the error "Next without For"

  2. #2
    Forum Contributor arlu1201's Avatar
    Join Date
    09-09-2011
    Location
    Bangalore, India
    MS-Off Ver
    Excel 2003 & 2007
    Posts
    19,166

    Re: Next without for error in macro

    Change the 2nd code to
    Please Login or Register  to view this content.
    If I have helped, Don't forget to add to my reputation (click on the star below the post)
    Don't forget to mark threads as "Solved" (Thread Tools->Mark thread as Solved)
    Use code tags when posting your VBA code: [code] Your code here [/code]

  3. #3
    Registered User
    Join Date
    06-05-2012
    Location
    Boston, Mass
    MS-Off Ver
    Excel 2007
    Posts
    10

    Re: Next without for error in macro

    Thank you, that fixed it.

+ 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