Use execute "POST" with internet transfer control 
Author Message
 Use execute "POST" with internet transfer control

Hi,

I am using MSINET.OCX to post some form data but the server can't get the
form data. I noticed that VB5.0 can't work with this control properly. But I
am using VS 6.0. Anybody get the similiar problem? My MSINET.OCX version is
6.008169 and VB6 with SP3.

thks,  wayne



Thu, 17 Oct 2002 03:00:00 GMT  
 Use execute "POST" with internet transfer control
Oh Oh, I know that one!

This bit of code made it work for me..

         Dim strURL As String, strFormData As String
         strURL = "http://webserver/generic.asp"
         strFormData = "fname=randy&lname=morgan"
         Inet1.Execute strURL, "Post", strFormData, _
            "Content-Type: application/x-www-form-urlencoded"

The part that actually makes it work is the last parm:

"Content-Type: application/x-www-form-urlencoded"

This last line is needed or the form posts nothing..

I did not find any docs that clearly specified what I needed to pass. Until
I ran across this KB article:

http://support.microsoft.com/support/kb/articles/Q167/7/06.asp

Gotta dig hard if you want answers!

- Brian Pavlich


Quote:
> Hi,

> I am using MSINET.OCX to post some form data but the server can't get the
> form data. I noticed that VB5.0 can't work with this control properly. But
I
> am using VS 6.0. Anybody get the similiar problem? My MSINET.OCX version
is
> 6.008169 and VB6 with SP3.

> thks,  wayne



Fri, 18 Oct 2002 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Internet Transfer Control "Execute" Method

2. NEEDED: Example of Internet Transfer Control use of Execute using POST

3. MS Internet Transfer Control - "PUT"

4. "Passive" Internet Transfer Control FTP connection

5. Internet Transfer Control, "GET", and the HTTP Protocol

6. MS Internet Transfer Control - "PUT"

7. Internet Transfer Control "Access Denied"

8. Internet Transfer Control - "Element Not Found"

9. VB5 Internet Control.Execute "CD subdir"

10. internet control execute ,"HEAD" problem

11. NEEDED: Example of POST operation with Internet Transfer Control - Execute method

12. Using "POST" method in INET control

 

 
Powered by phpBB® Forum Software