I have the following strange problem:
In a visual basic code i do references like: Workbooks("WorkbookX").Worksheets("WorksheetY").DoSomething
And they work fine. For some other people when running it does not find the worksheet i.e. gives the same error as if I had written
Workbooks("WorkbookX").Worksheets("WorksheetZ").DoSomething
where WorksheetZ does not exist. It helps if I change to the generic naming in excel i.e. Sheet8, Sheet9 but it would be quite cumbersome to change all references.
Does anyone have an idea?
In a visual basic code i do references like: Workbooks("WorkbookX").Worksheets("WorksheetY").DoSomething
And they work fine. For some other people when running it does not find the worksheet i.e. gives the same error as if I had written
Workbooks("WorkbookX").Worksheets("WorksheetZ").DoSomething
where WorksheetZ does not exist. It helps if I change to the generic naming in excel i.e. Sheet8, Sheet9 but it would be quite cumbersome to change all references.
Does anyone have an idea?