none
excel refereences RRS feed

  • Question

  • Hi,
    I am running the .net 2.0 code below in windows server 2003 R2, standard edition, service pack 2.

    string connectionString = @"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Work\Data.xls;Extended Properties=""Excel 8.0;HDR=YES;""";

    DbProviderFactory factory = DbProviderFactories.GetFactory("System.Data.OleDb");

    Error is:
    Error 4 The type or namespace name 'DbProviderFactory' could not be found (are you missing a using directive or an assembly reference?) 

    I have tried adding The following dlls but error still remains:
    Interop.Excel.dll
    Microsoft.Office.Core

    What references do I need to add to get this to work?

    Thanks

    Tuesday, February 5, 2008 9:37 AM

Answers

All replies