Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8540873
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T11:41:54+00:00 2026-06-11T11:41:54+00:00

It is necessary for me to write an application using C# .net that will

  • 0

It is necessary for me to write an application using C# .net that will edit specific .mdb files.

It’s purely an in-department application for reading in-department files that debateably shouldn’t be .mdb files, but I don’t have a choice in that matter. I am pushing for changing to XML files, but that’s a different matter.

The files are very much finite, 3ish tables with 100ish records each; so I hope to read the entire databases into application specific objects. Anything erroneous will be ignored and a new database copy will overwrite the previous one. The databases are a very specific format and easy for me to validate or throw out.

There seems to be many methods for actually reading/writing mdbs in .net which has left me confused. Can anyone suggest a best one?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T11:41:55+00:00Added an answer on June 11, 2026 at 11:41 am

    You can try with this code – based on Oledb provider

    var mdb = "c:\MyDB.mdb"; 
    var myDataTable = new DataTable(); 
    using(var connection = new OleDbConnection(....."))
    { 
    
    //Here sample format of string connection
    //"Provider=Microsoft.Jet.OLEDB.4.0;User ID=Admin;Data Source=" 
    //+ mdb + ";Mode=Share Deny None;Extended Properties='';Jet OLEDB:System database='';Jet OLEDB:Registry Path='';Jet OLEDB:Engine Type=4;Jet OLEDB:Database Locking Mode=0;Jet OLEDB:Global Partial Bulk Ops=2;Jet OLEDB:Global Bulk Transactions=1;Jet OLEDB:Create System Database=False;Jet OLEDB:Encrypt Database=False;Jet OLEDB:Don't Copy Locale on Compact=False;Jet OLEDB:Compact Without Replica Repair=False;Jet OLEDB:SFP=False
    
    
    connection.Open(); 
    var query = "SELECT * from TABLE"; //Adjust your query
    
    var adapter = new OleDbDataAdapter(query, connection); //This assigns the Select statement and connection of the data adapter 
    
    OleDbCommandBuilder oleDbCommandBuilder = new OleDbCommandBuilder(adapter); //This builds the update and Delete queries for the table in the above SQL. this only works if the select is a single table. 
    
    dadapt.Fill(MyDataTable); 
    
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am currently working on this application(C#,WPF,LINQ2XML,.NET 4.0) that displays details for 'Animals'. An
I have taken over support of a VB .Net application that makes use of
I'm trying to write an Eclipse rcp application using only jruby, or at least
I have to write an application that is essentially a proxy server to handle
I recently did some performance testing and analysis of an ASP.NET application using out-of-process
I am trying to write a simple application that monitors the COM port and
I am attempting to write an application that automatically sets the Android default alarm
I'm using Lucene.Net + SimpleLucene in my asp .net mvc application. There is a
I have previously been using Chilkat Zip .Net to generate backup files from my
I've got an application using sockets (which I did not write, so bear with

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.