Hi,
The following code is use ADODB to connect the database. By this way I would like to change the following coding by using "OleDbConnection", how can I change it?
RstBoa = New ADODB.Recordset
BoaSQL = "Select * From QtyVar ORDER BY QtyVarID"
RstBoa = ConnBoa.Execute(BoaSQL)
With RstBoa
If Not .EOF Then
Do While Not .EOF
'Retrieve Quantity Variance
CboVar.Items.Add(RstBoa("QtyVar").Value)
RstBoa.MoveNext()
Loop
End If
.Close()
End With
ConnBoa.Close()
RstBoa = Nothing
ConnBoa = Nothing