Workbook.activate acts dif when activewindow.caption changed
Thanks Ken
JC
--
CroceJC
"Ken" wrote:
jc
How do you know it is only the second me.activate that changes the
active sheet? It looks like the first one does it for me.
Try this
Sub test()
Me.Activate
MsgBox "what is the active sheet?"
ActiveWindow.Caption = "help xxxxx"
MsgBox "what is the active sheet now?"
Me.Activate
End Sub
Ken
On Jun 12, 3:01 pm, jc wrote:
Again this is the situation
I open a new workbook with more than one sheet.
I acitvate a sheet other than sheet(1)
I enter the following code in the workbook code
Sub test()
Me.Activate
ActiveWindow.Caption = "help help"
Me.Activate
End Sub
upon execution:
The first Me.Activate does not change the active sheet
The second Me.Activate changes the active sheet to Sheet(1)
=========================================
It is not part of an event and it is the me.activate that is changing the
active sheet to the sheet(1) which I believe is not normal behavior.
Can someone please replicate and confirm or deny.
--
JC
"Ken" wrote:
jc
I changed the active window caption using the immediate panel in Excel
2003. That does not seem to effect the the activewindow when activate
the workbook for me.
How are you changing the caption? How are you activating the
workbook? There could be something else going on if you are doing
that event code.
Ken
On Jun 12, 2:11 pm, jc wrote:
I am using EXCEL 2003
Did you set ActiveWindow.Caption to something different first?
--
JC
"Joel" wrote:
The activesheet isn't changing on Excel 2003
"jc" wrote:
Normally the active sheet in a workbook doesn't change when the workbook is
activated.
After setting the ActiveWindow.Caption to something new:
Workbook.activate changes the active sheet to Worksheets(1) no matter what
the previous active sheet was.
Can someone confirm this behavior?
Can someone explain this?
Can someone comeup with way to regain normal behavior?
--
JC- Hide quoted text -
- Show quoted text -- Hide quoted text -
- Show quoted text -
|