+ Reply to Thread
Results 1 to 4 of 4

VBA Code to SUM specific range in a column and repeat for all the coulmns with data.

  1. #1
    Registered User
    Join Date
    05-15-2013
    Location
    Hyderabad
    MS-Off Ver
    Excel 2003
    Posts
    39

    Post VBA Code to SUM specific range in a column and repeat for all the coulmns with data.

    Hi All,

    I can't stop myself without thanking you for the favor you do..

    I need your help on the below request please.

    I want to sum multiple specific ranges using vba for all the columns with data in it.

    For instance:

    From Column B its random that number of columns with values however my range of sum will still remain same. but its for sure that all the columns are one after other without any blank columns in the middle.

    I want to sum B5:B8+B11:B14+B17:B20 and Value in B30 and if there are values in those cell in column C I need the total of those range from Column C in C30 and similarly if the values in Column D in the same range, Need the result in Cell D30.

    I am trying to insert this to one of my existing MACRO.

    Can someone please help me on this

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: VBA Code to SUM specific range in a column and repeat for all the coulmns with data.

    We'd be able to help more easily if you would share your workbook with us. Manually add the results you expect and explain how you have arrived at the results.
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Registered User
    Join Date
    05-15-2013
    Location
    Hyderabad
    MS-Off Ver
    Excel 2003
    Posts
    39

    Re: VBA Code to SUM specific range in a column and repeat for all the coulmns with data.

    Sub Total.xlsxHi Richard

    Thanks for your reply,
    Please find the attached spread sheet with 2 tabs one before running MACRO and other with the expected result post MACRO. Result I am expecting is in Range B85 and in all the columns towards right column <> "", with same range of sum.

    Thanks once again for your time and interest.

    Naresh

  4. #4
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: VBA Code to SUM specific range in a column and repeat for all the coulmns with data.

    Hi,

    One way
    Please Login or Register  to view this content.

+ 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] Trying to move specific range to a specific sheet based on data in certain column
    By cain2011 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 08-01-2013, 08:09 AM
  2. Copy data in Specific column in a specific range
    By macrofan2012 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 12-14-2012, 01:27 PM
  3. How do I make my macro insert/paste code in specific column range?
    By Rabbitstew in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-17-2012, 04:33 PM
  4. VBA code to make a macro repeat as long as there is data in the column
    By dkassin in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-28-2012, 06:42 PM
  5. Replies: 4
    Last Post: 07-04-2007, 03:09 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