"raj chahal" <in**@digitise.info> wrote in message
news:OT*************@TK2MSFTNGP10.phx.gbl...
Thanks for your help.
Can I also give the user to make a piece of text bold without a 'rich text
editor'. If not any recommendations?
Thanks in advance..
"McKirahan" <Ne**@McKirahan.com> wrote in message
news:TK******************************@comcast.com. .. "raj chahal" <in**@digitise.info> wrote in message
news:#t**************@TK2MSFTNGP14.phx.gbl... Hi there
I've created a db field with Memo type, and I have stored some text
with carriage returns (no html) So the 3 words start on a differnt line. In
access this displays correctly ( each word starts on a new line).
However when I display these on a web page all the words appear on the
same line.
I need the words to be displayed on a seperate line.
[snip]
You'd have to know which word or words they want to be in bold.
One way is to have them start each line they want in bold with a period;
(or some other special character -- change the value of "cCHR" to it).
Then you could do this:
<%
Const cCHR = "."
sText = {your text on multiple lines}
aTemp = Split(sText,vbCrLf)
For iTemp = 0 To UBound(aTemp)
sTemp = aTemp(iTemp)
If Left(sTemp,1) = cCHR Then
aTemp(iTemp) = "<b>" & Mid(sTemp,2) & "</b>"
End If
Next
sText = Join(aTemp,"<br>")
%>
<%=sText%>
The above is untested -- let me know if there's a problem.