Vb net turn off screen updating Video chat chattole
So, I prefer Open Query action rather than Run SQL action.Regards, jon [font=Verdana][size=2]You should not have to do all that.Screen Updating = False in the macro but when the other Workbook is opened Screen Updating is on How can I turn off Screen Updating in the other workbook from within the calling macro? Enable Events = False If I use the watch window to look at Application. Activte line is run Unless I am missing something why not try opening the source WB, storing the data in "Get Data(i Count)" in an Array , exit the loop then ,activate This Workbook again, turnoff the sreen updating and do all the formatting work in one go by retreiving the Data stored in the Array. OK - this is a new concept which I don't quite understand. Thanks Rick Running the code from either a button on the worksheet or from a button on a userform makes no difference here is some of the code Application. Screen Updating I can see it change to True as soon as wb is opened regardless of the second line that turns it false. The intent of the code above is to copy 4 different ranges from a source (unopened) workbook into the active workbook, then format the copied range. Queries will run in the background if the correct command syntax is used.What method (action) are you using to execute your queries in the macro? I use the following Macro Options: Action: Open Query View: Datasheet Data Mode: Edit I would like to have each query saved with a different query name, so that I can modify them easily.
[/size][/font] Try the following steps and let me know what happens: If it does not do the trick in a macro setting, I will show you how to accomplish it with just a few lines of VBA code. Before running your macro, make sure that the checkbox for confirming action queries is unchecked. Modify your macro to sandwich the Open Query action between the Set Warnings On = No and Set Warnings On = Yes actions as shown.I used to be able to do this under VB6 but I have completely forgotten how to do it and I can no longer read my notes. It see it all as one control so it builds everyting the control needs at once and then you add that one control to the form. Mainly it just allows you to visually edit your group of controls rather than coding each control if you were to do it in just a normal class.