Send parameters to a URL and receive the returned parameters. Public String sendmsg (string user, string password, string phone, string text) {try {// If (! RegEx. ismatch (phone, @ "^ (13 | 15) \ D {9} $") // return "Incorrect mobile phone number format! "; String url =" http://www.xunsai.net: 8000 /"; string Param = "user =" + User + "& Password =" + password + "& phonenumber =" + phone + "& text =" + TEXT + "& charset = gb2312"; httpwebrequest request = (httpwebrequest) webrequest. create (URL); Request. method = "Post"; request. allowautoredirect = true; request. contenttype = "text/html; charset = gb2312;"; networkcredential NC = new networkcredential (user, password ); Request. credentials = NC; byte [] DATA = encoding. getencoding ("gb2312 "). getbytes (PARAM); Request. contentlength = data. length; stream = request. getrequeststream (); stream. write (data, 0, Data. length); stream. close (); httpwebresponse response = (httpwebresponse) request. getresponse (); streamreader sr = new streamreader (response. getresponsestream (), encoding. getencoding ("gb2312"); string S = Sr. readtoend (); response. close (); Return s;} catch (exception e) {Return e. message ;}} protected void button#click (Object sender, eventargs e) {// put the following strings. empty Replace the string url = string according to the remarks you need. format ("http://bms.hichina.com/sms_gateway/sms_api? "+" User_id = {0} & Password = {1} & mobile_phone = {2} "+" & MSG = {3} & send_date = {4} & subcode = {5 }", string. empty // user ID, String. empty // password, String. empty // phone number, server. urlencode (string. empty) // text message, server. urlencode (string. empty) // sending date, String. empty // enterprise ID); system. net. webClient client = new system. net. webClient (); string reply = client. downloadstring (URL); label1.text = reply ;}