紫禁城的秘密ed2k:求教各位VB高手!

来源:百度文库 编辑:中科新闻网 时间:2024/05/02 02:43:13
如何在文本框中实现替换。

把文段中的回车和换行替换为<p>和<br>!

Private Sub Text2_Change()
帮忙把这里补上,谢谢
End Sub

Private Sub Text2_Change()
Dim temp as string
temp=Text2.Text
temp=replace(temp,chr(10),"<p>")
temp=replace(temp,chr(13),"<br>")
text2.text=temp
End Sub

http://www.china-askpro.com/vbasic27.shtml
http://tech.acnow.net/html/Program/VB/