+ Reply to Thread
Results 1 to 4 of 4

Does WorksheetFunction.Sum takes more time?

  1. #1
    Forum Contributor
    Join Date
    11-12-2010
    Location
    HK
    MS-Off Ver
    Excel 2010
    Posts
    189

    Does WorksheetFunction.Sum takes more time?

    Hi,

    I got a problem when using below code. This procedure is called in another procedure named Grouping. WorksheetFunction.Sum(Range("B2", "B11")) produces 0 when I execute Sub Grouping (I dont know whether this is due to the speed of running). But when I execute solely on this Sub summation right after executing Sub Grouping, this worksheetfunction could produce the correct figure. what is the reason behind? Thanks

    Please Login or Register  to view this content.
    Last edited by lubbamkt; 05-24-2014 at 11:25 AM.

  2. #2
    Forum Guru HaHoBe's Avatar
    Join Date
    02-19-2005
    Location
    Hamburg, Germany
    MS-Off Ver
    work: 2016 on Win10 (notebook), private: 2019 on Win10 (desktop), 2019 on Win11 (notebook)
    Posts
    8,197

    Re: Does WorksheetFunction.Sum takes more time?

    Hi, lubbamkt,

    maybe try
    Please Login or Register  to view this content.
    Ciao,
    Holger
    Use Code-Tags for showing your code: [code] Your Code here [/code]
    Please mark your question Solved if there has been offered a solution that works fine for you

  3. #3
    Forum Contributor
    Join Date
    11-12-2010
    Location
    HK
    MS-Off Ver
    Excel 2010
    Posts
    189

    Re: Does WorksheetFunction.Sum takes more time?

    Thanks HaHoBe,

    Perfect. Could you tell me what is the rationale behind

    Quote Originally Posted by HaHoBe View Post
    Hi, lubbamkt,

    maybe try
    Please Login or Register  to view this content.
    Ciao,
    Holger

  4. #4
    Forum Guru HaHoBe's Avatar
    Join Date
    02-19-2005
    Location
    Hamburg, Germany
    MS-Off Ver
    work: 2016 on Win10 (notebook), private: 2019 on Win10 (desktop), 2019 on Win11 (notebook)
    Posts
    8,197

    Re: Does WorksheetFunction.Sum takes more time?

    Hi, lubbamkt,

    if you do not qualify a range with a workbook and/or worksheet name VBA assumes this range to be located on the ActiveSheet. As all other actions take place on Worksheets(3) by placing a dot in front of the range makes it part of that worksheet.

    Ciao,
    Holger

+ 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] Time Formula, time it takes to calculate
    By sans in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 02-16-2023, 08:23 AM
  2. Pasting takes time
    By ArnolddG in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 02-16-2014, 12:44 PM
  3. [SOLVED] Formula that takes takes out a specific word/number from text string
    By ncalvelo in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 11-29-2012, 10:21 AM
  4. worksheetfunction.run time error '1004'
    By akabraha in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 03-04-2008, 06:56 PM
  5. Get time it takes to run program!!
    By cjsasl in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 11-11-2005, 05:35 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