ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Activate method of Worksheet class fails in Excel 2000 (https://www.excelbanter.com/excel-discussion-misc-queries/44686-activate-method-worksheet-class-fails-excel-2000-a.html)

Chris Bloom

Activate method of Worksheet class fails in Excel 2000
 
I'm having trouble getting a distributed macro to work on a few
machines. The macro fails on the first line which reads:

Worksheet(1).Activate

I've also tried using the Sheets collection, but still the same error.

The computers in question run the following versions of excel:

Excel 2000 (9.0.6926 SP-3)
Excel 2000 (9.0.3821 SR-1)
Excel 2000 (9.0.2720)

I thought it might be a versioning issue (I developed the macro in Excel
2002), but one other instance of Excel 2000 (9.0.6926 SP-3) runs the
macro fine.

Does anyone know if something would block the Activate method in Excel?
The worksheet in question is actually a tab-delimited file that is
opened with excel.

Chris Bloom

Bob Umlas

Worksheets(1).Activate
you need the "s".


"Chris Bloom" wrote in message
...
I'm having trouble getting a distributed macro to work on a few
machines. The macro fails on the first line which reads:

Worksheet(1).Activate

I've also tried using the Sheets collection, but still the same error.

The computers in question run the following versions of excel:

Excel 2000 (9.0.6926 SP-3)
Excel 2000 (9.0.3821 SR-1)
Excel 2000 (9.0.2720)

I thought it might be a versioning issue (I developed the macro in Excel
2002), but one other instance of Excel 2000 (9.0.6926 SP-3) runs the
macro fine.

Does anyone know if something would block the Activate method in Excel?
The worksheet in question is actually a tab-delimited file that is
opened with excel.

Chris Bloom




Chris Bloom

Sorry, that was a typo. It is in the macro as "Worksheets"

Chris Bloom

Bob Umlas wrote:
Worksheets(1).Activate
you need the "s".


"Chris Bloom" wrote in message
...

I'm having trouble getting a distributed macro to work on a few
machines. The macro fails on the first line which reads:

Worksheet(1).Activate

I've also tried using the Sheets collection, but still the same error.

The computers in question run the following versions of excel:

Excel 2000 (9.0.6926 SP-3)
Excel 2000 (9.0.3821 SR-1)
Excel 2000 (9.0.2720)

I thought it might be a versioning issue (I developed the macro in Excel
2002), but one other instance of Excel 2000 (9.0.6926 SP-3) runs the
macro fine.

Does anyone know if something would block the Activate method in Excel?
The worksheet in question is actually a tab-delimited file that is
opened with excel.

Chris Bloom





Dave Peterson

If you put:

msgbox worksheets(1).name

right before it, do you get what you expect?

If I had a workbook with worksheets 1-8 (left to right), I could hide 1-7 and
worksheets(1).name refered to sheet1--but sheet8 was active (xl2003).

But if that workbook were hidden and no active workbook, then I got an error.

Chris Bloom wrote:

Sorry, that was a typo. It is in the macro as "Worksheets"

Chris Bloom

Bob Umlas wrote:
Worksheets(1).Activate
you need the "s".


"Chris Bloom" wrote in message
...

I'm having trouble getting a distributed macro to work on a few
machines. The macro fails on the first line which reads:

Worksheet(1).Activate

I've also tried using the Sheets collection, but still the same error.

The computers in question run the following versions of excel:

Excel 2000 (9.0.6926 SP-3)
Excel 2000 (9.0.3821 SR-1)
Excel 2000 (9.0.2720)

I thought it might be a versioning issue (I developed the macro in Excel
2002), but one other instance of Excel 2000 (9.0.6926 SP-3) runs the
macro fine.

Does anyone know if something would block the Activate method in Excel?
The worksheet in question is actually a tab-delimited file that is
opened with excel.

Chris Bloom





--

Dave Peterson


All times are GMT +1. The time now is 10:52 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com