Below is my code snippet.
This code runs behind an ASP GUI. Backend is Mysql
When I debug this code and reach the line
Do Until rec_ddas_Feedback.EOF = False
It gave me following error
"There is no source code available for current location."
Dim rec_ddas_Feedback As New ADODB.Recordset
Dim msgString As String
Dim msgcounter As Integer
If rec_ddas_Feedback.State = ADODB.ObjectStateEnum.adStateOpen Then
rec_ddas_Feedback.Close()
rec_ddas_Feedback.Open("SELECT dtofadd,dtofacc,remarks,Feedback from DDAS_remarks WHERE dtofadd BETWEEN ADDDATE(CURDATE(),INTERVAL -10 DAY) AND CURDATE() AND therapsitname='" + mdlusername + "' AND Feedback <> ''", cn, ADODB.CursorTypeEnum.adOpenKeyset, ADODB.LockTypeEnum.adLockOptimistic)
msgString = ""
msgcounter = 1
Do Until rec_ddas_Feedback.EOF = False
msgString = msgString + "<b>Message #" + msgcounter + " :</b><br>"
msgString = msgString + "<Pre>For your remark on dated <b>" + Format(rec_ddas_Feedback.Fields("dtofadd").Value, "DD MMMM YYYY") + " </b>about amount mismatches in account of " + Format(rec_ddas_Feedback.Fields("dtofacc").Value, "DD MMMM YYYY") + "</Pre></br>"
msgString = msgString + ". Your reply :" + rec_ddas_Feedback.Fields("remarks").Value
msgString = msgString + "<br>. Feedback : " + rec_ddas_Feedback.Fields("remarks").Value
rec_ddas_Feedback.MoveNext()
msgcounter = msgcounter + 1
Loop
lblMsg.Text = msgString
But, when I place the query in immediate window to replace the variable name with variable value and I ran the query on mysql QA it gave me one record.