Logo 
Search:

Sharepoint Forum

Ask Question   UnAnswered
Home » Forum » Sharepoint       RSS Feeds

OleDbConnection String SharePoint

  Asked By: Kyle    Date: Aug 21    Category: Sharepoint    Views: 1782

I am trying to access an excel file that is in a list in my SharePoint site.

My connection string is as follows:


this.Connection = "Provider=Microsoft.ACE.OLEDB.12.0;WSS;IMEX=2;RetrieveIds=Yes;DATABASE=" + siteUrl + ";LIST={" + listId + "};Extended Properties=\"Excel 12.0 Xml;HDR=YES\"";

where siteUrl is my current SPSite and listId is the Guid of the List that file is in. The list is part of the SPSite. It acts like it is stuck in an infinite loop when it tries to make the connection. It never shows an error message or display the next page at all, so I have a feeling that the connection string is right, but I might be missing something else. Can anyone give me some insight?

Share: 

 

1 Answer Found

 
Answer #1    Answered By: Jerod Carrillo     Answered On: Aug 21

According to this web site  http://www.connectionstrings.com/sharepoint#p84 you can use the provider to access sharepoint  list element or Excel files but not Excel files stored in sharepoint lists.

 
Didn't find what you were looking for? Find more on OleDbConnection String SharePoint Or get search suggestion and latest updates.