+ Reply to Thread
Results 1 to 7 of 7

Repeat Macro until until blank cell/row

  1. #1
    Registered User
    Join Date
    03-11-2014
    Location
    Melbourne
    MS-Off Ver
    Excel 2013
    Posts
    8

    Repeat Macro until until blank cell/row

    Hi Everyone,

    Hoping you can help me with a macro I'm trying to write. I am trying to create a series of templates (over 1000) so would love for a macro to create them for me. I have the form in excel populated from row 2 in another sheet. I have successfully got it to save as a pdf:

    Please Login or Register  to view this content.
    However when I try to get it to loop until no more data on the other sheet it doesn't work. This is the code I have tried to write:

    Please Login or Register  to view this content.
    Any help would be greatly appreciated.

    Cheers,

    Andrew
    Attached Files Attached Files
    Last edited by AndrewHowarth; 09-29-2015 at 02:37 AM. Reason: Adding Attachment

  2. #2
    Forum Expert
    Join Date
    12-10-2006
    Location
    Sydney
    MS-Off Ver
    Office 365
    Posts
    3,525

    Re: Repeat Macro until until blank cell/row

    Hi Andrew,

    Could you attach a copy of the workbook (devoid of sensitive data) as it's quite hard to write a solution without having that. Also, won't the file name in cell C14 need be changed each time?

    Robert
    Last edited by Trebor76; 09-29-2015 at 02:34 AM.
    ____________________________________________
    Please ensure you mark your thread as Solved once it is. Click here to see how
    If this post helps, please don't forget to say thanks by clicking the star icon in the bottom left-hand corner of my post

  3. #3
    Registered User
    Join Date
    03-11-2014
    Location
    Melbourne
    MS-Off Ver
    Excel 2013
    Posts
    8

    Re: Repeat Macro until until blank cell/row

    Hi Robert - added attachment to original post now.

    Also the file name in C14 will update from the other sheet "Store List" as the details are moved up to row 2.

    Thanks,

    Andrew
    Last edited by AndrewHowarth; 09-29-2015 at 02:53 AM.

  4. #4
    Forum Expert
    Join Date
    12-10-2006
    Location
    Sydney
    MS-Off Ver
    Office 365
    Posts
    3,525

    Re: Repeat Macro until until blank cell/row

    I have to dash now but I'll try and have look later tonight.

    My thought is to loop through all the records in the Store List tab, change the formulas in the Payment Form tab to the appropriate row in the Store List tab, PDF the result and start again.

    Would this suffice?

    Robert

  5. #5
    Forum Expert
    Join Date
    12-10-2006
    Location
    Sydney
    MS-Off Ver
    Office 365
    Posts
    3,525

    Re: Repeat Macro until until blank cell/row

    Hi Andrew,

    Try this:

    Please Login or Register  to view this content.
    Note you have the same formula in cells C12 and C16 of the Payment Form (hopefully the way I've set the macro up you'll easily see where that would have to be changed).

    Regards,

    Robert

  6. #6
    Registered User
    Join Date
    03-11-2014
    Location
    Melbourne
    MS-Off Ver
    Excel 2013
    Posts
    8

    Re: Repeat Macro until until blank cell/row

    Hi Robert,

    Thanks very much for this - works like a dream! No issue with the same formula being in cells C12 and C16, works great.

    Thanks again.

    Andrew

  7. #7
    Forum Expert
    Join Date
    12-10-2006
    Location
    Sydney
    MS-Off Ver
    Office 365
    Posts
    3,525

    Re: Repeat Macro until until blank cell/row

    Thanks very much for this - works like a dream!
    You're welcome. Thanks for marking the thread as solved and for the rep

    Regards,

    Robert

+ 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] repeat counting of blank cells till a cell with number/text
    By joshcct in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-03-2015, 03:33 AM
  2. [SOLVED] Need VBA Macro to Copy and paste column data in blank rows and repeat through spreadsheet
    By slk1186 in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 08-07-2014, 12:50 PM
  3. Count blank cells macro repeat
    By AG52014 in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 06-14-2014, 06:37 PM
  4. Macro to repeat filling in certain blank cells
    By lora2014 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 01-02-2014, 11:51 PM
  5. Refrence next blank cell to repeat VBA Code
    By SirAustin1 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-11-2011, 02:22 AM
  6. Repeat cell above (fill blank)
    By JanSurrey in forum Excel Formulas & Functions
    Replies: 12
    Last Post: 02-04-2008, 11:23 AM
  7. [SOLVED] Copy data in one cell to blank cell immediately below, repeat
    By Jeff in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 05-19-2006, 02:15 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