1
我试图让用户选择下载并保存网页到他们想要的位置。我一直在寻找解决方案,但似乎没有任何工作。我在经典的asp中使用vbscript。使用vbscript下载并保存网页
这是我最后一次尝试
dim xHttp: Set xHttp = createobject("Microsoft.XMLHTTP")
dim bStrm: Set bStrm = createobject("Adodb.Stream")
xHttp.Open "GET", "" &Session("ServerURL") & "/idautomation/IDAutomationStreamingLinear.aspx?D=MAPS$"&request.QueryString("catcode")&"%25"&request.QueryString("typecode")&"&X=0.09&BH=3&S=0&CC=T&LM=5&TM=7.5&ST=F", False
xHttp.Send
with bStrm
.type = 1 '//binary
.open
.write xHttp.responseBody
.savetofile "d:\DownloladPdf.pdf", 2 '//overwrite
end with
但它抛出一个“写入文件失败。”在.savetofile线。
我希望用户能够选择在哪里保存它...
显示您尝试过的代码。这不是作业解决服务 – mumair
我编辑我的问题 – programmingGirl
可能的重复[如何使用vbscript中的经典asp下载文件](http://stackoverflow.com/questions/12929866/how-to-download-the-files-使用-vbscript-in-classic-asp) – Dijkgraaf