Re: Problem Comparing program Versions

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



Norm wrote:
Hi,

I am probably missing something simple, but I have been having a
problem trying to figure out the best way to compare versions of a
program for updating.

I thought I could just add the Major, Minor and Revision, but it
would be possible for 4.2.2 to be more than 5.1.1. The same holds
true if I just check each number.

No, if you check each number in sequence from major on down, you will
never fail. 5 is > 4, so you stop comparison right there. You'd only
test the second values if the first ones were equal.

You could add up the parts, but only if you weight them first. (Major
* 1000000) + (Minor * 10000) + (Revision * 100) + Build -- or whatever
the parts are called (a 'correct' version number has 4 parts -- VB
unaccountably leaves one out).

Choose appropriate weights based on the maximum values you could
encounter. The ones I show would work for most apps, but probably not
for all.

--
Jim Mack
MicroDexterity Inc
www.microdexterity.com

.



Relevant Pages

  • RE: Comparing data in two sheets with similar values
    ... ' compare two different worksheets in two different workbooks ... .LineStyle = xlContinuous ... .Weight = xlHairline ...
    (microsoft.public.excel.worksheet.functions)
  • Re: So, I got my OW Cert
    ... to weight lifters in general (my experience, and not martial artists who use ... you're a power lifter, not a weight lifter, as if most of us "care". ... your acomplishments in your sport I feel are very ... about half my weight, I have no idea how our body fat percentages compare, ...
    (rec.scuba)
  • Re: my swing
    ... It has been reported I should not move the head - my shoulders turn ... I actually had the weight forward - e.g. the knees over the toes. ... I really compare myself to some 'athletic' guy with only half as much ...
    (rec.sport.golf)
  • Re: So, I got my OW Cert
    ... Lifter way well be stronger. ... you're a power lifter, not a weight lifter, as if most of us "care". ... recreational diving and ocean diving experiences are well beyond mine, ... about half my weight, I have no idea how our body fat percentages compare, ...
    (rec.scuba)
  • Re: What does an XR600 motor weigh?
    ... The only way to compare a 650R to a 600R is to include the weight of the ... service manual listed the engine weight right around 90#. ... We don't stop riding because we get old, we get old because we stop riding. ...
    (rec.motorcycles.dirt)