This sample shows you the simplest way to use parameters. Change for OleDB
(MS Access Jet) the SQLClient.SQLxxxx for OleDB.OleDBxxx
Dim cmd As New SqlClient.SqlCommand("SELECT * FROM MyTable WHERE MyDate BETWEEN @BeginDate And @EndDate", ConnectionObject)
cmd.Parameters.AddWithValue("@BeginDate", CDate(txtBeginDate.text))
cmd.Parameters.AddWithValue("@EndDate", CDate(txtEndDate.text))