Hello,

My name is Juan. This is my first post here, I expect to exchange information, experiences and code.

Well, I begin with this crazy thing called Inet....
I am automating a web page written in ASP. It consists of forms, posting data, and receiving succesive responses and newer posts. I discovered what data to post correctly.

The problem is that I have an Execute method and when I run it posting data to the server, the StateChanged event does NOT fire! I need to fire it up because the last form I send returns a text file as result. I tried to force the invocation writing Inet1_StateChanged 12 in the function code, but it hangs the app.

Here is the code:

Inet1.Execute URL, "POST", Data, "Content-Type: application/x-www-form-urlencoded"


Private Sub Inet1_StateChanged(ByVal State As Integer)
' Retrieve server response using the GetChunk
' method when State = 12.

Dim vtData As Variant ' Data variable.
Dim lngFileSize As Long


If State = 12 Then

Dim strData As String
Dim bDone As Boolean: bDone = False

lngFileSize = CLng(Inet1.GetHeader("Content-length"))

strData = Inet1.GetChunk(lngFileSize, icString)

Module1.InetCompleted = True
Module1.strResponse = strData



End If

End Sub

Hope you can help me.

Best wishes.


Juan