Excel 2003/ Excel 97

  • Thread starter Thread starter Don Lloyd
  • Start date Start date
D

Don Lloyd

Hi all,

Happy Easter to everyone !

I have a small (<300k) workbook that makes fairly extensive use of VBA.
It has been developed in Excel 2003 and works fine (in Excel 2003).

I have tried running it on two other computers, both with Excel 97, and in
both cases it crashes - "This program has performed an illegal
operation...."

However, if I access the code and step through it (f8), it functions as
designed on both XL 97 computers.

For each module I've tried exporting the code, deleting the module and then
importing the code again but to no avail.

Any suggestions / pointers will be gratefully recieved

Don
 
If you are using controls from the control toolbox toolbar, they can be
problematic. For example, for a commandbutton, you should set the
takefocusonclick property to false.

However, this doesn't usually cause a general protection fault. I would
check the project's reference items and insure only the standard references
are set.

As a general rule, development should always be performed on a machine using
the lowest version you intend to use with the software.
 
I had a similar problem one time and i simply copied the code out and pasted
it in the newer version and it worked, although I am not sure why.
 
Back
Top