473,325 Members | 2,774 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,325 software developers and data experts.

how to open Existing Excel file ....

Hello,

i tried to open existNg Excel file by using follow metho bt it give error ... that this file doestnt exist or path is incorrect........

wb = ThisApplication.Workbooks.Open(paramWorkbookPath,
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);

& i also used this method tooo..
it also doesnt work .. :(


wb= ThisApplication.Workbooks.Open(paramWorkbookPath, 0, true, 5,
"", "", true, Excel.XlPlatform.xlWindows, "\t", false, false,
0, true,Type.Missing, Type.Missing);

//////////
second thing how to read data from excel file & use it for charts...

i am using Excel 2007 , C# 2005 ... all z doing using COM...

waiting for reply..
thanks...........
Jan 16 '08 #1
4 2962
RedSon
5,000 Expert 4TB
Hello,

i tried to open existNg Excel file by using follow metho bt it give error ... that this file doestnt exist or path is incorrect........

wb = ThisApplication.Workbooks.Open(paramWorkbookPath,
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);

& i also used this method tooo..
it also doesnt work .. :(


wb= ThisApplication.Workbooks.Open(paramWorkbookPath, 0, true, 5,
"", "", true, Excel.XlPlatform.xlWindows, "\t", false, false,
0, true,Type.Missing, Type.Missing);

//////////
second thing how to read data from excel file & use it for charts...

i am using Excel 2007 , C# 2005 ... all z doing using COM...

waiting for reply..
thanks...........
There must be something wrong with your paramWorkbookPath.
Jan 16 '08 #2
that problem of method z solved i gave the the wrong extention .. nw
problem z no file z opened ... nothNg z happened...

so plz help me out ...

(i'm usNg C#2005, Excel 2007 & COM)

thanks
Jan 17 '08 #3
RedSon
5,000 Expert 4TB
that problem of method z solved i gave the the wrong extention .. nw
problem z no file z opened ... nothNg z happened...

so plz help me out ...

(i'm usNg C#2005, Excel 2007 & COM)

thanks
What? Do you think you could use proper English so I can tell what the heck you are talking about?
Jan 17 '08 #4
i used the followning fuctions But when i click the button ... nothNg is done ... ( means excel file didn't open)............

tring workbookPath = "G:\\test.xls"; // Add your own path here
Microsoft.Office.Interop.Excel.Workbook excelWorkbook = ThisApplication.Workbooks.Open(workbookPath, 0,
false, 5, "", "", false, Microsoft.Office.Interop.Excel.XlPlatform.xlWindow s, "", true,
false, 0, true, false, false);

or this one ........

wb = ThisApplication.Workbooks.Open(paramWorkbookPath,
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);
///////////
Can u please guide me ... how to open Existing Excel File ...

& how to get data from it ...

(i am using C# 2005, Excel 2007 & COM)

thanks................
Jan 17 '08 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

13
by: Allison Bailey | last post by:
Hi Folks, I'm a brand new Python programmer, so please point me in the right direction if this is not the best forum for this question.... I would like to open an existing MS Excel spreadsheet...
1
by: Jim | last post by:
This should really be simple, but I can't figure it out. I have some VB that exports a table in an Excel format ("C:\NewReport.xls"). After the export is done, I simply want to have some code...
1
by: Joe Cletcher | last post by:
It's got to be simple, but there doesn't seem to be an "open" method for opening an existing Excel spreadsheet in a VB.Net. What do I do after the following? Dim myExcel As...
2
by: Peter S. | last post by:
I have an ASP.NET page that invokes a web control written in C#. What I want to do is (based on the session ID) display a certain spreadsheet that exists on a network drive. I want the webcontrol...
3
by: Fauna | last post by:
I'm having an Excel problem. I hope this is the appropriate group to post in. I am converting an existing classic ASP web application to ASP .NET. There is a reporting menu where the user...
0
by: kennedystephen | last post by:
This seems like a simple task. But it's kicking my butt. I have 1 existing excel file. I want to copy the first 50 rows from that excel file, and put them in a new excel file. Then I want to get...
9
by: Looch | last post by:
Was hoping I could get some insight on this. I added a text box and command button to a web page and added the code in the .vb file to open an existing Excel file based on what was typed in the...
22
by: robertgregson | last post by:
Using C#, .NET3.5, Visual Studio 2008 and WCF on Windows VISTA SP1, I have written a service, service host (as a C# console application) and a client. The service uses...
4
by: manojspromantr | last post by:
Hi Friends I am trying to design a form where i need to browse a excel file using a open dialog box & append the same in a Table at the database.Any how i have taken care that the Table fields are...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...

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.