Results 1 to 16 of 16

VBA code for 2 buttons that can clear cells in a row then second button to bring data back

Threaded View

Hillster VBA code for 2 buttons that... 11-02-2019, 10:55 PM
BanginMyHeadOnMyDesk Re: VBA code for 2 buttons... 11-03-2019, 05:25 AM
Hillster Re: VBA code for 2 buttons... 11-03-2019, 08:07 AM
BanginMyHeadOnMyDesk Re: VBA code for 2 buttons... 11-03-2019, 09:37 AM
LJMetzger Re: VBA code for 2 buttons... 11-03-2019, 04:19 PM
Hillster Re: VBA code for 2 buttons... 11-03-2019, 09:41 PM
LJMetzger Re: VBA code for 2 buttons... 11-04-2019, 10:26 AM
Hillster Re: VBA code for 2 buttons... 11-03-2019, 09:47 PM
Logit Re: VBA code for 2 buttons... 11-03-2019, 11:53 PM
Hillster Re: VBA code for 2 buttons... 11-04-2019, 07:44 AM
Logit Re: VBA code for 2 buttons... 11-04-2019, 01:19 PM
Hillster Re: VBA code for 2 buttons... 11-04-2019, 01:44 PM
Logit Re: VBA code for 2 buttons... 11-04-2019, 02:09 PM
Hillster Re: VBA code for 2 buttons... 11-04-2019, 03:15 PM
Logit Re: VBA code for 2 buttons... 11-04-2019, 06:34 PM
Hillster Re: VBA code for 2 buttons... 11-08-2019, 09:14 PM
  1. #3
    Forum Contributor
    Join Date
    09-09-2012
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    176

    Re: VBA code for 2 buttons that can clear cells in a row then second button to bring data

    Hey BanginmyHeadOnMyDesk,

    1) When you click Clear the first time will it remove the first column of data, second time the second one etc.?

    Answer: Correct, 1st click removes Row 5 Data, second click removes 6 row Data, etc....

    2) Clicking Retrieve should bring them back in the reverse order of how they were removed?

    Answer: Correct, so if i click Clear 99 times, i am going to have to click Retrieve 99 times. That is the best part of the whole process. exactly what i want to have to do... BUT.... Upon exiting the workbook, the VBA will retrieve all the data back to its original state.

    3) Do they need to be removed or could they just be hidden?

    Answer: So the possible tricky part.... I would say Removed or Replaced actually.

    Explanation: I have other cells referencing Row 5.... Row 5 is the "Key" Row and the cells that are referencing it are in other sheets so..... in all reality, when the user clicks the "Clear" button, VBA will retrieve all the data starting at Row 6 and below then paste it over the top of Row 5's data... The result after one Click of the clear button: Row 6 data is now in Row 5. All the data gets bumped up one row and the original data that once was in Row 5 is now gone UNTIL the user clicks the "Retrieve" button, then VBA pushes all of the data back down by one row and the original Row 5 data is back again. So there always has to be data in Row 5..... Make sense? Then as a reminder, when the user exits the workbook, VBA will ensure all data is back to it's original state as if the "Clear" button was never clicked
    Last edited by Hillster; 11-03-2019 at 08:18 AM.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 1
    Last Post: 12-12-2017, 12:49 PM
  2. [SOLVED] Help with code to creat Reset button to clear cells and copy back the original formula
    By rv02 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 07-30-2015, 02:25 PM
  3. Array Formula Lookup - Bring back Lowest Date + Bring Back Cell Location
    By Matt1998 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 06-04-2014, 12:08 PM
  4. Replies: 3
    Last Post: 06-05-2012, 04:36 AM
  5. Replies: 2
    Last Post: 02-09-2009, 05:07 AM
  6. Create a button to clear data in certain cells
    By headbanger51 in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 01-07-2008, 03:18 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