+ Reply to Thread
Results 1 to 15 of 15

Macro automation help

  1. #1
    Registered User
    Join Date
    12-11-2013
    Location
    nyc
    MS-Off Ver
    M365 V2311
    Posts
    65

    Macro automation help

    Hi guys,

    I am trying to automate a task that would help me save a lot of time and hoping this community can help me out. I am trying to copy and paste the word down a column until it reach the "total line" and right after the "total line", I would like to insert a space.

    Please see attached example.

    Thank you so much for your assistance.

    Yayay
    Attached Files Attached Files

  2. #2
    Registered User
    Join Date
    12-11-2013
    Location
    nyc
    MS-Off Ver
    M365 V2311
    Posts
    65

    Re: Macro automation help

    Now that I read my post, I found it a bit confusing, what I meant to say is that I need a code to copy and paste the value from cell above to the next blank row for column A & B until it reaches the last row. Also, I need to insert a row right below the word "Total".

    Thanks again for taking the time to view my post, much appreciated.

    Regard,
    Yayay

  3. #3
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Macro automation help

    Hi Yayay

    This Code will work on your Sample Data. Please note that I've changed all "total" to "Total" for consistency. CTRL + x will fire the Code.
    Please Login or Register  to view this content.
    Attached Files Attached Files
    John

    If you have issues with Code I've provided, I appreciate your feedback.

    In the event Code provided resolves your issue, please mark your Thread as SOLVED.

    If you're satisfied by any members response to your issue please use the star icon at the lower left of their post.

  4. #4
    Registered User
    Join Date
    12-11-2013
    Location
    nyc
    MS-Off Ver
    M365 V2311
    Posts
    65

    Re: Macro automation help

    May I please bother you with some additional formatting change to the worksheet. I want to bold the entire row that contains "Total" and also add top and bottom border to "total line"

    Thank you so much for your assistance, this has help me enormously on my everyday data sorting tasks.

    Yayay

  5. #5
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Macro automation help

    Hi Yayay

    Format the output the way you wish to see it and we'll see what we can do.

  6. #6
    Registered User
    Join Date
    12-11-2013
    Location
    nyc
    MS-Off Ver
    M365 V2311
    Posts
    65

    Re: Macro automation help

    Please see attached worksheet "v2".

    Thanks,
    Yayay
    Attached Files Attached Files

  7. #7
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Macro automation help

    Hi Yayay

    Try this Code in the attached...please keep in mind this...
    Please note that I've changed all "total" to "Total" for consistency
    Please Login or Register  to view this content.
    Attached Files Attached Files

  8. #8
    Registered User
    Join Date
    12-11-2013
    Location
    nyc
    MS-Off Ver
    M365 V2311
    Posts
    65

    Re: Macro automation help

    Thank you so much, this is very helpful. I have one last question. What do I change in the code if I need to extend my border lines to an extra column. Please see attached worksheet for the extra column "publish date".

    Thank you so much.
    Yayay
    Attached Files Attached Files

  9. #9
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Macro automation help

    Hi Yayay

    You don't indicate if the Data already includes the new Column...your Sample Data would indicate not...so the Code adds it.

    Please Login or Register  to view this content.
    Attached Files Attached Files

  10. #10
    Registered User
    Join Date
    12-11-2013
    Location
    nyc
    MS-Off Ver
    M365 V2311
    Posts
    65

    Re: Macro automation help

    Apologize for the confusion, my sample data would already have that column. I wanted to make sure that the formatting goes through.

    Please let me know what would I need to adjust in the code.

    Thanks.
    Yayay
    Last edited by yayayken; 03-14-2016 at 04:42 PM. Reason: more clarification

  11. #11
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Macro automation help

    Hi Yayay

    Please upload your existing Sample Data. Please make certain the Sample Data is of the same structure as your actual data (does it start in Column B?; does it start on Row 4?). Place your expected output in Sheet2.

  12. #12
    Registered User
    Join Date
    12-11-2013
    Location
    nyc
    MS-Off Ver
    M365 V2311
    Posts
    65

    Re: Macro automation help

    Hi, Thank you so much for your patience with me. Attached is what the original data resembles and on "sheet 2" is what I would like the outcome to be.
    Attached Files Attached Files

  13. #13
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Macro automation help

    Hi Yayay

    Try this...
    Attached Files Attached Files

  14. #14
    Registered User
    Join Date
    12-11-2013
    Location
    nyc
    MS-Off Ver
    M365 V2311
    Posts
    65

    Re: Macro automation help

    This works. Again, thank you for your help.

    I will now mark this thread is "solved".

    Greatly appreciate your assistance.
    Yayay

  15. #15
    Forum Expert jaslake's Avatar
    Join Date
    02-21-2009
    Location
    Atwood Lake in Mid NE Ohio...look it up.
    MS-Off Ver
    Excel 2010 2019
    Posts
    12,749

    Re: Macro automation help

    You're welcome...glad I could help.

+ 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. New to excel macro and need help in report automation
    By kumar3698 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-05-2014, 11:39 AM
  2. Automation Macro Alternative to 'SendKey'
    By Wayfarer in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 12-02-2011, 01:42 PM
  3. Automation of Macro input parameters
    By cda123 in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-26-2011, 01:50 PM
  4. Automation Error in Excel VBA Macro
    By davidwe in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 04-27-2010, 12:18 AM
  5. Macro automation for graphs & data
    By ice in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-14-2009, 03:43 PM
  6. Macro for drill down & hyperlink automation
    By binar in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-12-2009, 03:41 PM
  7. Macro/automation
    By eQuestion in forum Excel General
    Replies: 0
    Last Post: 08-07-2007, 05:00 AM
  8. How To Delete an Excel Macro by Using Automation
    By ScottG in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 08-16-2005, 05:05 PM

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