I cannot figure out why when I expand the requestStream variable that I see that error. Here's my code:
...
request.Timeout = 30000;
request.Method = "POST";
request.ContentType = "application/x-www-form-urlencoded";
// write data to stream
byte[] requestBytes = Encoding.UTF8.GetBytes(request.ToString());
using (Stream requestStream = request.GetRequestStream())
{
requestStream.Write(requestBytes, 0, requestBytes.Length);
requestStream.Close();
}
...
...
Go to the complete details ...