现在的位置: 首页 > 综合 > 正文

关于无效使用 Null: ‘Replace’

2013年11月29日 ⁄ 综合 ⁄ 共 234字 ⁄ 字号 评论关闭

使用REPLACE来将数据库里读出来的数据替换,如果字段不为空是正常,但如果
为空时就出现以下提示:
Microsoft VBScript 运行时错误 错误 '800a005e' 
无效使用 Null: 'Replace' 

可以先判断
if isnull(rs("coutent"))=false then
response.write("null") 
else
response.write replace(rs("coutent"),chr(13),"<br/>")
end if

抱歉!评论已关闭.