Copy - Paste

E

Edgar Thoemmes

Another question relating to the import of some data from
another book.

After I have copied the data from the sheet I get the
messgage 'There is a large amount of data on the
Clipboard - Do you want to make this available to other
programs?

Is is possible for excel not to display this message.

I have tried application.screenupdating = false but this
is not working

Sub Import_Data()
'Imports data from Fname - Sheet (Test11) to Crystal_Table
Application.ScreenUpdating = False
If fname <> "" Then
Range("a1").Value = fname
Set oWb = Workbooks.Open(fname)
oWb.Sheets("TEST11").Range("A1:AQ100").Copy
Windows("IMPORT.xls").Activate
Sheets("Crystal_Table").Select
ActiveSheet.Paste
Else
MsgBox ("Please select a Valid File")
End If
oWb.Close
Worksheets("Menu").Activate
Application.ScreenUpdating = True
End Sub
 
R

Ron de Bruin

After the past line add this Edgar
It will clear the clipboard

Application.CutCopyMode = False
 
B

Bob Phillips

Edgar,

Have you tried

Application.CutCopyMode = False

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 
B

Beto

Edgar said:
Another question relating to the import of some data from
another book.

After I have copied the data from the sheet I get the
messgage 'There is a large amount of data on the
Clipboard - Do you want to make this available to other
programs?

Is is possible for excel not to display this message.

I have tried application.screenupdating = false but this
is not working

What you need is Application.DisplayAlerts = False, then set it back to
true.

I'm not sure waht will be the behaviour if the messagebox is skipped so
you'll have to try it out.

Regards,
 
B

Bob Phillips

I think you've got the wrong end of the stick here.

Read this site to get a proper understanding of events
http://www.cpearson.com/excel/events.htm

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 

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

Similar Threads

Importing data 3
Closing workbook 4
Subscript out of range 1
Code copies twice...? 13
Copy rows from other Excel-file 0
VBA for Dependents shortcut menu 0
Import Wizard 1
Import Worksheets and "Overright" 9

Top