I using ADODB and recordset and I facing a problem in crystal selection fomula and any expertise kindly please correct and advice my error!
Dim ItemNoFrom as string, ItemNoTo as string
ItemNoFrom = "ABC001"
ItemNoTo = "ABC100"
crReport.action = 0
crReport.selectionformula = "Select * from tblDB where itemno >= '" & ItemNoFrom & "' and itemno <= '" & ItemNoTo & "'"
It occur error for "... the remaining text is not part of SQL .... "
I try before in
crReport.SQLQuery = "Select * from tblDB where itemno >= '" & ItemNoFrom & "' and itemno <= '" & ItemNoTo & "'"
But it return me wrong data. Any body kindly please help.
Dim ItemNoFrom as string, ItemNoTo as string
ItemNoFrom = "ABC001"
ItemNoTo = "ABC100"
crReport.action = 0
crReport.selectionformula = "Select * from tblDB where itemno >= '" & ItemNoFrom & "' and itemno <= '" & ItemNoTo & "'"
It occur error for "... the remaining text is not part of SQL .... "
I try before in
crReport.SQLQuery = "Select * from tblDB where itemno >= '" & ItemNoFrom & "' and itemno <= '" & ItemNoTo & "'"
But it return me wrong data. Any body kindly please help.