select case mid(str,i,1)
case "<"
result=result+"<"
case ">"
result=result+">"
case chr(13)
result=result+"<br>"
case chr(34)
result=result+"""
case "&"
result=result+"&"
case chr(32)
'result=result+" "
if i+1<=l and i-1>0 then
if mid(str,i+1,1)=chr(32) or mid(str,i+1,1)=chr(9) or _
mid(str,i-1,1)=chr(32) or mid(str,i-1,1)=chr(9) then result=result+" "
else
result=result+" "
end if
else
result=result+" "
end if
case chr(9)
result=result+" "
case else
result=result+mid(str,i,1)
end select
ADC.Server = "http://<%= Request.ServerVariables("SERVER_NAME") %>"
ADC.Connect = "DSN=ASCS_SQL;UID=OSCS02ADM;PWD=PORTPIA"
ADC.ExecuteOptions = adcExecSync
ADC.sql="自己定义的sql语句"
adc.refresh
if not adc.recordset.eof then
jname.value = adc.recordset("字段名")
else
'退出程序
end if