// This is the background submission function of the SMS platform.
String postData = string. format ("ECODE = {0} & USERNAME = {1} & PASSWORD = {2} & MOBILE = {3} & CONTENT = {4}", ECODE, USERNAME, PASSWORD, MOBILE, CONTENT); // The data to be issued
Byte [] byteArray = System. Text. Encoding. UTF8.GetBytes (postData );
HttpWebRequest objWebRequest = (HttpWebRequest) WebRequest. Create ("http://n.020sms.com/MSMSEND.ewing"); // sending Address
ObjWebRequest. Method = "POST"; // submission Method
ObjWebRequest. ContentType = "application/x-www-form-urlencoded ";
ObjWebRequest. ContentLength = byteArray. Length;
Stream newStream = objWebRequest. GetRequestStream (); // Send the data.
NewStream. Write (byteArray, 0, byteArray. Length); // Write Parameters
NewStream. Close ();
HttpWebResponse response = (HttpWebResponse) objWebRequest. GetResponse (); // get the response
StreamReader sr = new StreamReader (response. GetResponseStream (), System. Text. Encoding. Default );
String textResponse = sr. ReadToEnd () + "return data"; // return data
Response. Write (textResponse); // print the return value
From yagene