I'm trying to send data from a mobile application written in Java ME, to an ASP.NET website connected to an SQL server. I tried to open an httpconnection output stream in the Java ME application, and send the data in a POST to the website. The problem is I don't know how to accept data on the website. I found code online that I tried to modify to suit my application, but I feel I'm waaaay off. Could anyone give me some pointers on how to go about this?
Protected Sub Button1_Click(sender As Object, e As System.EventArgs) Handles Button1.Click Dim str As Stream Dim strLen As Integer Dim strRead As Integer 'Request input stream from the poster str = Request.InputStream 'Get the length of incoming string While (strLen = 0) strLen = str.Length End While 'make a Byte array the size of the stream Dim strArr(strLen) As Byte 'read the stream into the array strRead = str.Read(strArr, 0, strLen) Label1.Text = strArr.ToString() End Sub