Solved

excel macro error

Posted on 2004-04-02
2
432 Views
Last Modified: 2012-08-14
I geta error 1004,pastespecial method of range class failed
Test.xls is already open.Here is the code


Workbooks.Open "D:\Games\just.xls"
Sheets("KR").Select
Cells.Select
Selection.Copy
Application.CutCopyMode = False
Workbooks("test.xls").Activate
Sheets("Sheet1").Select

Excel.Range("A1").PasteSpecial xlPasteValues

What could be the problem.I get the error messageat the last line
0
Comment
Question by:greatmanu
2 Comments
 

Author Comment

by:greatmanu
ID: 10739873
the file just.xls sheets are linked to an external file
0
 
LVL 50

Accepted Solution

by:
Dave Brett earned 125 total points
ID: 10740019
Hi greatmanu,

remove this line - it stops the copy

Application.CutCopyMode = False

Cheers

Dave
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

816 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now