replace 遇到 Null 值時會發生錯誤,錯誤訊息:Null 的使用不正確: 'replace'
原程式碼:
out = out & replace(asrs.Fields(i).Value,","," ") & ","
改為:
If Not IsNull(as400rs.Fields(i).Value) Then
out = out & replace(asrs.Fields(i).Value,","," ") & ","
Else
out = out & " " & ","
End If
沒有留言:
張貼留言