Rhubarb

I created a C# application that reads Excel data sent to us from our users. This was working just fine until we started receiving data from a new client. The client swore that the files are spread sheets and after alot of head scratching (and long meetings with the user), we finally figured out that the files were in fact spreadsheets; however, they were created using an application called OpenOffice.

My question is, can I use OleDb or Odbc to open these type files and if so how




Re: .NET Framework Data Access and Storage Reading Non-Microsoft files

OmegaMan

Rhubarb wrote:

I created a C# application that reads Excel data sent to us from our users. This was working just fine until we started receiving data from a new client. The client swore that the files are spread sheets and after alot of head scratching (and long meetings with the user), we finally figured out that the files were in fact spreadsheets; however, they were created using an application called OpenOffice.

My question is, can I use OleDb or Odbc to open these type files and if so how



You may have to just try it....since Open Office is an open source product and not Microsoft, you may not get a lot of responses here...try the Open office forum ...





Re: .NET Framework Data Access and Storage Reading Non-Microsoft files

Rhubarb

Yeah, aint that typical. I'm the one using a microsoft product and it's a customer using an open source. I've got no control over what they choose to use.

Problem is, I've already asked the same question in the OpenOffice site. Got the same "cold shoulder".

Seems the "wall" exists everywhere.

Thanks anyway.






Re: .NET Framework Data Access and Storage Reading Non-Microsoft files

Ivan Pavlovi?

Hi Rhubarb,

OpenOffice stores all data in XML format. That xml file is zipped and given approppriate extension, like *.sxc for spreadsheet file. You can try to unzip file and load data into Dataset or XmlDataDocument and then use it in your application.






Re: .NET Framework Data Access and Storage Reading Non-Microsoft files

Rhubarb

Thank you Ivan. I'll try that and then politly ask our users to "convert" over to Excel May never happen but would make my life easier.

Greg






Re: .NET Framework Data Access and Storage Reading Non-Microsoft files

OmegaMan

Rhubarb wrote:

Thank you Ivan. I'll try that and then politly ask our users to "convert" over to Excel May never happen but would make my life easier.

Greg



Couldn't you have the user save to CSV format or possibly Xml I am in an industry where Excel rules the roost and making anyone go to Xml is almost impossible...so I may already know your answer. <g>





Re: .NET Framework Data Access and Storage Reading Non-Microsoft files

Rhubarb

This is the only user (knock on wood) that uses a non-microsoft app. I personally have nothing against open-source (I dual boot Windows XP Pro and Linux at home, don't tell anyone), but would be nice if everyone could at least "talk" to each other (meaning applications).

I'm thinking of asking them to just send me a text file and I'll create an app to create a CSV. The problem is the user is not a programmer and actually got a "deer in the headlights" look when I brought that subject up.

Greg






Re: .NET Framework Data Access and Storage Reading Non-Microsoft files

OmegaMan

If you can convince/trian the user to save to CSV, assuming that data functionality is not lost, here is a blog Opening CSV or Text Files as Calc Spreadsheets--and Vice Versa to save to CSV in open office...scroll down halfway. Good luck.





Re: .NET Framework Data Access and Storage Reading Non-Microsoft files

nmanx62

That OpenOffice user should be able to save files in MS Office compatible format. The preference can be set for a particular file as it is saved the first time or for all file types from the start. If they were to set saves to MS Office compatibility for all files, they will have no adverse affects to their ue of any file in OO.