我想将数据从excel导入到asp.net中的sqlserver 2005中 [英] I wanna import the data from excel into sqlserver 2005 in asp.net
本文介绍了我想将数据从excel导入到asp.net中的sqlserver 2005中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
你们可以为我推荐任何有价值的解决方案。
i想从excel导入一些表值到sqlserver
我跟着以下链接
http://www.aspdotnet-suresh.com/2010/09/import-data-from-excel-to- sql-database.html [ ^ ]
i得到错误
Microsoft Office Access数据库引擎可以找不到对象'Sheet1 $'
can u guys refer me any valuable solution for this .
i wanna import some table values from excel into sqlserver
and i was followed the below link
http://www.aspdotnet-suresh.com/2010/09/import-data-from-excel-to-sql-database.html[^]
i got the error
"The Microsoft Office Access database engine could not find the object 'Sheet1$'"
推荐答案
'
reefer it ... :)
http:// cleancode4devs.blogspot.in/2012/01/import-data-from-excel-to-sqlserver.html [ ^ ]
reefer it...:)
http://cleancode4devs.blogspot.in/2012/01/import-data-from-excel-to-sqlserver.html[^]
private bool sheetNameValidation()
{
//this is ur uploaded file name
string FileName = Path.GetFileName(FileUpload.PostedFile.FileName);
string Extension = Path.GetExtension(FileUpload.PostedFile.FileName);
string FolderPath = ConfigurationManager.AppSettings["FolderPath"];
string FilePath = Server.MapPath(FolderPath + FileName);
string ExcelConnectionString = "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=" + FilePath + ";Extended Properties=" + "\"Excel 12.0;HDR=YES;\"";
string myExcelDataQuery = "Select top 1 * from [Data
这篇关于我想将数据从excel导入到asp.net中的sqlserver 2005中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文