Hiding macro execution

A

Angeliki

Hello
I wrote a code that copys values from one workbook to another workbook.
The problem is that when goes from one workbook to another there is a
flickering in the screen.
Can you tell me how to hide macro execution?The code works ok i just don't
want to see the macro be executed.
Thanks in advance

Regards
Angeliki

Windows("Book1").Activate
Sheets("Information").Select
Range("A1:I12").Select
Selection.Copy
Windows("Book2").Activate
Selection.PasteSpecial Paste:=xlValues, Operation:=xlNone,
SkipBlanks:=False, Transpose:=False
Selection.PasteSpecial Paste:=xlFormats, Operation:=xlNone,
SkipBlanks:=False, Transpose:=False
Columns("A:I").Select
Columns("A:I").EntireColumn.AutoFit
Range("A1").Select
Sheets("Sheet1").Select
Sheets("Sheet1").Name = "Information"

Windows("Book1").Activate
Application.CutCopyMode = False
Range("A1").Select
 
A

Angeliki

I tried this one. However it goes to one workbook to another several times.
Should i add this before each time it'a about to change workbook in the
code?
I would appreciate any help

Thanks

Angeliki
 
P

pantelis

I think what Angeliki means is that she included the

application.screenupdating = False code but she is still

showing the sheets when changing from one workbook to another.

I'm not sure how to correct for this but would be interested in anyones
input.

Pantelis
 
D

Don Guillett

the

application.screenupdating=false
should be at the start of your macro
application.screenupdating=true
at the end
the change to your workbooks shouldn't show. It may? not be necessary to
open the workbook. Why don't you post all of your code for comments.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top