Results 1 to 2 of 2

Thread: POSTing data to a webpage

  1. #1

    Thread Starter
    Retired VBF Adm1nistrator plenderj's Avatar
    Join Date
    Jan 2001
    Location
    Dublin, Ireland
    Posts
    10,359

    Unhappy POSTing data to a webpage

    I don't understand this. I have the following code:

    Code:
                objRequest = WebRequest.Create(strLoginURL)
                With objRequest
                    .Method = "POST"
                    .ContentType = "application/x-www-form-urlencoded"
                    .CookieContainer = ckeCookies
                End With
                Dim stmRequestWriter As New StreamWriter(objRequest.GetRequestStream)
                stmRequestWriter.Write(strPostData)
                stmRequestWriter.Close()
    The code executes okay, but without the desired results. After investigating using a packet sniffer, I've discovered that the POST isn't going through in one go.
    If I post the exact same form using IE6, it posts it with all the correct data in the HTTP header. But with my ASP.NET Web Service, it makes the initial POST, and then the rest of the data is stuck into HTTP Continuation packets.

    So how is IE6 posting the same (actually more data), in one request, and my service's data is being split up into n difference HTTP segments?
    Microsoft MVP : Visual Developer - Visual Basic [2004-2005]

  2. #2
    I wonder how many charact
    Join Date
    Feb 2001
    Location
    Savage, MN, USA
    Posts
    3,704

    Re: POSTing data to a webpage

    Perhaps its getting buffered? If so I thought there was a way to force a flush on a stream...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width