Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

Excel help

  • 29-07-2019 01:35PM
    #1
    Registered Users, Registered Users 2 Posts: 14


    Hi All. I need some help with an Excel issue.
    I have a macro to create a monthly invoice from the master data sheet. However I need to repeat the macro for each row in the master data sheet, stopping at the last row. The number of rows vary month to month.

    Appreciate any help.


Comments

  • Registered Users, Registered Users 2 Posts: 2,418 ✭✭✭antix80


    Counting the number of non-blank cells in the column headed "invoice number" should work.
    The excel function is COUNTA(A:A) and then you'll have to do a for loop (for x = 1 to numberOfNonBlankCells)


Advertisement