Copy and Paste problem

Hi,
I have made macros to copy sheet form one file and paste into another, 
however somtimes there is a problem when for example I change print area 
in target file or anything else I recive a message:
Error the target area is not the same size as the copy area what is 
starnge as area doesnt change, only solution i found is simply delete 
the file and make a new one.
Im sure you have same problem but did you find a solution ?
0
hokah (84)
1/3/2005 8:54:12 PM
excel 39879 articles. 2 followers. Follow

1 Replies
536 Views

Similar Articles

[PageSpeed] 39

Piotr,

I'm not sure what the Print Area has to do with copying and pasting.  Have 
you determined for sure which statement in your code is generating the 
error?  Perhaps if you post the code of the macro, and any other relevant 
information about the sheets.

Generally, in a macro, you copy/paste like this:

1)  This method doesn't use the clipboard.
Workbooks(Source).Sheets(Whatever).Range(Whatever).Copy Destination:= 
Workbooks(Destination).Sheets(Whatever).Range(Whatever)

2) This method does use the clipboard.
Workbooks(Source).Sheets(Whatever).Range(Whatever).Copy
Workbooks(Destination).Sheets(Whatever).Range(Whatever).Paste

In either case, it will start the paste in the upper-left cell of the 
destination range, ignoring the actual extents of that range; it pastes the 
entire range from the Copy.   You need only specify the upper left cell.

-- 
Earl Kiosterud
mvpearl omitthisword at verizon period net
-------------------------------------------

"Piotr" <hokah@wp.pl> wrote in message news:crcbdk$8k6$1@inews.gazeta.pl...
> Hi,
> I have made macros to copy sheet form one file and paste into another, 
> however somtimes there is a problem when for example I change print area 
> in target file or anything else I recive a message:
> Error the target area is not the same size as the copy area what is 
> starnge as area doesnt change, only solution i found is simply delete the 
> file and make a new one.
> Im sure you have same problem but did you find a solution ? 


0
nothanks4548 (968)
1/4/2005 10:01:24 PM
Reply:

Similar Artilces:

