Results 1 to 3 of 3

Find Next Empty Cell

Threaded View

  1. #1
    Forum Contributor
    Join Date
    02-05-2010
    Location
    Exeter, England
    MS-Off Ver
    Excel 2007 & 2010
    Posts
    180

    Find Next Empty Cell

    Hi,

    I would like some help please to find next empty cell. My cells are C18, H18, C33,H33, C48 and H48. I would like a code that first looks at C18 and if its empty insert here if not then H18 if thats empty insert here if not then C33 ...and so on to H48.

    I started to create the following code (not complete) but I'm sure there must be better way

    Private Sub CommandButton1_Click()
    
    If Range("C18") = "" Then
    Range("C18").Value = TextBox1.Value
    Else
    If Range("H18") = "" Then
    Range("H18").Value = TextBox1.Value
    
    End If
    End If
    Unload Me
    End Sub
    Last edited by zimbo109; 05-14-2010 at 02:03 PM. Reason: spelling

Thread Information

Users Browsing this Thread

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

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