when I a get the XML url from a recordset I get this error
Invalid procedure call or argument: 'xmlDOM.load'
Set xmlDOM = CreateObject("MSXML2.DOMDocument")
xmlDOM.async = False
xmlDOM.setProperty "ServerHTTPRequest", True
sql="select top 1 * from rss where id=12"
rs.open sql,objcon
if not rs.eof then
response.write rs("url") 'This returns http://npps.ir/rss.aspx?c=25
xmlDOM.Load(rs("url"))
end if
rs.close
But there is no error when I hardcode that url (however it returns false because the target url is not a valid XML):
xmlDOM.Load("http://npps.ir/rss.aspx?c=25")
As I read in documentation of MSXML2 the Load method will return true or false on the case of succes or fail. So why do I get that error and why there is no error when I hardcode the url?
Update:
when I used xmlDOM.Load(cstr(rs("url")))
I got no error. Isn't a recordset value a string itself?