DVD Copy Pro for Mac
[b]DVD Copy Pro for Mac[/b] is a DVD copy software that can support D9 to D5 compression. With simple operation, it can save DVD in four different ways including directly burning to DVD disc, saving as DVD folder, copying into DVD media format that can be played by DVD Player directly, and converting as ISO file for easy movie management. Now this cool Mac DVD Copy also supports the latest released Snow Leopard. You can download [b][url=http://www.dvd-copy-mac.net/download/dvd-copy-pro-mac.zip]DVD Copy Pro for Mac[/url][/b] freely right now. [b]More information:[/b][quote]http://www.dvd-...

IF OR problem
Not sure where to start with this formula but I need a single formula that results in multiple possible answers. Here is what I have If E3 = "U6" then “120” or = "U8" then “150” or = "U10" or "U12" or "U14" or "U16" and G3 = “com” then “350” or = "U10" or "U12" or "U14" or "U16" and G3 = “dev” then “380” or = "U10" or "U12" or "U14" or "U16" and G3 = “Tier” then “410” or = "U18" then “375” C...

Problems opening Excel files using DFS links
Hi, I origianlly posted this question under networking, but this may be a better forum for my question. Have a weird problem. We're on a Windows 2000 domain where the users' home directory has been redirected using this syntax: \\fqdn.xxx\dfs root\sharename\%username%. The DFS root server is a member file server that holds the majority of the network shares (including the user profiles and home folders). The DFS root is registered in our AD. Here's the problem: Occasionally someone will try to open an Excel file on a share via a DFS link and will get an error message stati...

Import/copy calendar in Outlook 2003
I got a new computer and installed Office 2003, and wanted to move my calendar to the new PC. I created a new data file called Personal Folders from Old PC. I wanted to copy my calendar OVER my current one in Personal Folders, but don't see a way to do so. I can copy my old calendar into the Pesonal Folders, but can't delete the new, empty Calendar. So I have Calendar, and Calendar 1 under my Personal Folders. Any way to just import/copy my reminders/appointments into my new calendar? Thanks for any advice. Ck G'Day Cathy, 1. Use the Folder List 2. Click on the OLD Cal...

Copy info from one workbook to another?
I have a problem I have a workbook with the function i want like a discribe here. The problem is i want to split the workbook but i don`t know how. Is it possible to have a main workbook with information from other workbooks at each worksheet? I have 20 workbooks with information. I would like to have a main workbook with on sheet1 every row from the 20workbooks with category1, on sheet2 every row from the 20workbooks with category2, etc, etc. The information in the 20workbooks in always only on sheet. The Colum in which the data is has no fix end. I go to fill in the rows trough a...

Secondary Copy
Hi, My customer using Great Plains modified report(Primary Copy). Now he wants new report something similar to the modified GP report with very few changes. I tried to copy the modified report and planned to use us a secondary copy. But the report has temp tables, so I am unable to make secondary copy. Can some one help me in how to make a new report something similar to the modified report, where to launch it. Whether it is possible throught VBA & Modifier? Regards Selvakumar.S A report with a temporary table can only be a primary copy. This is because only a primary copy can b...

local copy of mail
How do you store a copy of all your mail on you local computer when using Exchange? You setup an OST/Offline Folders file. Check with your mail admin if they support that configuration. "Brandon Baker" <brandon@discussions.microsoft.com> wrote in message news:epNKuJ19FHA.4004@TK2MSFTNGP14.phx.gbl... > How do you store a copy of all your mail on you local computer when using > Exchange? > ...

Outlook 2000 SP3
How can I copy my mail and calendar to CD so that I can take my received and sent mail history to a new computer with Outlook installed? Thanks. >-----Original Message----- >How can I copy my mail and calendar to CD so that I can >take my received and sent mail history to a new computer >with Outlook installed? Thanks. >. > All your data saves in C:\Documents and Settings\Username\Local Settings\Application Data\Microsoft\Outlook\archive.pst and C:\Documents and Settings\Evgeni\Local Settings\Application Data\Microsoft\Outlook\outlook.pst You can either install instan...

Text to column and paste special transpose
Hi All, I have 1 table like this item_number qty ref 00010-001 3 U34,U36,U43 00013-001 2 U16,U21 12505-001 3 U32,U33,U42 12512-001 3 U5,U6,U27 and 1 want it to become like this item_number qty ref 00010-001 3 U34 00010-001 3 U36 00010-001 3 U43 00013-001 2 U16 00013-001 2 U21 12505-001 3 U32 12505-001 3 U33 12505-001 3 U42 12512-001 3 U5 12512-001 3 U6 12512-001 3 U27 Anybody can help me to program it in macro.. usually i do it manually and have to redo again do to careless. After using Text to Columns on Column C.......comma delimited.........Run the Reorganize macro. Sub ReOrganize...

Merging Problems
CRM 4 Professional We recently upgraded to Version 4. Now, when I try to merge records, I get an error that says simply, "No Attribute." This happens with both accounts and contacts. I created some "test" accounts and contacts that are definitely not associated with any other entities and I get the same problem. Any help is appreciated. ------=_NextPart_0001_713E8B87 Content-Type: text/plain Content-Transfer-Encoding: 7bit Hi Talina, Thanks for posting in. This is Ken in Online Partner Support. I am working on this issue at Microsoft.Private.Directaccess.Crm. He...

Copy picture ossice wizard
I have project 2007 standard edition, but the button is not working at all? Any suggestions Hi, The wizard is IMHO useless. Go to Roport, Copy Picture and do without the Wizard what millions have done before the Wizard existed. HTH -- Jan De Messemaeker Microsoft Project Most Valuable Professional +32 495 300 620 For availability check: http://users.online.be/prom-ade/Calendar.pdf "Enrique" <Enrique@discussions.microsoft.com> wrote in message news:72B5AA6C-67AE-468D-B6AE-FF16F52E57BD@microsoft.com... >I have project 2007 standard edition, but the bu...

Click on link problems
When I click on a url link in email---a box opens saying "Open Link Browser". And also a browser window. How do I get rid of the smaller link browser? Point it to iexplore.exe -- Robert Sparnaaij [MVP-Outlook] www.howto-outlook.com Tips of the month: -What do the Outlook Icons Mean? -Create an Office 2003 CD slipstreamed with Service Pack 1 ----- "Robin" <robinhood2@juno.com> wrote in message news:frelk01n5cpu241v2l277fd2lajui8kokj@4ax.com... > When I click on a url link in email---a box opens saying "Open Link > Browser". And also a browser...

Paste Values not working in Excel 2003 (?)
Hi, Using Excel 2003 with Win xp Pro I copy a range of cels, then I choose EDIT > PASTE SPECIAL > VALUES and it does NOT paste ALL the cel contentent... It does paste all the cels, but only the first 3 lines of each cel's content. Is there any limitation in the number of characters ? Thanks ALex This is not the exact problem you describe, put perhaps it's related: XL2000: "255 Characters in Cell" Error When Copying Worksheet, at: http://support.microsoft.com/default.aspx?scid=kb;en-us;213548 -- HTH - -Frank Isaacs Dolphin Technology Corp. http://vbapro.com ...

Copy and paste versus copy and insert copied cells
What is the difference between these commands? Try them, it is pretty easy to see the difference -- Regards, Peo Sjoblom "Alana" <Alana@discussions.microsoft.com> wrote in message news:879FED29-5541-41B0-BB2C-7108D42ED593@microsoft.com... > What is the difference between these commands? ...

Multiple signatures problem in outlook 2003
Hi We have two accounts in outlook, one the exchange and the other a pop account so we can sent email under two separate domains (units of business). We need to have separate signatures for each account. We assumed outlook 2003 provided that on its own and upgraded outlook only to outlook 2003 while leaving office versions to below 2003. Now it turns out we also need word 2003 for this feature to work as standard. My question is; is there any way to create an email with a signature other than the default even if it is through vba code? Thanks Regards Not that I know of. --� Milly Sta...

subtotal copy and paste
Hi I have used the subtotal option in Excel and this is fine. I have also collasped the list so only the subtotal for each category is visible. However I want to copy and paste this list (just the subtotal) into another sheet When I do this it expands and shows all the results. Is it possible to just copy the visible bit. I have looked in paste special but no luck Cheers Hager On Jan 21, 6:38=A0am, Hager <Ha...@discussions.microsoft.com> wrote: > Hi > > I have used the subtotal option in Excel and this is fine. I have also > collasped the list so only the...

Copy above fails one way, copy below fails another way
I have a table of blood pressure readings that looks something like this: A B C D E 11 12 Averages: 134 83 74 13 R# Date Sys Dia Pul 14 4 8/17/08 138 87 72 15 3 8/15/08 130 84 76 16 2 8/12/08 137 83 70 17 1 8/11/08 129 79 76 Cell A14 contains =A15+1 Cell C12 contains =AVERAGE(C14:C17) Cell D12 contains =AVERAGE(D14:D17) Cell E12 contains =AVERAGE(E14:E17) Every time I take a new reading, I want to add a row to the top of the table, between row 13 (the header) and row 14 (the previous top row). I want to push a...

Printing problem #10
One of our staff has received a workbook with single page sheets in it. But every time we attempt to print it, the printer spews out 20+ sheets although the document only has one page and we can see the print area borders. How do we fix this? -- Yours truly - Canadian Newsgirl hi. Excel is pretty squirrelly when it comes to printing. Highlight the area you want to print. click File>Print area>set print area. >-----Original Message----- >One of our staff has received a workbook with single page sheets in it. But >every time we attempt to print it, the printer spews out 2...

Problem using xml writer
Hi I want to create following xml document using xmlwriter <?xml version="1.0" ?> - <epps> - <remit_trn type="technical"> <remit_date_dtm dtm = "201" >test</remit_date_dtm> <rmt_payee_n1>test</rmt_payee_n1> <rmt_payee_n1>test</rmt_payee_n1> <rmt_ref>test</rmt_ref> </remit_trn> </epps> I wrote the code to do the same but when I run the code I am getting following exception on executing the following line xmlw.WriteAttributeString("dtm01" , "201&quo...

Business Portal "Copy to Excel" not working in Query pages
Hi, I am using Business Portal 4.0. When browsing through one of the queries pages in Business Portal, i clicked "Copy to Excel" icon. I got an error saying "The Office Web Components (OWC) must be installed to copy results to Excel." at the bottom. I am using Office 2007 on my machine. I came to know that Microsoft Office Web Components will no longer be shipping in Microsoft Office. I tried installing Office 2003 Add-in: Office Web Components from http://www.microsoft.com/downloads/details.aspx?familyid=7287252C-402E-4F72-97A5-E0FD290D4B76&displaylang=en a...

Outlook Archiving Problem #2
Outlook will ask me if I want to Archive, I hit ok. Mine in set to archive items 6mos old. Nothing shows up in my archived folder list. Help. I am the main email address for our company, my inbox is huge. Beth Check the Modified date on the items that aren't being archived as you think they should. That's the date Outlook uses to determine whether or not an item is ready to be AutoArchived, and a simple action such as moving the item to another folder can change the Modified date. More information and a list of actions that change the Modified date can be found here: http:...

Copying graphs
Hi Is it possible to range value a graph ie I would like to copy the graph to another workbook, show all the information but without the links? Thanks You could copy the chart as a picture, then paste it wherever you want. Select the chart, hold Shift while clicking on the Edit menu, Choose Copy Picture, and select the On Screen and As Picture options, then go to the other workbook/sheet and Paste. - Jon ------- Jon Peltier, Microsoft Excel MVP Tutorials and Custom Solutions Peltier Technical Services, Inc. - http://PeltierTech.com _______ "Dixie" <Dixie@discussions.micr...

Problem with Video Codecs
Hi =) i have a .mkv file (matroska video) that opens fine in WMP and all, but there is no video along with the audio. i am already in possesion of all the necissary codecs for video files such as mkv's because i have others that work. upon viewing the file's properties when in the WMP playlist (playing only audio at this point) i notice that under the files advanced settings (first tab) the file HAS NOT been assigned a video codec AT ALL, whereas it HAS been assigned an audio one. i also opened another one of my .mkv files and it has been assigned a video codec called...

Custom Form Property, Parameter Query Access 2007 Problem
In most of my Access Forms I create a custom form property like the following: Form called "fMgr" Public Property Let prpAssignEventGroup(ByVal v As Long) iAssignEventGroup = v End Property Public Property Get prpAssignEventGroup() As Long prpAssignEventGroup = iAssignEventGroup End Property Then in my query I create a parameter like the following: [Forms]![fMgr].[prpAssignEventGroup] here is the SQL: PARAMETERS [Forms]![fMgr].[prpAssignEventGroup] Long; SELECT tEventGrpsAssgn.* FROM tEventGrpsAssgn WHERE tEventGrpsAssgn.EGRP_ID=[Forms]![fMgr].[prpAssi...

Problem Deploying web site with Crystal Reports
I have created a asp.net web site using Visual Studio 2008 and Crytal Reports. I have two small reports that work perfectly on my development machine, and I have tripple checked that I have added reference to the CrystalDecisions.CrystalReports.Engine in my project. I do not have any CrystalReports dll's in my bin folder but when select my project and then click on the properties window the following refereces are there. CrystalDecisions.CrystalReports.Engine, CrystalDecisions.EnterpriseFrameWork, CrystalDecisions.Enterprice.InfoStore, CrystalDecisions.ReportAppServer.C...