Results 1 to 7 of 7

Deleting items from a spreadsheet based off of combo box selection

Threaded View

  1. #1
    Forum Contributor
    Join Date
    05-20-2013
    Location
    Ann Arbor, MI
    MS-Off Ver
    Excel 2010
    Posts
    255

    Deleting items from a spreadsheet based off of combo box selection

    Currently, I have a combo box that is populated from a specific column in a spread sheet. On the userform, there is an Update page where I want the user to be able to choose something already in the combobox, and then press "delete from list." Is there a way for me to this?

    Below is the code i'm currently using, but i'm getting "Run-Time Error '5': Invalid procedure call or argument" (I'm very new to vba)

    Private Sub delLocateBTN_Click()

    With Worksheets("READ ONLY")
    If .Cells("F").Value = DelLocationcb.Value Then
    .Cells("F").Select ' select the row
    Selection.EntireRow.Delete ' now delete the entire row
    ThisWorkbook.Save
    End If
    End With



    End Sub
    Last edited by emilyloz; 05-29-2013 at 09:43 AM.

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