+ Reply to Thread
Results 1 to 2 of 2

Worrying too much about processing time?

  1. #1
    Registered User
    Join Date
    08-08-2012
    Location
    Detroit, MI
    MS-Off Ver
    Excel 2010
    Posts
    15

    Worrying too much about processing time?

    I'm new to VBA. I'm finding myself obsessing maybe too much about processing time. I totally understand the obvious things, like operating on addresses/ranges/variables/arrays rather than in active cells, etc.

    Here's an example. I'm going through a list, filtering by several different variables to generate a list of part numbers that I'm going to feed into another system (mainframe...). I started creating these tools for a coworker when I knew very little, so all my macros have been pretty piecemeal. Now I'm streamlining...feels very inefficient to totally redesign everything, but when I started I didn't even know what I mentioned in the first paragraph.

    So here's an idea, I was going to use an array to hold a list of numbers. Now I figure I will make it a 2D array so I can also hold the inventory quantity data I plan to get from the mainframe. While redesigning, I figure I'll also use this array to record whether this part is listed multiple times in my tracking excel file (which some are, and which is not up to me). I could use an array column for this, or I thought of a random "new" idea: make the part number negative in my array if it's used multiple times. Then later, check each number for <0...

    As a newbie, jumping in and programming before having much experience, esp. in VBA, I'm constantly worrying about things like this, always aware that there's probably an alternate way, and always aware that if I worry about it too much I can't actually GET TO WORK, yet if I hastily get to work, then I'll wind up wanting/needing to change it later.

    So, what do you guys do? Should I stop worrying? Should I keep worrying, do short tests to see how long stuff takes? In your experience, have you found that your upfront nitpicking about methods have resulted in long term (per-run) savings? Or no?

  2. #2
    Registered User
    Join Date
    07-15-2013
    Location
    Atkinson, Nebraska
    MS-Off Ver
    Excel 2013
    Posts
    10

    Re: Worrying too much about processing time?

    I would do a quick run of your stuff to see if it's going to take a really long time. Once you get your results, think about the time you'd lose in the next year (you'll probably think of something else in that time) if you leave it as is. If that time is greater than the time it'd take to nitpick a little, then you'll need to fix some things.

+ 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. Macro which delays for processing time
    By freud1 in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 07-05-2012, 07:04 AM
  2. Windows XP : Processing response time very slow
    By Thembinkosi in forum Microsoft Windows Help
    Replies: 3
    Last Post: 05-14-2011, 10:38 AM
  3. Calculate processing time with fixed time paramaters
    By Apel in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 09-01-2009, 08:54 AM
  4. Macro processing time is very slow
    By Foxcan in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-17-2009, 11:44 PM
  5. Looping Through and Processing 1000 records at a time.
    By NBVC in forum Excel Programming / VBA / Macros
    Replies: 15
    Last Post: 10-30-2008, 12:51 PM

Tags for this Thread

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