found by googling ADODB.Stream large file
for i = 0 to objStream.sizeMy earlier trials along same lines did not work when I tried the Binarywrite and the Read calls in different lines, probably since I didn't save the Read's return value in a variable or something. When it had not worked, briefly tried a javasript-based solution:
i = i + 128000
Response.BinaryWrite(objStream.Read(128000))
Response.Flush
next
<script language="JavaScript" type="text/JavaScript">The experts exchange link had some small syntax problems like SaveAs not within quotes, script tag not having the language=Javascript etc. Abandoned this as unsuitable because IE6 on WinXP was playing the file in Windows Media Player instead of showing the download box. Firefox, Konqueror, IE7 etc worked, Safari also did not work.
function forcedown(x){
myTempWindow = window.open(x,"SSS");
myTempWindow.document.execCommand("SaveAs",null,x);
myTempWindow.close();
}
</script>
....
<a href="javascript://" onclick="forcedown('http://downloads.radiosai.org/filename.wmv');">dwnld</a>
No comments:
Post a Comment