View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
jorma jorma is offline
external usenet poster
 
Posts: 1
Default Multi-threaded calculation and VBA

I have an example with VBA and a simple sheet, which
- runs OK in Excel 2000
- runs OK in Excel 2007 when multi-threaded calculation is disabled
- fails in Excel 2007 when multi-threaded calculation is enabled on a
dual-core processor

It is really simple, it just changes some variables back and forth and
checks that the computed value from them is what it shoud be. There is a User
Form on the screen, and when I drag the form with my mouse during the
computation, the computation fails (in Excel 2007 on Vista with MTC and
dual-core).

The sheet is he
http://www.mylvin.com/stuff/mtctest.zip
Open the sheet, click the button "Start MTC Stress Test",
click the button "Start the test" on the form which opens,
and then drag the form to a different position on the screen with your mouse.
You'll see the error message about the computation.
If you don't drag, the test runs fine.

I'm not sure if this is a bug in Excel 2007 (if so, I don't know where to
report it) or a wrong approach when programming with VBA into multi-threaded
enviroment.

What do you think?

- Jorma.
http://www.mylvin.com