Ragazzi ho cercato di andare avanti, ma nada.
A me non interessa visualizzare la pagina, ma devo solo inviare la richiesta di invio e vorrei farlo senza usare webbrowser e quindi senza intasare il mio programmino con cookie e cache.
Quindi ho pensato ad una webrequest di tipo GET visto che non mi occorre scrivere nessun username o quant'altro.
Allora ho pensato di dare queste righe di codice:
codice:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Dim req As System.Net.HttpWebRequest = CType(System.Net.HttpWebRequest.Create("http://tuttopertuttigusti.blogspot.com/"), System.Net.HttpWebRequest)
req.Method = "GET"
Using res As System.Net.HttpWebResponse = CType(req.GetResponse(), System.Net.HttpWebResponse)
Dim statusCode As String = res.StatusCode
Dim description As String = res.StatusDescription
Dim str As System.IO.StreamReader = New System.IO.StreamReader(res.GetResponseStream())
Dim response As String = str.ReadToEnd()
str.Close()
End Using
MsgBox("Ho finito!")
End Sub
Però ho notato che nonostante in fase di debug non mi da errori, la richiesta non viene eseguita. Infatti, ho testato tramite un sito web se venisse effettivamente caricata la richiesta, tramite l'incremento di un visitatore (ho utilizzato un casuale forum di forumfree per testarlo) ma nada
Dove sbaglio??
Vi ringrazio anticipatamente