// Collection of code snippets by Arne Vajhøj // (likely posted to comp.os.vms/INFO-VAX, INFO-TPU, MACRO32, eksperten.dk, newz.dk, LinkedIn or other place sometime between 1990 and now) using System; using System.Data; using System.Data.OleDb; namespace E { public class Program { public static void Main(string[] args) { OleDbConnection con = new OleDbConnection(@"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Databases\MSAccess\Test.mdb;"); con.Open(); OleDbDataAdapter da = new OleDbDataAdapter("SELECT f1,f2 FROM t1", con); DataSet ds = new DataSet(); da.Fill(ds, "t1"); Console.WriteLine(ds.Tables["t1"].Rows[2]["f2"]); } } }