首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > .NET > C# >

Dear buddy, I am mad, can you help me and don't drop me as your sacrifice,该怎么处理

2012-06-12 
Dear buddy, I am mad, can you help me and dont drop me as your sacrificeHi,When I am trying to imp

Dear buddy, I am mad, can you help me and don't drop me as your sacrifice
Hi,
When I am trying to import data from excel to table it's giving me following error :-
An exception of type 'System.Data.OleDb.OleDbException' occurred in System.Data.dll but was not handled in user code

Additional information: External table is not in the expected format.

I am using following code:-
Collapse
OleDbConnection excelConn = new OleDbConnection();
excelConn = new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source='" + filelocation + "';Extended Properties=Excel 8.0"); 
excelConn.Open();

[解决办法]
try{
}cacth{
}
print error!


[解决办法]
http://support.microsoft.com/kb/825738/zh-cn
hope it can help you

热点排行