Click here to Skip to main content
15,895,084 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi all:
I created a https server using Serv-U,the URL is:https://10.172.149.43. I can login the https if i use the IE web, and can download file from the https. Now i want to know how can i download a specific file automatically(LabVIEW,C++,anyone is OK!)
Posted

You can work with HTTPS exactly as with HTTP, using the class System.Net.HttpWebRequest. See the explanation if the MSDN page below: you should use System.Net.WebRequest.Create to get the instance of HttpWebRequest, not HttpWebRequest constructor; concrete run-time type will be figured out of URL schema (https:// in your case).

See:
http://msdn.microsoft.com/en-us/library/system.net.httpwebrequest.aspx[^],
http://msdn.microsoft.com/en-us/library/system.net.webrequest.aspx[^] (see code sample for HTTP, but use "https://...").

I don't know detail of your authentication page, but if this is a regular Web form with user name/password, you can log in using "POST" method.
This can give you the idea:
http://social.msdn.microsoft.com/Forums/en/ncl/thread/105a3dcc-949f-4f1a-887e-40fedb9f2b62[^].

—SA
 
Share this answer
 
v2
Yes, we are all fine, thanks... but please, could you tell us what have you tried till now? what problems do you have? ...

We will help you, but first we need to know what happens to even try it...

PS: google is your fRiend... (I guess most of the people misses that R and then no one uses it)...

searching for that: "https download files c++" will give you nice results... among them:

http://www.cplusplus.com/src/[^]


HTH...
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900