Microsoft Knowledge Base |
|
VB for Applications Worksheets Move Method with Hidden Sheet |
|
|
Last reviewed: September 13, 1996
Article ID: Q127940 |
|
The information in this article applies to:
SYMPTOMSIf you attempt to use the following code in a workbook where you have hidden sheets, you will receive unexpected results:
ActiveSheet.Move before:=Sheets("sheet name")
CAUSEIf there are any hidden sheets in your workbook that are located before the sheet that you are trying to move in front of, the move method will actually move the active sheet behind your destination worksheet.
WORKAROUNDIf you have hidden sheets in your workbook and you are going to be moving your sheets using Visual Basic for Applications code, you will need to locate all of your hidden sheets at the very end of your workbook. This problem only occurs when there are hidden sheets in front of your destination sheets.
STATUSMicrosoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article. We are researching this problem and will post more information here in the Microsoft Knowledge Base as it becomes available.
|
|
KBCategory: kbprg kbcode
©1997 Microsoft Corporation. All rights reserved. Legal Notices. |