+ Reply to Thread
Results 1 to 4 of 4

WorksheetFunction.Sum() is not working, any advice?

  1. #1
    Registered User
    Join Date
    09-18-2011
    Location
    IL
    MS-Off Ver
    Excel 2007
    Posts
    13

    WorksheetFunction.Sum() is not working, any advice?

    Please Login or Register  to view this content.
    Any idea what I am doing wrong with this code? This is what I am trying to attempt:

    If rowNum = 3 then:
    Cells(3,6) = WorksheetFunction.Sum(Range("A3:E2"))

    I get a run time error 13, type mismatch.

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: WorksheetFunction.Sum() is not working, any advice?

    Replace + with &
    Entia non sunt multiplicanda sine necessitate

  3. #3
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,425

    Re: WorksheetFunction.Sum() is not working, any advice?

    Change all the plus (+) signs to ampersands (&).


    Regards, TMS
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  4. #4
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,425

    Re: WorksheetFunction.Sum() is not working, any advice?

    Thanks for the rep

+ 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] WorksheetFunction.CountA not working
    By timtim89 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 04-13-2021, 06:11 AM
  2. [SOLVED] Do while with worksheetfunction.sum not working
    By timtim89 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 05-21-2012, 03:39 PM
  3. application.worksheetfunction.countfs() not working.
    By Lifeseeker in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 01-02-2012, 08:14 PM
  4. Application.WorksheetFunction stops working if the Sub is called
    By emmalg in forum Excel Programming / VBA / Macros
    Replies: 15
    Last Post: 02-03-2011, 09:28 AM
  5. vlookup worksheetfunction call from VBA not working
    By Conor in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 10-03-2006, 11:35 AM

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