Long ll_session ll_connect, ll_request
String lsnull
String ls_url, ls_server
String ls_msg=the fill (" ", 4 * 1024 * 10)
Long ll_index ll_msg_len, ls_error
Boolean lb_temp
Setnull (lsnull)
Ll_msg_len=len (ls_msg)
Ll_session=InternetOpenA (lsnull, 0, lsnull lsnull, 0)
Ls_server="www.applevb.com"
Ll_connect=InternetConnectA (ll_session ls_server, 80, lsnull, lsnull, 0, 3)
Ls_url="/sourcecode/nt_service.zip"
Ll_request=HttpOpenRequestA (ls_url ll_connect, "GET", "HTTP/1.1," lsnull, "*/*", 0, 0)
Lb_temp=HttpQueryInfoA (ll_request, 5, ls_msg, ll_msg_len, ll_index)
Ls_error=GetLastError ()
Messagebox (' ', ls_error)
Every newspaper out fault is 12150, said can't find the file header information? Inside the file address into the thunderbolt, however, is that you can grab the file header information?
Brain damage,,, there is something wrong with the code? Participate in take oh ~
CodePudding user response:
Add, said some of the methods are not online, such as the second parameter can't InternetConnectA http://protocol headers, do so, still not,,, function declaration is as follows://1.
The function long InternetOpenA (string sAgent, long lAccess, string sProxyName, string sProxyBypass, long lFlags) library "wininet. DLL
"//2.
The function long InternetConnectA (long hInternetSession, string lpszServerName, long nProxyPort, string lpszUsername, string lpszPassword, long dwService, long dwFlags, long dwContext) library "wininet. DLL
"//3.
The function long HttpOpenRequestA (long hConnect, string lpszVerb, string lpszObjectName, string lpszVersion, string lpszReferrer, string lplpszAcceptTypes, long dwFlags, long dwContext) library "wininet. DLL
"//4.
The function Boolean HttpQueryInfoA (long hRequest, long dwInfoLevel, ref string lpvBuffer, ref long lpdwBufferLength, ref long lpdwIndex) library "wininet. DLL
"//
The Function Long GetLastError () library "kernel32. DLL"
CodePudding user response:
The up ~ up ~CodePudding user response:
MarkIf you use the pb10 above, on the outside of the defined function to add alias for 'InternetOpenA; ANSI '
CodePudding user response:
Top post!!!!!!CodePudding user response:
CodePudding user response:
Dizzy dead,,, ever know? I'm the ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~... living to see ah, ha ha ~CodePudding user response:
Actually you can have a try, might be that there is a problem, I try to...CodePudding user response:
Still no one today? Speechless,,,,,,,,,,,,,,CodePudding user response:
Use InternetOpenUrl