![]() |
Windows On/Windows Off
I have an Excel workbook with a sheet that hold data that I want to update
from an MS SQL database. Normally the sheet is hidden, and I want unhide it and place the recordset onto the sheet. I have the logic to copy the downloaded recordsheet, but what I want to do is open the workbook and retrieve a small dataset from the server without the user seeing the new sheet. My Excel help is rather limited on the company's PC, so if someone could assist with providing a little code chunk I would greatly appreciate it. In old (very old) versions of Lotus, a macro could run a WindowsOff Command to shut of the Windows updating while the macro was running. Is there something similar in VBA? TIA. Mark |
Windows On/Windows Off
Not sure if this is what you are looking for, but you can switch off
Screen updating: Application.ScreenUpdating = False Hope that helps. Remy Blaettler www.collaboral.com |
Windows On/Windows Off
You must remember to set this back to TRUE once the macro has done its
work. Your error handler should also turn it back to TRUE. Pete |
Windows On/Windows Off
Thanks guys. It worked well.
"Pete" wrote: You must remember to set this back to TRUE once the macro has done its work. Your error handler should also turn it back to TRUE. Pete |
All times are GMT +1. The time now is 03:38 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com