Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Excel To ADO DataSet Error
Message
Information générale
Forum:
ASP.NET
Catégorie:
Code, syntaxe and commandes
Divers
Thread ID:
01382016
Message ID:
01382084
Vues:
44
>I'm trying to get the connection string right. If I use:
>
>
>string sExcelConnString =
>    "provider=Microsoft.Jet.OLEDB.4.0; data source='" + sFileName + " '; " + "Extended Properties=Excel 8.0;";
>
>then it works fine.
>
>However, if I add the "Hdr=Yes" on the end...
>
>
>string sExcelConnString =
>    "provider=Microsoft.Jet.OLEDB.4.0; data source='" + sFileName + " '; " + "Extended Properties=Excel 8.0;Hdr=Yes";
>
>
>
>I get "Could not find installable ISAM". I googled it but I don't see what the problem is.
>
>Anyone?

Extended Properties , they are expected to be in quotes, like:
string sExcelConnString =
    "provider=Microsoft.Jet.OLEDB.4.0; data source='" + sFileName + " '; " + "Extended Properties=""Excel 8.0;Hdr=Yes""";
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform