![]() |
Worksheet_Change Event problem in 2007
Hi,
I have code in the Worksheet_Change event of a spreadsheet I created with Excel 2003 and XP OS. If I copy that spreadsheet on to a machine running Excel 2007 and Vista, the code runs because I can step through it, but the code is not executed. I'm sure that screen updating is enabled and nothing in the event code disables it. I do disable events once the initial change event occurs because one of the calls within this routine hides rows and columns on rhe worksheet and I don't want to re-fire the change event. I do re-enable events at the end of the sub. I'm including a snippet of the code. You can see that it should be updating the status bar but it does not. I'm sure I'm just missing something simple but I can't for the life of me figure out what it might be. Any input would be appreciated. Here's the code: Private Sub Worksheet_Change(ByVal Target As Range) Dim LastCol As Integer Dim OnOff As Integer Dim UpdateScreen As String If Target.Row = 4 And Target.Column = 5 Then ActiveWorkbook.Unprotect Password:="password" Application.EnableCancelKey = xlDisabled On Error GoTo GracefulExit With Application .EnableEvents = False .StatusBar = False .StatusBar = "Building Format.....Please Wait." End With Call BudgetPresentation (LastCol) -- Thanks. Chuck M. |
All times are GMT +1. The time now is 02:22 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com