+ Reply to Thread
Results 1 to 3 of 3

VBA rolling +1 total

Hybrid View

Rick-O-Shay VBA rolling +1 total 12-30-2009, 02:32 PM
ncmay Re: VBA rolling +1 total 12-30-2009, 02:39 PM
Rick-O-Shay Re: VBA rolling +1 total 12-30-2009, 02:46 PM
  1. #1
    Forum Contributor
    Join Date
    12-30-2009
    Location
    US
    MS-Off Ver
    Excel 2003, 2010, 2016, 2019, & Office 365
    Posts
    194

    VBA rolling +1 total

    Is there a way to make a VBA code where everytime I run this macro it adds 1 to a cell and keeps a running total?

    Example:

    E17 currently = 0

    Running the macro makes it display 1
    Running it again makes it display 2 etc...
    Last edited by Rick-O-Shay; 12-30-2009 at 02:47 PM. Reason: Solved

  2. #2
    Forum Contributor
    Join Date
    07-24-2009
    Location
    Valrico, FL USA
    MS-Off Ver
    Excel 2016
    Posts
    358

    Re: VBA rolling +1 total

    There is probably a better way than the code below.
    Add this line to your macro.
    Change the sheet reference to suit your needs.

    Sheet1.Range("E17").Value = Sheet1.Range("E17").Value + 1

  3. #3
    Forum Contributor
    Join Date
    12-30-2009
    Location
    US
    MS-Off Ver
    Excel 2003, 2010, 2016, 2019, & Office 365
    Posts
    194

    Re: VBA rolling +1 total

    Thank you so much!

+ 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