I used the samplecode associated with linkid=139 but replaced the sURL with my asp url plus username and pwd which I tested in IE, however, it does not appear to work via the vbs file.
The vbs file is sitting in the same directory as the asp page. The asp page does create, write and close a file.
Help troubleshooting would be greatly appreciated.
scheduletest.asp :
<%@ LANGUAGE="VBSCRIPT" %>
<%
dim objFMR_FSO,objFMRTS
set objFMR_FSO = CreateObject ("Scripting.FileSystemObject")
dim testfile
testfile="c:\inetpub\wwwroot\formstracking_monthly\asp\pdfreports\test.txt"
if not objFMR_FSO.FileExists(testfile) then
set objFMRTS=objFMR_FSO.CreateTextFile(testfile)
else
set objFMRTS=objFMR_FSO.OpenTextFile(testfile,ForAppending)
end if
objFMRTS.WriteLine("test test")
objFMRTS.Close
set objFMR_FSO = Nothing
set objFMRTS = Nothing
%>
test.vbs:
Sub MyASPJob
Dim oXMLHttp
Dim sURL
on error resume next
Set oXMLHttp = CreateObject("MSXML2.XMLHTTP.3.0")
' sURL="http://usr:pwd@url/formstracking_monthly/asp/scheduletest.asp"
oXMLHttp.open "GET", sURL, false
oXMLHttp.send()
if oXMLHttp.status = 200 Then
' Retrieve enter HTML response
MsgBox oXMLHttp.ResponseText
else
' Failed
end if
Set oXMLHttp = nothing
End Sub
Call MyASPJob()