+ Reply to Thread
Results 1 to 3 of 3

Syntax Error Finding Last Row

  1. #1
    Forum Contributor
    Join Date
    06-18-2010
    Location
    USA
    MS-Off Ver
    Excel 2016
    Posts
    546

    Syntax Error Finding Last Row

    I am attempting to find the last row with data in column G and clear everything after a . My syntax will clear fine if I hardcode cells to search, but since adding in the last cell it throws an error of Invalid Syntax. What do I need to change to make this valid syntax?

    Please Login or Register  to view this content.

  2. #2
    Forum Expert
    Join Date
    11-22-2016
    Location
    Cornwall,UK
    MS-Off Ver
    office 365
    Posts
    4,240

    Re: Syntax Error Finding Last Row

    Try:
    Please Login or Register  to view this content.
    instead of:
    Please Login or Register  to view this content.
    So remove the 2nd colon ( : ) and insert the ampersand symbol ( & ) after the quotation marks
    Last edited by kev_; 02-06-2017 at 09:48 AM.
    Click *Add Reputation to thank those who helped you. Ask if anything is not clear

  3. #3
    Forum Contributor
    Join Date
    06-18-2010
    Location
    USA
    MS-Off Ver
    Excel 2016
    Posts
    546

    Re: Syntax Error Finding Last Row

    Excellent! Thank you!

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. VBA - Finding the average of a range and ignoring zeroes - syntax question
    By lordterrin in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 05-02-2014, 12:56 PM
  2. Excel macro (compile error. syntax error.) error
    By salar_younis in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 01-06-2014, 06:11 AM
  3. [SOLVED] first timer using VB to cut and paste macro - getting compile error syntax error
    By jopedder in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 10-24-2013, 11:45 AM
  4. Receiving following error “Complie error : syntax error” Help
    By masond3 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 11-02-2012, 10:19 AM
  5. [SOLVED] Compile Error: Expected Expression, Syntax Error
    By gjohn282 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 09-20-2012, 11:28 PM
  6. Syntax Error and Compile Error: Expected Line Number or Label...
    By AnthonyWB in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 01-31-2011, 09:59 AM
  7. runtime error: syntax error or access violation
    By oucsester in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-03-2006, 12:55 PM

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