%
id=Request.QueryString("id")
Set connection = Server.CreateObject("ADODB.Connection")
connection.Open("customers")
SQL="SELECT * FROM Notes WHERE ID_Customer like '"&id&"' ORDER BY Actual_Date;"
Set list=connection.Execute(SQL)
%>
<%
Do while NOT list.EOF
' We don't show the time in the short view of the notes
sdate=Left(list.Fields("Actual_Date"),10)
' We cut the content if it's longer than 50 characters
scontent=list.Fields("Content")
If len(scontent) > 50 then
content=Left(scontent,47)
scontent=content&" ..."
End If
Response.Write("")
list.movenext()
Loop
%>