Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Modules / DAO / VBA / January 2006

Tip: Looking for answers? Try searching our database.

Copy excel sheet to another excel file

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Zurn - 13 Jan 2006 16:36 GMT
What code will help me with copying an excel sheet to another ecel file.

I open two excel files with code in Access environment.

Now I want values from one sheet to another (Pastespecial only the values)...

Where can I find info about this matter?

Thx,
Zurn
SteveS - 14 Jan 2006 17:50 GMT
Zurn,

You should ask your question in one of the Excel newsgroups.

This newsgroup is for the Access database.

HTH
Signature

Steve S
--------------------------------
"Veni, Vidi, Velcro"
(I came; I saw; I stuck around.)

> What code will help me with copying an excel sheet to another ecel file.
>
[quoted text clipped - 6 lines]
> Thx,
> Zurn
Ed Adamthwaite - 16 Jan 2006 06:12 GMT
Hi Zurn,
if you want to copy before a sheet in the destination Excel file:

        xlApp.Sheets("Sheet1").Copy
Workbooks("MyOtherWorkBook.xls").Sheets(1)

if you want to copy after a sheet in the destination Excel file (notice the
comma):

        xlApp.Sheets("Sheet1").Copy ,
Workbooks("MyOtherWorkBook.xls").Sheets(1)

I assume that you have something like "xlApp" as the object variable for the
Excel.Application.

HTH, :-)

Ed Adamthwaite

> What code will help me with copying an excel sheet to another ecel file.
>
[quoted text clipped - 7 lines]
> Thx,
> Zurn
Zurn - 16 Jan 2006 08:58 GMT
I did not want a new sheet, I copied the values to the "source" sheet of the
new excel file. Your code was very helpful. Thank you

    xlApp.Sheets(1).cells.Copy
xlApp.Workbooks("accessDB.xls").Sheets("source").cells

*Zurn*

> Hi Zurn,
> if you want to copy before a sheet in the destination Excel file:
[quoted text clipped - 26 lines]
> > Thx,
> > Zurn
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.