+ Reply to Thread
Results 1 to 8 of 8

Userform select last entry and delete them

  1. #1
    Registered User
    Join Date
    05-05-2020
    Location
    Germany
    MS-Off Ver
    2013
    Posts
    82

    Userform select last entry and delete them

    Hi

    How can I chose the last 2 cells in 2 columns and delete them?

    I created a userform, which saves the data either in column D and E or Column D, E and F, depending on the user's choice. Now I want to add 2 buttons (for each choice) that will delete the last entry.

    other columns are filled and the row shouldn't be deleted.

  2. #2
    Forum Expert BadlySpelledBuoy's Avatar
    Join Date
    06-14-2013
    Location
    East Sussex
    MS-Off Ver
    365
    Posts
    5,681

    Re: Userform select last entry and delete them

    Assuming you meant Tabelle2 from the attachment in your other thread, this will delete the values from the last populated row in D:E
    Please Login or Register  to view this content.
    And this the same from D:F
    Please Login or Register  to view this content.
    Is that what you meant?

    BSB

  3. #3
    Registered User
    Join Date
    05-05-2020
    Location
    Germany
    MS-Off Ver
    2013
    Posts
    82

    Re: Userform select last entry and delete them

    Quote Originally Posted by BadlySpelledBuoy View Post
    Assuming you meant Tabelle2 from the attachment in your other thread, this will delete the values from the last populated row in D:E
    Please Login or Register  to view this content.
    And this the same from D:F
    Please Login or Register  to view this content.
    Is that what you meant?

    BSB
    Yes it's for the same userform
    I added few lines, so that it'll ask for confirmation before deleting, but now it doesn't delete

    Please Login or Register  to view this content.
    Last edited by (T_T); 09-14-2020 at 08:32 AM.

  4. #4
    Forum Expert BadlySpelledBuoy's Avatar
    Join Date
    06-14-2013
    Location
    East Sussex
    MS-Off Ver
    365
    Posts
    5,681

    Re: Userform select last entry and delete them

    Try this:
    Please Login or Register  to view this content.
    BSB

  5. #5
    Registered User
    Join Date
    05-05-2020
    Location
    Germany
    MS-Off Ver
    2013
    Posts
    82

    Re: Userform select last entry and delete them

    Quote Originally Posted by BadlySpelledBuoy View Post
    Try this:
    Please Login or Register  to view this content.
    BSB
    It's the same when I click on yes nothing happens

  6. #6
    Forum Expert BadlySpelledBuoy's Avatar
    Join Date
    06-14-2013
    Location
    East Sussex
    MS-Off Ver
    365
    Posts
    5,681

    Re: Userform select last entry and delete them

    I see the whole code you've added?

    BSB

  7. #7
    Registered User
    Join Date
    05-05-2020
    Location
    Germany
    MS-Off Ver
    2013
    Posts
    82

    Re: Userform select last entry and delete them

    I just realized that I didn't change the sheet name (*∩~∩)

    it works fine
    thank you

  8. #8
    Forum Expert BadlySpelledBuoy's Avatar
    Join Date
    06-14-2013
    Location
    East Sussex
    MS-Off Ver
    365
    Posts
    5,681

    Re: Userform select last entry and delete them

    Excellent news. Glad I could help.

    BSB

+ 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] Select Table entry from list and delete?
    By Kevchenk0 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 07-01-2020, 09:56 AM
  2. Delete an entry (row) in a userform listbox and update table on worksheet
    By colin7 in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 08-08-2019, 07:18 AM
  3. Macro For Userform Entry that will Cut, Delete, and Paste Row
    By Kyhosa in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 04-17-2019, 11:06 AM
  4. [SOLVED] Select List box entry based on List box on another userform. --> Edit data on next userfor
    By travelkid in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 01-28-2019, 12:46 PM
  5. userform code to add or delete entry with condition
    By padreSlo in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 09-01-2018, 09:05 AM
  6. Update and delete entry in Datasheet via Userform
    By Magnet in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-11-2012, 09:50 AM
  7. delete entry on worksheet via userform listbox
    By confused325 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-21-2009, 12:19 PM

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