+ Reply to Thread
Results 1 to 8 of 8

Delete Unwanted Rows

  1. #1
    Registered User
    Join Date
    02-19-2013
    Location
    Houston, USA
    MS-Off Ver
    Excel 2010
    Posts
    21

    Delete Unwanted Rows

    Hi,

    Here's the code that I wrote to delete all the rows that not empty in column V. However, it did not work. Please help. Thanks.

    Please Login or Register  to view this content.
    Best regards,

    Matt
    Attached Files Attached Files
    Last edited by [email protected]; 07-08-2013 at 10:48 AM.

  2. #2
    Forum Expert
    Join Date
    03-28-2012
    Location
    TBA
    MS-Off Ver
    Office 365
    Posts
    12,454

    Re: Delete Unwanted Rows

    Matt,
    Please use code tags with your code as per forum's rule.
    Do you mean you want to delete a row if column V is EMPTY? Is it entire row?

  3. #3
    Registered User
    Join Date
    02-19-2013
    Location
    Houston, USA
    MS-Off Ver
    Excel 2010
    Posts
    21

    Re: Delete Unwanted Rows

    Here's the X for.

    Dim X As Long
    X = ActiveSheet.UsedRange.Rows.Count

  4. #4
    Registered User
    Join Date
    02-19-2013
    Location
    Houston, USA
    MS-Off Ver
    Excel 2010
    Posts
    21

    Re: Delete Unwanted Rows

    I like to remove the rows that are not Empty. I was not familiar with the code, so I used "=" for a test. Eventually, I will change it to "Not Equal".

  5. #5
    Registered User
    Join Date
    02-19-2013
    Location
    Houston, USA
    MS-Off Ver
    Excel 2010
    Posts
    21

    Re: Delete Unwanted Rows

    Sorry about the rule. I have to learn it first.

  6. #6
    Forum Expert
    Join Date
    03-28-2012
    Location
    TBA
    MS-Off Ver
    Office 365
    Posts
    12,454

    Re: Delete Unwanted Rows

    This line shows that you are testing for empty cell.

    Please Login or Register  to view this content.

  7. #7
    Forum Expert
    Join Date
    03-28-2012
    Location
    TBA
    MS-Off Ver
    Office 365
    Posts
    12,454

    Re: Delete Unwanted Rows

    My code attached.
    Attached Files Attached Files

  8. #8
    Registered User
    Join Date
    02-19-2013
    Location
    Houston, USA
    MS-Off Ver
    Excel 2010
    Posts
    21

    Re: Delete Unwanted Rows

    Thank you very much AB33. Your code worked perfectly, and provided a lot for me to learn as well.

+ Reply to Thread

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