+ Reply to Thread
Results 1 to 5 of 5

can you paste the sum created by hiliting a range

  1. #1
    Registered User
    Join Date
    11-29-2009
    Location
    oregon
    MS-Off Ver
    Excel 2003
    Posts
    5

    can you paste the sum created by hiliting a range

    If you have a range (column or row) of numbers and you hilite them, Excel displays the total (sum) of the hilited numbers in the lower right side of the screen. How do you, can you, paste that sum into a cell on the open sheet or another sheet? Does it take a little vba program to do that?

    Thanks for your help.
    Last edited by napadude; 12-01-2009 at 01:51 PM.

  2. #2
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: can you paste the sum created by hiliting a range

    Yes, VBA is your best bet, eg:

    Please Login or Register  to view this content.
    so you would select your cells, run the above routine and the total would appear in Sheet1!A1

  3. #3
    Registered User
    Join Date
    11-29-2009
    Location
    oregon
    MS-Off Ver
    Excel 2003
    Posts
    5

    Re: can you paste the sum created by hiliting a range

    thank you for the help. I am not real good with VBA, but understand your sol'n.
    I will look another place to find out how to implement the VBA.

    What if I wanted to paste it to a cell that I had hilited on a sheet (any sheet that I happened to pick), how would I change the code - should have been more specific the 1st time around.

    Again, thank you.

  4. #4
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: can you paste the sum created by hiliting a range

    your "selection" is either

    a) the values to sum

    b) the cell in which to paste result

    as a general rule it can't be both unless you come up with some logic to ensure say the first cell selected is always to contain the total and to be excluded from the calculation itself, ie:

    Please Login or Register  to view this content.
    but it's not very practical (obviously)

  5. #5
    Registered User
    Join Date
    11-29-2009
    Location
    oregon
    MS-Off Ver
    Excel 2003
    Posts
    5

    Re: can you paste the sum created by hiliting a range

    Thank you for the help, I understand.

+ 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