+ Reply to Thread
Results 1 to 5 of 5

Macro Help - Subtotaling Cells w/ Same Name Info

  1. #1
    Registered User
    Join Date
    01-14-2013
    Location
    Fort Worth, TX
    MS-Off Ver
    Excel 2003
    Posts
    4

    Macro Help - Subtotaling Cells w/ Same Name Info

    Hello!

    I am new to this forum and new to Excel macros. I work for a finance company and have a question about how to code a macro. What I need it to do is subtotal cells that have the same name, e.g. stock lot information. So several cells in a single column with a symbol e.g. AAPL, and the shares purchased each date in the next column respective cell. I have attached an example of what I mean (I hope it works, Im new to this). Lot Example.xlsx

    I've been trying to figure it out but I'm not very good with coding. I'm sure its a very easy task for an experienced programmer. What I've been trying to do is have it put the subtotal to the right of the last cell with that symbol. It'd be even better if it could start in new columns, with the symbol name and respective subtotal. Meaning, A and B columns are the symbols/lots, and C and D is a single symbol name/subtotaled amount.

    I GREATLY appreciate any help with this problem. Thank you for your time and assistance!

    ~Donny

  2. #2
    Forum Expert
    Join Date
    01-15-2007
    Location
    Brisbane, Australia
    MS-Off Ver
    2007
    Posts
    6,591

    Re: Macro Help - Subtotaling Cells w/ Same Name Info

    Hi

    why don't you just add some headings, and use a pivot table? Much easier.

    rylo

  3. #3
    Registered User
    Join Date
    01-14-2013
    Location
    Fort Worth, TX
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Macro Help - Subtotaling Cells w/ Same Name Info

    Hah. Guess I didn't think of that.. Thanks

  4. #4
    Forum Contributor
    Join Date
    09-22-2012
    Location
    Berkeley, CA
    MS-Off Ver
    Excel 2010
    Posts
    112

    Re: Macro Help - Subtotaling Cells w/ Same Name Info

    Another way to do it would be to use the "sumif" function. You could create a cell for each stock name and use the functions to sum all the values that have that stock name.
    ------------------------
    W2

  5. #5
    Registered User
    Join Date
    01-14-2013
    Location
    Fort Worth, TX
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Macro Help - Subtotaling Cells w/ Same Name Info

    Thank you everyone for the replies..! I guess I've been trying to learn VBA, so I get stuck in that mindset and forget about the other, more simple features Excel has to offer =P

    Thanks again, I truly appreciate your help!

+ 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