Community discussion forum

Problem handling Redirects with MSXML2.XMLHTTP

  • 1 year ago
    I am having a problem handing redirects in vb with MSXML2.XMLHTTP. What happens is it never sees the redirects, it automatically forwards to the next link without my knowledge. I am working on an application that speaks to the webpage. All is fine until I get to the part where I am about to download the file. When I "POST" the data that it is requesting the source of the html is suppose to post a link to a file. It does the samething in the browser. Once you submit the data it automaticly starts downloading the file. The issue I have with that is I can not get the header information before it starts the download which in turn makes it impossible for me to get the filename. So I have no clue what to save the fileas. Any suggestions? *update... i found a component that does prevent the redirects and will show the headers of the redirect page which includes the link to the file. But I would still rather use xmlhttp because it is free.
    Post was edited on 09/11/2008 17:53:17 Report abuse
  • 1 year ago
    raising hand for help!
  • 1 year ago
    I found out while researching it is not possible with xmlhttp. Maybe in the future, but until then I will have to rewrite the code using winhttprequest, which has an api call to prevent redirects.. which would solve my issue.

Post a reply

Enter your message below

Sign in or Join us (it's free).

We'd love to hear what you think! Submit ideas or give us feedback