+ Reply to Thread
Results 1 to 4 of 4

Time of execution

  1. #1
    Registered User
    Join Date
    09-03-2016
    Location
    Catania, Italy
    MS-Off Ver
    Excel 2007
    Posts
    2

    Time of execution

    Good morning
    I have an Excel file with 2 Sheets.
    In the first (named CLAIM) it there is a list of codes in the coloumn A and other codes in the P-Q-R-S-T columns
    In the other (named DELIVERY) it there is a list of codes in the coloumn A and the state of the order in coloumn CK
    I must collate all the codes of the with the. P-Q-R-S-T of the CLAIM Sheet with the codes in coloumn A of the DELIVERY Sheet. If the codes are identical I control the string in the same row in coloumn CK; if the string is "Consegnato" the color of the cell in CLAIM Sheet must be green.

    I have made two macros
    1°) I have allotted the codes to of the variable and with For … Next cycles I compare codes
    2°) I have used AutoFilter to compare codes

    The two macro functions perfectly.
    Problem
    I launch first the macro n.1- time of execution= xTime
    Then I launch the macro n.2- time of execution= yTime (very near to xTime)

    Then I launch again the macro n.1- time of execution= xTime multiplied 7
    Then I launch again the macro n.2- time of execution= yTime (around)

    What caused this strange behavior?

    Here is my file

    Thank you in advance and there I pray of excuse my English

    I wait for you reply.

    Bye,
    Mario
    Attached Files Attached Files

  2. #2
    Administrator JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Time of execution

    Every time I run macro1, it's about 20 seconds.
    Every time I run macro2, it's about 5 seconds.
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    “None of us is as good as all of us” - Ray Kroc
    “Actually, I *am* a rocket scientist.” - JB (little ones count!)

  3. #3
    Forum Contributor IonutC's Avatar
    Join Date
    01-28-2016
    Location
    Bucharest, Romania
    MS-Off Ver
    Office 2019
    Posts
    486

    Re: Time of execution

    the same for me
    Please consider:
    Be polite. Thank those who have helped you.
    Click the star icon in the lower left part of the contributor's post and add Reputation. If you are satisfied with the help you have received, then Please do Mark your thread [SOLVED] .
    Click on GO ADVANCED and then scroll down to Manage Attachments to open the upload window.
    Posting code between tags makes your code much easier to read and copy for testing, it also maintains VBA formatting.

  4. #4
    Registered User
    Join Date
    09-03-2016
    Location
    Catania, Italy
    MS-Off Ver
    Excel 2007
    Posts
    2

    Re: Time of execution

    Hi dear friends
    I have solved. The problem was caused by the subfix .Text in the cycles.

    Now I submit my file "correct". Try again.

    Ciao,
    Mario
    Attached Files Attached Files

+ 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. Reducing AddItem Execution Time
    By Kyle123 in forum Excel Programming / VBA / Macros
    Replies: 10
    Last Post: 08-24-2011, 03:13 PM
  2. Time limit on Code Execution
    By bgunawan in forum Excel Programming / VBA / Macros
    Replies: 25
    Last Post: 07-15-2009, 07:51 AM
  3. Code Execution Degrades Over Time
    By KDT in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 07-25-2008, 04:28 PM
  4. Lookup execution time
    By Zade in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-26-2007, 01:34 PM
  5. Date Time of Last Execution
    By JB2010 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 05-22-2006, 10:35 AM
  6. [SOLVED] add + suppress command buttons in execution time
    By Ali Couran KOTE in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-06-2006, 06:00 PM
  7. Macro execution time
    By Henry in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-08-2005, 11:05 AM
  8. Replies: 5
    Last Post: 04-12-2005, 05:06 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