Thanks for your reply.
The error is just the same. And it doesn't explain why exactly the same code runs on one machine and not on the other.
Main Topics
Browse All TopicsI have code on my PC and it runs fine. I have exactly the same code on my laptop, and it keeps running into an error on lines like
Windows("upcomingraces").A
run-time error '9' subscript out of range
"upcomingraces" is open, but will not activate.
Can you help please?
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Hello robinbernett,
I can reproduce your problem if the two workbooks are in separate instances of Excel.
For example, if you check the box for "Ignore other applications" in the Tools...Options...General menu item, then Excel will open up each workbook in a separate instance of Excel. You would then receive an runtime error 9 subscript out of range when trying to switch from the window in one instance of Excel to a window in another instance of Excel. This error does not occur if the Ignore other applications checkbox is unchecked and the other workbook is opened in the same instance of Excel.
Regards,
Brad
Thanks Trantrak
No, I don't think so - the code is exactly the same, and in any case the case is correct.
Thanks Brad
I was hopeful there for a minute, and appreciate that you have tried to replicate the problem, but the box is unchecked already. Also the vba creates the workbooks, except one which is a template so presumably they are all in the same instance of Excel - but whatever the case would be the same on one machine to another.
Business Accounts
Answer for Membership
by: jppintoPosted on 2009-11-01 at 11:13:52ID: 25714954
Use this instead:
tivate
Sheets("upcomingraces").Ac