C # connects access,dbf through OLE DB.

Source: Internet
Author: User
Tags dbase ole

64-bit program requires download driver Accessdatabaseengine_x64.exe

32-bit program requires download driver AccessDatabaseEngine.exe

Official: https://www.microsoft.com/zh-cn/download/details.aspx?id=13255

The version of Office to be installed with is always

64-bit Links

     This string. Format ("Provider = microsoft.ace.oledb.12.0;D ata Source ={0}; Extended properties=dbase IV; " , FilePath);      This New OleDbConnection (connstring);

32-bit Links

     This string. Format ("Provider = microsoft.jet.oledb.4.0;D ata Source ={0}; Extended properties=dbase IV; " , FilePath);      This New OleDbConnection (connstring);

Basic code

      This New OleDbConnection (connstring);           = Connection.createcommand ();  Connection.Open ();      = Sql;      int count = DC. ExecuteNonQuery ();     Connection.close ();     dc. Dispose ();

C # connects access,dbf through OLE DB.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.