473,398 Members | 2,368 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,398 software developers and data experts.

copy data from 1 workbook (excel) to another

Hello,

I want to open 2 workbook, , lets say workbook1 and workbook2

now I want to copy data from a sheet name "TEST" in workbook2 and paste the
data to a sheet named "TEST" in workbook.
now , I dont know the size of the data ,so I can't use the get_range option
of the c# . I need a command like select.currentregion of the vba.

antoher problem that I have is that I can't open 2 workbook with the
Excel.Application:
Excel.Application oXL;

Excel.Workbook Wxls =
oXL.Workbooks.Open(wfile,
Type.Missing, Type.Missing, Type.Missing,
Type.Missing,
Type.Missing, Type.Missing, Type.Missing,
Type.Missing,
Type.Missing, Type.Missing, Type.Missing,
Type.Missing,
Type.Missing, Type.Missing);
Excel.Workbook Wxls2 =
oXL.Workbooks.Open(wfile2,
Type.Missing, Type.Missing, Type.Missing,
Type.Missing,
Type.Missing, Type.Missing, Type.Missing,
Type.Missing,
Type.Missing, Type.Missing, Type.Missing,
Type.Missing,
Type.Missing, Type.Missing);

mybe my syntax is not good.

So, Does anyone know how to do this?
Thanks,
Eyal
Nov 17 '05 #1
0 1271

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Jack | last post by:
Windows 2K Pro Access/Excel 2003 Hi there, I have a large number of password protected Excel Workbooks. The files are protected by code that runs when the workbook opens. The code asks the...
0
by: eyal | last post by:
Hello, I want to open 2 workbook, , lets say workbook1 and workbook2 now I want to copy data from a sheet name "TEST" in workbook2 and paste the data to a sheet named "TEST" in workbook. now...
0
by: shan_chennai | last post by:
I have the followign requirement.. I have a worksheet Named 'Sales' in a excel Workbook named "WorkBook1". There is another workbook by Name "Workbook2" which has many worksheets. There is a...
1
by: Jerry J | last post by:
I am sending Excel reports to web clients. Excel opens in internet explorer displaying multiple sheets. It is pretty simple to do and works well. To do it, a client clicks a link to an ASPX page...
0
by: Kay | last post by:
Hi all, I want to copy an entire row from a worksheet to another worksheet, when I set the excel app = visible and step thru the code I can actally see a row is appended to another worksheet,...
10
by: Niklas | last post by:
Hi Before I start coding I need to be sure that nobody else has not done it yet and that I can use it. I need an import utility which import data from Excel to a database or some object in...
7
by: Vanessa | last post by:
hi Everyone, I have two questions on exporting data to Excel using ASP (w/o converting formatted excel file into web page and then plug in the dynamic data): 1. Can we export data into...
0
by: Taxman | last post by:
Windows XP, MS Office Excel 2003 If the tasks, I’m trying accomplish have been addressed previously (separately or in combination). Please, provide the links or keyword search to find them. I’ve...
3
by: samj | last post by:
Looking at code examples, it would seem this is simple, but I can't figure it out. From an Access 2000 form command button, I want to copy all worksheets in an existing workbook to an existing...
4
by: omono84 | last post by:
I know that this should be rather simple but i seem to be missing a step to get it to work. and have been unable to find a solution on the net. The aim is that I click on the open button to find...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.