Function Downurl (StrRemoteurl, Strlocalurl)
{
Try
{
VAR XMLHTTP = New ActiveXObject ("Microsoft.xmlhttp");
XMLHTTP.Open ("Get", StrremoteURL, FALSE);
Xmlhttp.send ();
VAR AdodbStream = New ActiveXObject ("AdoDb.Stream");
AdoDBStream.Type = 1; // 1 = adtypebinary
AdoDBStream.open ();
AdoDBStream.write (XMLHTTP.RESPONSEBODY);
AdodbStream.savetofile (StrlocalURL, 2);
Adodbstream.close ();
Adodbstream = NULL;
XMLHTTP = NULL;
}
Catch (e)
{
WINDOW.CONFIRM ("Download URL Error!");
}
//Window.confirm ("Download is complete.");
}