MVP's?? Why is Excel 97 VBA much faster than Excel 2002 VBA

K

Ken Macksey

Hi

I don't know if anyone knows why, but it seems that Excel 97 runs for next
loops at about 25 times faster than Excel 2002.

In Dec 2002, I created a workbook using the code attributed originally to
Bob McCormick to break worksheet passwords and later modified by Norman
Harker to break workbook passwords that automatically looped through a
workbook and unprotected the workbook and all sheets with the same or
different passwords.
I incorperated a rough timer into it so it showed at the end approximately
how long it took to unprotect the wb and all sheets.

Using Excel 97, it consistently took about 16 seconds to remove passwords
for the wb and 3 worksheets that were all different passwords.
I upgraded to office XP 2002 and since then, using Excel 2002 and all else
being equal, it takes about 6 minutes and 50 seconds for the same workbook.

I downloaded J.E.McGimpsey's latest wb based on the same code and it takes
about the same time as well.

Anyone know why?

I decided to re-install just Excel 97 to do some testing, and lo and behold
with both excel 97 and excel 2002 installed on the same machine, running the
same files, it still only takes 16 seconds with Exel 97 and 6 minutes and 50
seconds with Excel 2002.

This code is just basically just a bunch of for next loops, so is it a
difference in the way they are run or is it something to do with the extra
protection features or options available with excel 2002?

KenM
 
K

Ken Macksey

Hi

After running several loop timing tests in both excel 97 and excel 2002,
there appears to be no difference in speed etc.
My only guess is that M.S. changed the way the password's are hashed in
excel 2002 and maybe only one or two combinations will remove the password
whereas in excel 97 maybe hundreds of combinations will.

I don't know.

Does anyone else know?

KenM
 
R

RWN

Ken;
I'm not an expert here but I think you're probably on the right track
based on my experience with protecting a VBA project in xl2k and not
being able to open it in xl97 as it wouldn't even allow me to enter a
password (caused me a degree of heart failure at the time!).
I posted a question on one of the XL ng's and was told that xl2k's
password protection was "beefed up" (my term) over xl97.
Seems to be related(?)
 
A

Alert

Ken Macksey said:
Hi

I don't know if anyone knows why, but it seems that Excel 97 runs for next
loops at about 25 times faster than Excel 2002.

In Dec 2002, I created a workbook using the code attributed originally to
Bob McCormick to break worksheet passwords and later modified by Norman
Harker to break workbook passwords that automatically looped through a
workbook and unprotected the workbook and all sheets with the same or
different passwords.
I incorperated a rough timer into it so it showed at the end approximately
how long it took to unprotect the wb and all sheets.

Using Excel 97, it consistently took about 16 seconds to remove passwords
for the wb and 3 worksheets that were all different passwords.
I upgraded to office XP 2002 and since then, using Excel 2002 and all else
being equal, it takes about 6 minutes and 50 seconds for the same workbook.

I downloaded J.E.McGimpsey's latest wb based on the same code and it takes
about the same time as well.

Anyone know why?

I decided to re-install just Excel 97 to do some testing, and lo and behold
with both excel 97 and excel 2002 installed on the same machine, running the
same files, it still only takes 16 seconds with Exel 97 and 6 minutes and 50
seconds with Excel 2002.

This code is just basically just a bunch of for next loops, so is it a
difference in the way they are run or is it something to do with the extra
protection features or options available with excel 2002?

KenM

Yes, Microsoft have modified their algorythm, and although the
intention was not to make it more stringent, it typically takes longer
to recover a password by the brute force method if you're using a
program written for the old system.

If you search for password recovery tools on the web, you'll find that
most of them have been modified in line with the new mechanism.

http://www.intertek.org.uk
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top