+ Reply to Thread
Results 1 to 4 of 4

find last empty cell and highlight yellow

Hybrid View

  1. #1
    Registered User
    Join Date
    01-26-2014
    Location
    Sydney
    MS-Off Ver
    Excel 2013
    Posts
    93

    find last empty cell and highlight yellow

    I am using this code which finds the next empty cell after data.What do i need to change in the code so the cell also fills in with color Yellow?

    Thank you

    James

    Private Sub CommandButton1_Click()
    ActiveSheet.Range("A" & Rows.Count).End(xlUp).Offset(1, 0).Select
    Interior.Color = 65535
    End Sub

  2. #2
    Forum Expert
    Join Date
    06-12-2012
    Location
    Ridgefield Park, New Jersey
    MS-Off Ver
    Excel 2003,2007,2010
    Posts
    10,241

    Re: find last empty cell and highlight yellow

    Maybe:

    Sub James_S()
    ActiveSheet.Range("A" & Rows.count).End(xlUp).Offset(1, 0).Interior.ColorIndex = 6
    End Sub

  3. #3
    Forum Expert Olly's Avatar
    Join Date
    09-10-2013
    Location
    Darlington, UK
    MS-Off Ver
    Excel 2016, 2019, 365
    Posts
    6,284

    Re: find last empty cell and highlight yellow

    You're very nearly there!

    Private Sub CommandButton1_Click()
    ActiveSheet.Range("A" & Rows.Count).End(xlUp).Offset(1, 0).Interior.Color = 65535
    End Sub
    No need to select it first
    let Source = #table({"Question","Thread", "User"},{{"Answered","Mark Solved", "Add Reputation"}}) in Source

    If I give you Power Query (Get & Transform Data) code, and you don't know what to do with it, then CLICK HERE

    Walking the tightrope between genius and eejit...

  4. #4
    Registered User
    Join Date
    01-26-2014
    Location
    Sydney
    MS-Off Ver
    Excel 2013
    Posts
    93

    Re: find last empty cell and highlight yellow

    Thank you it works

+ 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. [SOLVED] Find number and highlight in yellow
    By Jerry HKA in forum Excel Programming / VBA / Macros
    Replies: 15
    Last Post: 02-10-2014, 04:17 AM
  2. [SOLVED] Highlight Yellow Active Row, PROBLEM: row selected before closing stays yellow
    By NumberCruncher311 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 02-12-2013, 07:01 PM
  3. [SOLVED] How to find first and last non empty cell in row and highlight between?
    By Puzzles in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 01-27-2013, 02:58 PM
  4. Macro To find match Value from other clomn and highlight in yellow
    By tariqnaz2005 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-16-2012, 09:42 AM
  5. How to make the empty cell become yellow? (SOLVED)
    By Lewis Koh in forum Excel General
    Replies: 2
    Last Post: 06-04-2010, 10:11 AM

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